}
protected abstract boolean setPropertyExternal(String key, String value);
protected boolean setPropertyInternal(String key, String value) {
JCRUser jcrUser = lookupExternalUser();
if (jcrUser == null) {
// deploy
try {
long timer = System.currentTimeMillis();
JCRStoreService.getInstance().deployExternalUser(this);
JahiaUserManagerService.LOGGER.info(
"Created internal user node for user {} in {} ms", userKey,
(System.currentTimeMillis() - timer));
jcrUser = lookupExternalUser();
} catch (RepositoryException e) {
JahiaUserManagerService.LOGGER.error("Error deploying external user '" + getName()
+ "' for provider '" + getProviderName() + "' into JCR repository. Cause: "
+ e.getMessage(), e);
}
}
return jcrUser != null && jcrUser.setProperty(key, value);
}