Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Won't Fix
    • Affects Version/s: 1.1.5
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      I noticed today strange behavior if I change the loglevel for myfaces. Some getters of backing beans are called although the rendered attribute of a parent component is false. It is caused by class DebugUtils.traceView.
      I enabled logging via following setting: log4j.logger.org.apache.myfaces=DEBUG

      Sample jsp:
      <t:panelGroup rendered="#

      {!empty requestScope['myflag']}

      ">
      <t:dataTable value="#

      {myController.value}

      " ...
      </t:panelGroup>

      myController.getValue() is now called if logging is enabled although myflag is not set in request scope.

      This makes debugging difficult if the app behaves different depending on loglevel settings. Data can be uninitialized if the parent should not be rendered (or it will be lazy initialized on each request if BackingBean is request scope and not saved in the request).

      Therefore I would prefer to skip all components that should not be rendered from output.

      I'll provide a patch as soon as possible (I 'l try this month)

      1. DebugUtils.patch
        0.7 kB
        Michael Heinen

        Activity

        Michael Heinen created issue -
        Michael Heinen made changes -
        Field Original Value New Value
        Status Open [ 1 ] Patch Available [ 10002 ]
        Hide
        Michael Heinen added a comment -

        rendered check added in order to skip components that should not be rendered

        Show
        Michael Heinen added a comment - rendered check added in order to skip components that should not be rendered
        Michael Heinen made changes -
        Attachment DebugUtils.patch [ 12375936 ]
        Thomas Andraschko made changes -
        Status Patch Available [ 10002 ] Open [ 1 ]
        Hide
        Thomas Andraschko added a comment -

        Please check our issue closing policy: http://myfaces.apache.org/wiki/core/committer-and-pmc-guide/myfaces-project-management.html
        If the is issue is still important for you, please reopen and attach a patch.

        Show
        Thomas Andraschko added a comment - Please check our issue closing policy: http://myfaces.apache.org/wiki/core/committer-and-pmc-guide/myfaces-project-management.html If the is issue is still important for you, please reopen and attach a patch.
        Thomas Andraschko made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Won't Fix [ 2 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Patch Available Patch Available
        8d 3m 1 Michael Heinen 19/Feb/08 16:08
        Patch Available Patch Available Open Open
        2749d 15h 33m 1 Thomas Andraschko 31/Aug/15 07:42
        Open Open Closed Closed
        50s 1 Thomas Andraschko 31/Aug/15 07:43

          People

          • Assignee:
            Unassigned
            Reporter:
            Michael Heinen
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development