Uploaded image for project: 'JBoss VFS'
  1. JBoss VFS
  2. JBVFS-120

Handler for vfsmemory should override getHostAddress(URL)

    XMLWordPrintable

Details

    • Task
    • Resolution: Done
    • Major
    • 2.1.3.GA
    • 2.1.2.GA
    • None
    • None

    Description

      See JBCL-117.

      Isn't the real issue here that
      org.jboss.virtual.protocol.vfsmemory.Handler
      doesn't override

      URLStreamHandler.hashCode(url)

      It is using the "host" part of the url for something that is not a host.
      This is leading to spurious DNS lookups that cannot be cached because they always fail.

      The attached patch does this by overriding getHostAddress(URL) inside org.jboss.virtual.protocol.vfsmemory.Handler to always return null. This is also semantically correct, since vfsmemory "hosts" are not real hosts at all.

      There's no reason to override hashCode() or equals(), as they both use getHostAddress().

      Attachments

        Issue Links

          Activity

            People

              ajustin@redhat.com Ales Justin
              ajustin@redhat.com Ales Justin
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: