Details
Description
Our scenario:
Syncope synchronizes from AD e propagates to an external custom resource (all this process is done by a SyncTask).
If during the user/role propagation, to external resource, an exception is thrown the id will be null in report.
In my opinion, after seeing UserSyncResultHandler.doCreate, the cause could be that
result.setId(created.getResult().getKey());
is placed after
taskExecutor.execute(tasks);
that in my case can throw an RuntimeException.
Example of report with null value:
Users [created/failures]: 6/1 [updated/failures]: 0/0 [deleted/failures]: 0/0 [ignored]: 0 Roles [created/failures]: 5/0 [updated/failures]: 0/0 [deleted/failures]: 0/0 [ignored]: 0 Users failed to create: CREATE FAILURE (id/name): null/utente4 with message: SyncopeClientCompositeException: {[RequiredValuesMissing [surname, email]]} Users created: CREATE SUCCESS (id/name): null/user4me2 CREATE SUCCESS (id/name): null/user4me5 CREATE SUCCESS (id/name): null/user4me8 CREATE SUCCESS (id/name): null/user.4me7 CREATE SUCCESS (id/name): null/user.4me42015012702 CREATE SUCCESS (id/name): null/User4me2015012606 Users updated: Users deleted: Users ignored: Roles created: CREATE SUCCESS (id/name): 250/SyncopeTest CREATE SUCCESS (id/name): null/LDAPSync4Me2 CREATE SUCCESS (id/name): 252/LDAPSync4Me3 CREATE SUCCESS (id/name): null/TestSync4Me1 CREATE SUCCESS (id/name): 254/TestSyncGroup4Me Roles updated: Roles deleted: Roles ignored: