javaserverfaces
  1. javaserverfaces
  2. JAVASERVERFACES-1557

ResourceHandlerImpl does not cache in production mode

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.2
    • Fix Version/s: 2.0.3-b01
    • Component/s: resources
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      1,557

      Description

      ResourceHandlerImpl.handleResourceRequest takes too long to deliver a 304. From
      my point of view, delivering a 304 should take quasi no time.

      The problem seems to be that ResourceManager.findLibrary is called again and
      again. Can resources really change in production mode?

      If resources can't change in production mode, simply cache all necessary
      information (most notably last modified) and return 304 immediately.

      I will look deeper into this. Maybe i will find some point to change.

        Activity

        Hide
        Manfred Riem added a comment -

        Closing issue out

        Show
        Manfred Riem added a comment - Closing issue out
        Hide
        Ryan Lubke added a comment -

        Mark fixed in b01.

        Show
        Ryan Lubke added a comment - Mark fixed in b01.
        Hide
        Ryan Lubke added a comment -

        Changes applied (r8352).

        We'll cache the timestamp for the lifetime if the ResourceInfo instance,
        however, the cache behavior is disabled by default. The cache behavior can
        be enabled by setting the com.sun.faces.cacheResourceModificationTimestamp
        context init parameter to true.

        Show
        Ryan Lubke added a comment - Changes applied (r8352). We'll cache the timestamp for the lifetime if the ResourceInfo instance, however, the cache behavior is disabled by default. The cache behavior can be enabled by setting the com.sun.faces.cacheResourceModificationTimestamp context init parameter to true.
        Hide
        Jason Lee added a comment -

        r=jdlee

        Show
        Jason Lee added a comment - r=jdlee
        Hide
        Ryan Lubke added a comment -

        Created an attachment (id=1133)
        Proposed changes (ver 1)

        Show
        Ryan Lubke added a comment - Created an attachment (id=1133) Proposed changes (ver 1)

          People

          • Assignee:
            Ryan Lubke
            Reporter:
            Frank Caputo
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: