Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-61

Validation of web.xml not working, leading to StringOutOfBounds Exception

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Obsolete
    • Icon: Minor Minor
    • None
    • 6.2.0.GA
    • None
    • Hide

      Include the following within a web.xml file:

      <listener>
      <listener-class></listener-class>
      </listener>

      Show
      Include the following within a web.xml file: <listener> <listener-class></listener-class> </listener>

      When the web.xml includes bad configuration, such as:
      ...
      <listener>
      <listener-class></listener-class>
      </listener>
      ...

      The exception is cryptic (attached), because it ends up passing the bad entry to JBoss Modules, which also does not handle the exception case well. Several areas where this could be improved:

      JBoss Modules should validate the input and provide back a descriptive exception stating "Empty class name" rather than causing a StringOutOfBounds exception.

      JBoss Web should provide details that the exception occurred while processing web.xml, which is not immediately clear from the exception produced. Ideally, the exception would also include the location in the XML that had issues validating (application, xml file name, and line number of the exception).

              rmaucher Remy Maucherat
              brad.davis@amentra.com Brad Davis
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: