<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Apr 25, 2016 at 7:48 PM, Jeremy A Scott <span dir="ltr"><<a href="mailto:jeremy.scott@wisc.edu" target="_blank">jeremy.scott@wisc.edu</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">I'd like to use the pools as they were originally intended, so what are the options/config for returning the connections to the pool in a known state with BindPassivator?<br></blockquote><div><br></div><div>Modify the bindConnectionConfig bean to use a connectionInitializer:</div><div><br></div><div><bean id="bindConnectionConfig" parent="connectionConfig" p:connectionInitializer-ref="bindConnectionInitializer" /> </div><div><br></div><div>Modify the bindConnectionPool bean to use a passivator:</div><div><br></div><div><div><bean id="bindConnectionPool" class="org.ldaptive.pool.BlockingConnectionPool" parent="connectionPool"</div><div> p:connectionFactory-ref="bindConnectionFactory" p:name="bind-pool" p:passivator-ref="bindPassivator" /></div></div><div><br></div><div>Add a bindPassivator bean:</div><div><br></div><div><bean id="bindPassivator" class="org.ldaptive.pool.BindPassivator"></div><div> <property name="bindRequest"></div><div> <bean class="org.ldaptive.BindRequest" <span class="">p</span><span class="">:d</span><span class="">n</span><span class="">=</span><span class="">"#{'%{idp.authn.LDAP.bindDN:undefined}'.trim()}"</span>></div><div><div> <property name="credential"></div><div> <bean class="org.ldaptive.Credential"></div><div> <constructor-arg value="%{idp.authn.LDAP.bindDNCredential:undefined}" /></div><div> </bean></div><div> </property></div></div>
<div> </bean></div><div> </property></div><div></bean></div><div><br></div><div>--Daniel Fisher</div><div><br></div></div></div></div>