<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Mar 24, 2016 at 12:11 PM, John Horne <span dir="ltr"><<a href="mailto:john.horne@plymouth.ac.uk" target="_blank">john.horne@plymouth.ac.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Thanks for that. I would have thought though that the strategy would<br>
have been part of the 'connectionConfig', since that is where the URLs<br>
are defined, rather than a per-provider thing.<br></blockquote><div><br></div><div>That property has been moved to connection config in the latest snapshot of ldaptive.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I have no problem with using a pool, but would like it to use round-<br>
robin when selecting which LDAP server/URL should be used for any new<br>
connections.</blockquote><div><br></div><div>You can configure the round robin strategy to use it's invocation count, rather than the connection count.</div><div>This behavior will be closer to what you expect for a connection pool.</div><div><div><bean id="connStrategy" class="org.ldaptive.provider.ConnectionStrategies$RoundRobinConnectionStrategy"></div><div>  <constructor-arg value="false" /><br></div><div></bean</div><div><bean id="jndiConfig" class="org.ldaptive.provider.jndi.JndiProviderConfig" p:connectionStrategy-ref="connStrategy" /></div></div><div><br></div><div>Since connections will attempt to reopen themselves under certain failure conditions, this doesn't guarantee that each new connection in the pool will use the next URL.</div><div>But under nominal circumstances that's the behavior you will see.</div><div>I always like to point out that none of these software solutions are a good substitute for a network load balancer.</div><div><br></div><div>--Daniel Fisher</div><div> </div></div></div></div>