Update 2:

I think I found at least one part of the code that is causing problems:

It is findUserByUserName(String userName) in LDAPExtUserModuleImpl (that uses 
searchUsers).

I changed the code:

         SearchResult res = (SearchResult)sr.iterator().next();         
  |          Context ctx = (Context)res.getObject();
  |          String dn = ctx.getNameInNamespace();
  |          
  |          return createUserInstance(res.getAttributes(), dn);

With:

         SearchResult res = (SearchResult)sr.iterator().next();         
  |          Context ctx = (Context)res.getObject();
  |          String dn = ctx.getNameInNamespace();
  |          User user = createUserInstance(res.getAttributes(), dn);
  |          System.err.println("CREATED USER AND CLOSE CONTEXT");
  |          ctx.close();
  |          return user;

Now the Context is closed and caused the connection to be released right away 
(according to the pooling debug messages).

Continuing with experiments.

In any case, I do think the LDAP code needs optimizing. Is there any technical 
documentation on it available?

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4141846#4141846

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4141846
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to