Unboundid setHealthCheck() and setHealthCheckIntervalMillis()

78 views
Skip to first unread message

Austin

unread,
Oct 1, 2020, 10:40:27 PM10/1/20
to sakai-dev
Hello Sakai Devs,

We are seeing some "SocketException(Connection reset)" errors on "ldap bind" when connecting to our ldap server when using the unbound library.  I suspect they are caused by our ldap server having a short idle timeout setting and I don't think we can increase that timeout.  

I compared the network traffic between unboundid and jldap and it seems like jldap starts a new connection for every request.  But unboundid seems to reuse the connection.  Maybe that's just the nature of unboundid's connection pool?

Anyway, I've been experimenting with unboundid's 

setHealthCheck(LDAPConnectionPoolHealthCheck healthCheck)
setHealthCheckIntervalMillis(long healthCheckInterval)

Is that something worth starting a JIRA for?  Or is there a better way to handle "SocketException(Connection reset)" errors?

Actually, in the past, https://groups.google.com/a/apereo.org/g/sakai-dev/c/GqZvmAH4iKs/m/CjZ9GebiBgAJ, we worked around a similar error using

connectionPool.setRetryFailedOperationsDueToInvalidConnections(true).

But it seems like this new error, which appears in the tomcat logs, but no users have complained about failing to login, happens intermittently even with that option enabled.

Thanks,

Austin

Austin

unread,
Oct 2, 2020, 7:15:56 PM10/2/20
to sakai-dev
I started https://jira.sakaiproject.org/browse/SAK-44410 and I'll submit a PR soon, unless some thinks there's a better way to fix connection reset errors other than enabling Unboundid's health check interval.
Reply all
Reply to author
Forward
0 new messages