Tips for Servlet Developers
Maximizing servlet performance requires techniques somewhat different from those used to maximize the performance of stand-alone programs. One important step is to avoid having to connect to the LDAP server for each request. The connection-pooling model presented in this chapter solves this problem.
Another step to increase performance is to make use of the caching module of the SDK to avoid having to go out on the wire to satisfy repetitive searches. The cache object can be queried to see how many requests are being satisfied from the cache versus going to the directory. See Chapter 15 for details on how and when to use LDAPCache.
Finally, keep the DN of each record around to use as a key for direct access to a user's ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access