-
Type: Bug
-
Status: Resolved
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 10.10
-
Fix Version/s: 10.10-HF28, 11.2, 2021.0
-
Component/s: Authentication
The first authentication with Keycloak which also creates the user in the user directory if it does not exist fails with this error
2020-05-27T21:51:22,083 ERROR [nuxeo-error-log] org.nuxeo.ecm.directory.DirectoryException: The document cannot be updated because its id is missing at org.nuxeo.ecm.directory.BaseSession.updateEntry(BaseSession.java:406) at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.updateUser(UserManagerImpl.java:1412) at org.nuxeo.ecm.platform.usermanager.UserManagerImpl.updateUser(UserManagerImpl.java:1044) at org.nuxeo.ecm.platform.ui.web.keycloak.KeycloakUserMapper.updateUser(KeycloakUserMapper.java:151) at org.nuxeo.ecm.platform.ui.web.keycloak.KeycloakUserMapper.lambda$getOrCreateAndUpdateNuxeoPrincipal$0(KeycloakUserMapper.java:73) at org.nuxeo.runtime.api.Framework.doPrivileged(Framework.java:293) at org.nuxeo.ecm.platform.ui.web.keycloak.KeycloakUserMapper.getOrCreateAndUpdateNuxeoPrincipal(KeycloakUserMapper.java:61) at org.nuxeo.usermapper.service.UserMapperComponent.getOrCreateAndUpdateNuxeoPrincipal(UserMapperComponent.java:110) at org.nuxeo.usermapper.service.UserMapperComponent.getOrCreateAndUpdateNuxeoPrincipal(UserMapperComponent.java:104) at org.nuxeo.ecm.platform.ui.web.keycloak.KeycloakAuthenticationPlugin.handleRetrieveIdentity(KeycloakAuthenticationPlugin.java:128) at org.nuxeo.ecm.platform.ui.web.auth.NuxeoAuthenticationFilter.handleRetrieveIdentity(NuxeoAuthenticationFilter.java:1146) at org.nuxeo.ecm.platform.ui.web.auth.NuxeoAuthenticationFilter.doFilterInternal(NuxeoAuthenticationFilter.java:549) at org.nuxeo.ecm.platform.ui.web.auth.NuxeoAuthenticationFilter.doFilter(NuxeoAuthenticationFilter.java:430)
Problem comes from the fact that the user document model which is created is not used to update the directory entry.
- Is referenced in