public BulkActionResult provision(final String etag, final long userId,
final List<StatusBean> statuses, final boolean changepwd, final String password) {
BulkActionResult result;
synchronized (this) {
UserService service = getService(etag, UserService.class);
final ResourceAssociationMod associationMod = new ResourceAssociationMod();
associationMod.getTargetResources().addAll(
CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
ResourceName.class));
associationMod.setChangePwd(changepwd);
associationMod.setPassword(password);
result = service.bulkAssociation(userId, ResourceAssociationActionType.PROVISION, associationMod).
readEntity(BulkActionResult.class);
resetClient(UserService.class);
}
return result;
}