Uploaded image for project: 'MyFaces Core'
  1. MyFaces Core
  2. MYFACES-3365

jsf.js: getProjectStage speed improvement

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 2.0.10, 2.1.4
    • None
    • None

    Description

      The getProjectStage in our impl is suboptimal performancewise because it is implemented purely functional. But our implementation is an imperative singleton, so we can apply the singleton pattern to the method as well and safe the state after the first determination for future access. This should save us a little bit of time because we do not have to parse the script tags every time.
      Also the 4 == in the if are slower than a direct map lookup. The code becomes tighter that way as well.

      Attachments

        Activity

          People

            Unassigned Unassigned
            werpu Werner Punz
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: