glassfish
  1. glassfish
  2. GLASSFISH-1521

Jasper must honor locally bundled standard taglibs (JSTL, JSF) if the embedding container does not provide them

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 9.1pe
    • Fix Version/s: 9.1pe_dev
    • Component/s: web_container
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: Sun

    • Issuezilla Id:
      1,521
    • Status Whiteboard:
      Hide

      fixed-pwc12

      Show
      fixed-pwc12

      Description

      The following issue has been raised on <jetty-discuss@lists.sourceforge.net>.
      Since Jetty bundles Jasper from GlassFish, we need to accommodate the scenario
      described.

      Tim Vernum wrote:

      > We're getting a regular stream of confusion about Jetty's loading of
      > JSF implementations (and occasionally JSTL) from webapps. >
      > I believe what Jetty is currently doing is not 100% correct.
      >
      > The JSP 2.1 spec says (from 7.3.2 of the PFD2, which is what I have
      > sitting on my laptop):
      >
      > The following order of precedence applies (from highest to lowest) when
      > building the taglib map (see the following sections for details):
      > 1. If the container is Java EE platform compliant, the Map Entries
      > for the tag libraries that are part of the Java EE platform. This
      > currently includes the JavaServer Pages Standard Tag Library
      > libraries and the JavaServer Faces
      > libraries.
      > 2. Taglib Map in web.xml
      > 3. Implicit Map Entries from TLDs
      > TLDs in JAR files in WEB-INF/lib
      > TLDs under WEB-INF
      > 4. Implicit Map Entries from the Container
      >
      > Jetty appears to be latching on to #1 and thus requires that webapps
      > to use implementations from the container classpath.
      > This would be correct is Jetty was Java EE compliant, but Jetty does
      > not attempt to be Java EE complaint in all situations.
      >
      > So, if Jetty is running under Glassfish/Geronimo/etc, then a
      > JSTL/JSF implementation should be available on the container
      > classpath and this should override any implementation provided by
      > the web-app.
      > But in most of these cases, the user is running Jetty by itself,
      > without a JSTL/JSF implementation on the container classpath. In
      > which case Jetty isn't acting as a Java EE platform complaint
      > container and item #1 doesn't apply.
      >
      > My proposal is that we drop the requirement that JSF be on the
      > container classpath, and instead change it to a requirement that any
      > JSF implementation on the container classpath will override the
      > implementation in the webapp (which, by my reading, is what the spec
      > actually calls for)
      >
      > Unless I've missed something in one of the other specs it seems like
      > Jetty has acutally gone too far, and it making life difficult for
      > people unnecessarily.

        Activity

        Hide
        jluehe added a comment -

        Fixed:

        Checking in TldLocationsCache.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v
        <-- TldLocationsCache.java
        new revision: 1.14; previous revision: 1.13
        done

        Show
        jluehe added a comment - Fixed: Checking in TldLocationsCache.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v <-- TldLocationsCache.java new revision: 1.14; previous revision: 1.13 done
        Hide
        kmeduri added a comment -

        Merged the fix to PWC12Dev_Branch:

        Checking in
        appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v
        <-- TldLocationsCache.java
        new revision: 1.13.6.1; previous revision: 1.13
        done

        Show
        kmeduri added a comment - Merged the fix to PWC12Dev_Branch: Checking in appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v <-- TldLocationsCache.java new revision: 1.13.6.1; previous revision: 1.13 done
        Hide
        jluehe added a comment -

        Fix caused regression, see

        https://glassfish.dev.java.net/issues/show_bug.cgi?id=1668
        (SQE cache tests failed /w PWC6117: File "/jsp/caching/Sun ONE Application
        Server Tags" not found).

        Fixed regression, as follows: Any local JAR files must be scanned for TLD
        resources unconditionally and must not be checked against the list of JAR
        files known not to contain any TLDs (only JAR files higher up in the classloader
        chain must be checked against that list).

        Checking in TldLocationsCache.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v
        <-- TldLocationsCache.java
        new revision: 1.15; previous revision: 1.14
        done

        Show
        jluehe added a comment - Fix caused regression, see https://glassfish.dev.java.net/issues/show_bug.cgi?id=1668 (SQE cache tests failed /w PWC6117: File "/jsp/caching/Sun ONE Application Server Tags" not found). Fixed regression, as follows: Any local JAR files must be scanned for TLD resources unconditionally and must not be checked against the list of JAR files known not to contain any TLDs (only JAR files higher up in the classloader chain must be checked against that list). Checking in TldLocationsCache.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/jasper/compiler/TldLocationsCache.java,v <-- TldLocationsCache.java new revision: 1.15; previous revision: 1.14 done

          People

          • Assignee:
            jluehe
            Reporter:
            jluehe
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: