Jun 17th, 2010, 12:57 PM
AttributesMapper vs ContextMapper (performance)
For some time we have been using SimpleLdapTemplate in conjunction with a ContextMapper instance to perform various lookups and searches. In our system we sometimes return hundreds or even thousands of results from ldap.
We noticed that if we use an AttributesMapper instead of a ContextMapper (this required us to subclass SimpleLdapTemplate and add an extra method that accepts an AttributesMapper) then we get a huge performance increase (from 10 seconds now down to .5 seconds for example).
I am wondering what the difference is between the AttributesMapper and the ContextMapper that would account for this difference in performance. Any ideas?