Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-3744

ServletContext.getContextPath() for ROOT.war should be "", not "/"

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 9.0.0.Alpha1
    • None
    • Web (Undertow)
    • None
    • Hide

      1. Copy the attached war file (modified helloworld quickstart) as ROOT.war to standalone/deployments
      2. Visit http://localhost:8080/HelloWorld
      3. Both context path values should be empty

      Show
      1. Copy the attached war file (modified helloworld quickstart) as ROOT.war to standalone/deployments 2. Visit http://localhost:8080/HelloWorld 3. Both context path values should be empty

    Description

      According to JavaDocs (ServletContext.getContextPath and HttpServletRequest.getContextPath): "For servlets in the default (root) context, this method returns "". "

      Using latest 9.0.0.Alpha1-SNAPSHOT nightly build from https://ci.jboss.org/hudson/job/WildFly-latest-master/1334/ the value is returned in both cases as "/" rather than "" (empty string).

      Attachments

        Activity

          People

            sdouglas1@redhat.com Stuart Douglas
            sflanigan Sean Flanigan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: