Uploaded image for project: 'Karaf'
  1. Karaf
  2. KARAF-985

LDAPLoginModule generates a large number of DirContext objects

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.4
    • Fix Version/s: 2.2.5, 3.0.0
    • Component/s: karaf-config
    • Labels:
      None
    • Environment:

      Karaf 2.2.5-snapshot

      Description

      In class org.apache.karaf.jaas.modules.ldap.LDAPLoginModule, "DirContext.close()" and "NamingEnumeration.close()" are not called in all cases.
      Although it is not mandatory, it would be better to call it in all cases (to be sure, in a "finally" block).
      http://download.oracle.com/javase/tutorial/jndi/ldap/close.html
      Otherwise, this leaves one "com.sun.jndi.ldap.Connection" thread running for each LDAP request. After several minutes, the thread disappears automatically.
      During a performance test with 10 concurrent users, this creates up to several hundreds of such threads.

        Attachments

          Activity

            People

            • Assignee:
              jbonofre Jean-Baptiste Onofré
              Reporter:
              metatech metatech
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 2h
                2h
                Remaining:
                Remaining Estimate - 2h
                2h
                Logged:
                Time Spent - Not Specified
                Not Specified