javaserverfaces
  1. javaserverfaces
  2. JAVASERVERFACES-1866

ParialViewContextImpl does not respect FacesContextWrapper

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.1.0
    • Fix Version/s: 2.1_gf31_m7
    • Component/s: ajax
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

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

      size_small importance_large

      Show
      size_small importance_large

      Description

      PartialViewContextImple gets the impl's FacesContext reference from
      FacesContextImpl directly and always uses this FacesContextImpl for partial
      request processing (processPartial() always uses ctx that was passed in at
      construcion time).

      Therefore it's not possible to use wrapped FacesContext for partial request
      processing, unless wrapped FacesContext's override the method
      getPartialViewContext().

      I think there are two possible solutions:
      1. make FacesContextWrapper.getPartialViewContext() methot abstract so wrappers
      are forced to override this method.
      2. on first access PartialViewContextImpl should acquire
      FacesContext.getCurrentInstance() and cache it locally instead of using the
      passed in instance.

      1. changebundle.txt
        2 kB
        rogerk
      2. PartialViewContextImpl-1866.patch
        3 kB
        Hanspeter Duennenberger
      3. PartialViewContextImpl-1866.patch
        3 kB
        Hanspeter Duennenberger

        Activity

        Hide
        Hanspeter Duennenberger added a comment -

        Created an attachment (id=1335)
        PartialViewContextImpl patch

        Show
        Hanspeter Duennenberger added a comment - Created an attachment (id=1335) PartialViewContextImpl patch
        Hide
        Hanspeter Duennenberger added a comment -

        Created an attachment (id=1337)
        Improved patch with better selfdescribing naming

        Show
        Hanspeter Duennenberger added a comment - Created an attachment (id=1337) Improved patch with better selfdescribing naming
        Hide
        rogerk added a comment -

        Thanks for the update.
        Testing your latest patch now.

        Show
        rogerk added a comment - Thanks for the update. Testing your latest patch now.
        Hide
        rogerk added a comment -

        Committed revision 8722.

        Show
        rogerk added a comment - Committed revision 8722.
        Hide
        Manfred Riem added a comment -

        Closing issue out

        Show
        Manfred Riem added a comment - Closing issue out

          People

          • Assignee:
            rogerk
            Reporter:
            Hanspeter Duennenberger
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: