Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-7351

jboss.qualified.host.name may not be properly calculated

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • None
    • Server
    • None

      The jboss.qualified.host.name is the propery name that holds the fully-qualified name of the host machine where WildFly is running.

      If it is not explicitly set, its value is calculated as follow:

      it gets the runtime value of "HOSTNAME" or "COMPUTERNAME" environment variables, or, if neither environment variable is present, to the value of InetAddress.getLocalHost().getHostName().
      However InetAddress.getLocalHost().getHostName() does not perform a DNS lookup to get the FQDN of the current host, so it won't return the expected value.

      This issue is a consequence of https://bugs.openjdk.org/browse/JDK-8201369 fixed since JDK 11 which was not properly backported to JDK 1.8 and later fixed by https://bugs.openjdk.org/browse/JDK-8339414

      The consequences are that in the case this value is calculated using InetAddress.getLocalHost().getHostName(), the server would not calculate it as expected since JDK11 and could produce different results if you were using different versions of JDK, for example with JDK 1.8.

      At this moment the mininum JDK to run WildFly is JDK 17, so any user relaying on the server InetAddress.getLocalHost().getHostName() calculation could not be getting the expected FQDN value, so they should have found an alternative approach to configure the server FQDN host name, for example using an environment variable or explicitely setting it with -Djboss.qualified.host.name=XYZ

              yborgess1@redhat.com Yeray Borges Santana
              yborgess1@redhat.com Yeray Borges Santana
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: