0 Replies Latest reply on Feb 13, 2002 12:01 PM by Ullrich Pollaehne

    ServletRequest#getServerName() returns 'localhost'

    Ullrich Pollaehne Newbie

      Hi,

      I am using JBoss 2.4.4 with integrated Tomcat 4.0.1 from the JBoss-2.4.4_Tomcat-4.0.1.zip.
      Into this configuration I do deploy an EAR that contains a WAR which contains a WebStart enabled application and the WebStart servlet (jnlp-servlet.jar).
      Within the JNLP file I use the $$codebase variable to be able to deploy the file on different host without a need to modify the JNLP file.
      The Problem that arises is:
      The WebStart servlet replaces the $$codebase variable by requesting the hostname from the ServletRequest#getServerName() method. This method invariably returns "localhost" as the server name instead of the real server name. If I start a standalone Tomcat everything works as expected (getServerName() returns the real name and not localhost).
      Is there anything I need to configure or is this a bug?

      kind regards,
      Ullrich.