0

Considering the huge load that I am getting for authentication, using multiple threads and Connectionpool will be a best solution to handle the load. However I have two design options in my mind

  1. Pass Connectionpool to individual threads as argument and get a connection to do the bind request from ConnectionPool

  2. Pass connection to threads rather than passing Connectionpool to threads and do bind request

Which Design would you prefer most and what are the reasons for them?

Community
  • 1
  • 1
Malinda
  • 336
  • 2
  • 12

1 Answers1

1

I found an answer for this question after a discussion happened with UnboundIDSDK forum. I will add the final finding for others. according to this It is recommended to available the pool to threads by passing the pool to thread as argument.

public BindResult doBind(LDAPConnectionPool pool, 
                     BindRequest bindRequest)
         throws LDAPException
{
 return pool.bind(bindRequest);
}
Malinda
  • 336
  • 2
  • 12