[ 
https://issues.apache.org/jira/browse/DIRAPI-362?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17171317#comment-17171317
 ] 

Emmanuel Lécharny commented on DIRAPI-362:
------------------------------------------

No, you don't need to create multiple connction for each user. One connection 
per user is clearly enough, and you can even manage to use a connection pool, 
shared by all the users (we do have such a thing in the API 
(http://directory.apache.org/api/gen-docs/latest2/apidocs/org/apache/directory/ldap/client/api/LdapConnectionPool.html),
 assuming you manage the user context on your side.

Actually, you can also keep one connection per user, but that would be a waste 
of resource (inodes and memory). Better use a pool of bound connection, re-bind 
them when needed, send the requests you need, then unbind and put back the 
connection to the pool. To be clear : what is costly, time wise, is the TCP 
connection establishment. Binding, requesting, unbinding is not really 
bothersome.

If you don't mind dealing with authorization on the LDAP server, then you can 
even use an admin LDAP connection, to avoid the Bind/Unbind requests.

Regarding the other aspect of your question (the token bit), it's pretty 
orthogonal to LDAP, and even more to the API. You can ask the server to use 
whatever you need to login and authenticate a client, assuming the server is 
capable of doing so. Typically, you may delegate authentication in a LDAP 
server to a Microsoft AD directory. But the server has to support such a 
feature. The LDAP API offers the EXTERNAL SASL bind system to do that. 

> Multiple client login Using Apache Directory Client API
> -------------------------------------------------------
>
>                 Key: DIRAPI-362
>                 URL: https://issues.apache.org/jira/browse/DIRAPI-362
>             Project: Directory Client API
>          Issue Type: Question
>    Affects Versions: 2.0.0
>            Reporter: Deepak Purbia
>            Priority: Major
>
> Hi,
> I wan to Integrate Active Directory in my current web application for this I 
> am using Apache Directory Client API . I am following this guide  
> [https://directory.apache.org/api/user-guide.html] for client implementation. 
> But in this guide i only see connection is used by single client only. What 
> if multiple client login .  How do I manage multiple client session in LDAP  
> client. Is there any way to support this kind of situation.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to