MyFaces Core
  1. MyFaces Core
  2. MYFACES-3150

[perf] buildView: review usage of "facelets.FACET_NAME"

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.1.0-SNAPSHOT
    • Fix Version/s: 2.0.13, 2.1.7
    • Component/s: General
    • Labels:
      None
    • Environment:
      myfaces core trunk

      Description

      Consider 1000 components in view without any f:facet.

      During VDL.buildView Facelets call for each component ComponentHandler.getFacetName(FaceletContext, UIComponent) and that creates 3 calls of Map.get():

      1) _ComponentAttributesMap.getPropertyDescriptor(String)
      2) _ComponentAttributesMap.getUnderlyingMap().get()
      3) UIComponent.getValueExpression(String)

      3000 "empty" invocations in buildView withnout match.

      Suggestions:

      • do not use Component.attribute for that marker (comes from FacetHandler)
      • replace map.get calls with property for performance reasons
      • use a stack or property on AbstractFaceletContext if possible

        Activity

        Martin Kočí created issue -
        Martin Kočí made changes -
        Field Original Value New Value
        Assignee Martin Kočí [ markoc50 ]
        Martin Kočí made changes -
        Attachment MYFACES-3150-v1.patch [ 12517284 ]
        Leonardo Uribe made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Martin Kočí [ markoc50 ] Leonardo Uribe [ lu4242 ]
        Fix Version/s 2.0.13 [ 12319847 ]
        Fix Version/s 2.1.7 [ 12319845 ]
        Resolution Fixed [ 1 ]
        Leonardo Uribe made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Leonardo Uribe
            Reporter:
            Martin Kočí
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development