public void syncUsers ( boolean createUsers , boolean deleteUsers ) { List < String > realmUserNames = externalUsersService . getUserNames ( ) ; if ( LOG . isDebugEnabled ( ) ) { LOG . debug ( "Synchronize for realm=" + realm + " users=" + realmUserNames . size ( ) + " (createUsers = " + createUsers + ", deleteUsers = " + deleteUsers + ")" ) ; } for ( String username : realmUserNames ) { User user = externalUsersService . getUser ( username ) ; applyPatch ( user ) ; if ( createUsers ) { createOrUpdateUser ( user ) ; } else if ( userExists ( user . getUsername ( ) ) ) { updateUser ( user ) ; } List < String > groupNames = externalUsersService . getGroupNames ( username ) ; updateUserGroups ( username , groupNames ) ; } if ( deleteUsers ) { deleteAsyncUsers ( realmUserNames ) ; } }
from NextServerSession doesn t work