javax.naming.communicationexception:连接重置[根异常为java.net.socketexception:连接重置]

egmofgnx  于 2021-08-25  发布在  Java
关注(0)|答案(0)|浏览(439)

我创造了 User Federation 开始 KeyCloak 连接到我们的公司ldap。我已经准备好了 Connection TimeoutRead Timeout 到15分钟(900000毫秒),同步用户进程只工作了一小段时间,因为我可以看到用户在表中填充,几分钟后我看到下面的连接重置错误。我甚至尝试将“-1”设置为无限超时,但这也没有帮助。

ERROR [org.keycloak.storage.ldap.idm.store.ldap.LDAPOperationManager] (default task-24) Could not query server using DN [OU=People,DC=mydomain,DC=com] and filter [(&(mail=*)(objectclass=person)(objectclass=organizationalPerson)(objectclass=user))]: javax.naming.CommunicationException: Connection reset [Root exception is java.net.SocketException: Connection reset]; remaining name 'OU=People,DC=mydomain,DC=com'
        at java.naming/com.sun.jndi.ldap.LdapCtx.doSearch(LdapCtx.java:2003)
        at java.naming/com.sun.jndi.ldap.LdapCtx.searchAux(LdapCtx.java:1845)
        at java.naming/com.sun.jndi.ldap.LdapCtx.c_search(LdapCtx.java:1770)
        at java.naming/com.sun.jndi.toolkit.ctx.ComponentDirContext.p_search(ComponentDirContext.java:392)
        at java.naming/com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.search(PartialCompositeDirContext.java:358)
        at java.naming/javax.naming.directory.InitialDirContext.search(InitialDirContext.java:276)
        at java.naming/javax.naming.directory.InitialDirContext.search(InitialDirContext.java:276)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.store.ldap.LDAPOperationManager$4.execute(LDAPOperationManager.java:306)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.store.ldap.LDAPOperationManager$4.execute(LDAPOperationManager.java:297)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.store.ldap.LDAPOperationManager.execute(LDAPOperationManager.java:728)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.store.ldap.LDAPOperationManager.searchPaginated(LDAPOperationManager.java:297)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.store.ldap.LDAPIdentityStore.fetchQueryResults(LDAPIdentityStore.java:277)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.idm.query.internal.LDAPQuery.getResultList(LDAPQuery.java:172)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.LDAPStorageProviderFactory.syncImpl(LDAPStorageProviderFactory.java:529)
        at org.keycloak.keycloak-ldap-federation@12.0.4//org.keycloak.storage.ldap.LDAPStorageProviderFactory.sync(LDAPStorageProviderFactory.java:465)
        at org.keycloak.keycloak-services@12.0.4//org.keycloak.services.managers.UserStorageSyncManager$2$1.call(UserStorageSyncManager.java:108)
        at org.keycloak.keycloak-services@12.0.4//org.keycloak.services.managers.UserStorageSyncManager$2$1.call(UserStorageSyncManager.java:103)
        at org.keycloak.keycloak-model-infinispan@12.0.4//org.keycloak.cluster.infinispan.InfinispanClusterProvider.executeIfNotExecuted(InfinispanClusterProvider.java:78)
        at org.keycloak.keycloak-services@12.0.4//org.keycloak.services.managers.UserStorageSyncManager$2.run(UserStorageSyncManager.java:103)
        at org.keycloak.keycloak-server-spi-private@12.0.4//org.keycloak.models.utils.KeycloakModelUtils.runJobInTransaction(KeycloakModelUtils.java:228)
        at org.keycloak.keycloak-services@12.0.4//org.keycloak.services.managers.UserStorageSyncManager.syncAllUsers(UserStorageSyncManager.java:93)
        at org.keycloak.keycloak-services@12.0.4//org.keycloak.services.resources.admin.UserStorageProviderResource.syncUsers(UserStorageProviderResource.java:142)

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题