Uploaded image for project: 'Shiro'
  1. Shiro
  2. SHIRO-498

ThreadLocal should not be created when not necessary

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.2.2
    • 1.2.4
    • None

    Description

      org.apache.shiro.util.ThreadContext.getValue(Object) and org.apache.shiro.util.ThreadContext.remove(Object) initialze the TheadLocal unnecessarily via initialValue(). Both methods should return without creating the ThreadLocal to avoid potential memory leaks.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jkemnade Jochen Kemnade
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: