On Tue, Feb 9, 2010 at 6:17 AM, Emmanuel Lecharny <firstname.lastname@example.org>
when the client issue a first BindRequest, the messageId will be '1'. It will start a new LdapSession on the server, with all the subsequent operations having an incremented messageId. The clinet is responsible for the ID generation.
Now, if the client issue a new BindRequest, should the messageId be incremented, or reset to 1 ? My understanding is that we are stil in the same LdapSession, with a request for new credentials, and we then need to use an incremented ID.
For instance, in this scenario, where the ID is in parentheses after the request :
the XXX should be 4.
Now, that raise another question : whet should we do with the responses to (3), assuming we haven't received all of it ? Should we discard them ? My understanding is that they are still valid.
The values for the message ID are specific to the session established with the bind not with the connection. So we would start again from 1. In a way note that the session:messageId uniquely identifies each message received by the server - although this is not explicit with a session id there is a unique LdapSession object created.
So a new LdapSession object needs to be created for the new bind request that comes in and numbers need to start back at 1. They can start at 4 too if you like but this is not necessary, you just don't view 1 2 and 3 as value usable message ID values for that session.
Now in terms of outstanding operations that are still in progress you need to abandon or cancel them programatically once there is an explicit UnbindRequest or there is an implicit unbind with a RE-BindRequest using the same TCP socket.
Does this make sense or am I missing something.