syncope-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fmarte...@apache.org
Subject [31/50] [abbrv] syncope git commit: [SYNCOPE-141][SYNCOPE-142] Implementation completed
Date Fri, 30 Oct 2015 11:35:10 GMT
http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/AnyObjectSyncResultHandlerImpl.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/AnyObjectSyncResultHandlerImpl.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/AnyObjectSyncResultHandlerImpl.java
index 079529d..75703b3 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/AnyObjectSyncResultHandlerImpl.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/AnyObjectSyncResultHandlerImpl.java
@@ -32,7 +32,7 @@ import org.apache.syncope.core.persistence.api.entity.Any;
 import org.apache.syncope.core.persistence.api.entity.AnyUtils;
 import org.apache.syncope.core.provisioning.api.ProvisioningManager;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.apache.syncope.core.provisioning.api.sync.AnyObjectSyncResultHandler;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 
@@ -81,11 +81,11 @@ public class AnyObjectSyncResultHandlerImpl extends AbstractSyncResultHandler im
     }
 
     @Override
-    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningResult result) {
+    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningReport result) {
         AnyObjectTO anyObjectTO = AnyObjectTO.class.cast(anyTO);
 
         Map.Entry<Long, List<PropagationStatus>> created = anyObjectProvisioningManager.create(
-                anyObjectTO, Collections.singleton(profile.getTask().getResource().getKey()));
+                anyObjectTO, Collections.singleton(profile.getTask().getResource().getKey()), true);
 
         result.setKey(created.getKey());
         result.setName(getName(anyTO));
@@ -98,11 +98,12 @@ public class AnyObjectSyncResultHandlerImpl extends AbstractSyncResultHandler im
             final AnyTO before,
             final AnyPatch anyPatch,
             final SyncDelta delta,
-            final ProvisioningResult result) {
+            final ProvisioningReport result) {
 
         AnyObjectPatch anyObjectPatch = AnyObjectPatch.class.cast(anyPatch);
 
-        Map.Entry<Long, List<PropagationStatus>> updated = anyObjectProvisioningManager.update(anyObjectPatch);
+        Map.Entry<Long, List<PropagationStatus>> updated =
+                anyObjectProvisioningManager.update(anyObjectPatch, true);
 
         AnyObjectTO after = anyObjectDataBinder.getAnyObjectTO(updated.getKey());
         result.setName(getName(after));

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DBPasswordSyncActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DBPasswordSyncActions.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DBPasswordSyncActions.java
index 35e50f9..4032b23 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DBPasswordSyncActions.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DBPasswordSyncActions.java
@@ -32,7 +32,7 @@ import org.apache.syncope.core.persistence.api.entity.ConnInstance;
 import org.apache.syncope.core.persistence.api.entity.user.User;
 import org.apache.syncope.core.provisioning.api.Connector;
 import org.apache.syncope.core.provisioning.api.sync.ProvisioningProfile;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 import org.quartz.JobExecutionException;
 import org.slf4j.Logger;
@@ -128,7 +128,7 @@ public class DBPasswordSyncActions extends DefaultSyncActions {
             final ProvisioningProfile<?, ?> profile,
             final SyncDelta delta,
             final A any,
-            final ProvisioningResult result) throws JobExecutionException {
+            final ProvisioningReport result) throws JobExecutionException {
 
         if (any instanceof UserTO && encodedPassword != null && cipher != null) {
             User syncopeUser = userDAO.find(any.getKey());

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultPushActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultPushActions.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultPushActions.java
index 15f06e0..bb75f66 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultPushActions.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultPushActions.java
@@ -21,7 +21,7 @@ package org.apache.syncope.core.provisioning.java.sync;
 import org.apache.syncope.core.persistence.api.entity.Any;
 import org.apache.syncope.core.provisioning.api.sync.PushActions;
 import org.apache.syncope.core.provisioning.api.sync.ProvisioningProfile;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.quartz.JobExecutionException;
 
 /**
@@ -77,7 +77,7 @@ public abstract class DefaultPushActions implements PushActions {
 
     @Override
     public <A extends Any<?, ?>> void onError(
-            final ProvisioningProfile<?, ?> profile, final A any, final ProvisioningResult result,
+            final ProvisioningProfile<?, ?> profile, final A any, final ProvisioningReport result,
             final Exception error) throws JobExecutionException {
 
         // do nothing
@@ -85,7 +85,7 @@ public abstract class DefaultPushActions implements PushActions {
 
     @Override
     public <A extends Any<?, ?>> void after(
-            final ProvisioningProfile<?, ?> profile, final A any, final ProvisioningResult result)
+            final ProvisioningProfile<?, ?> profile, final A any, final ProvisioningReport result)
             throws JobExecutionException {
 
         // do nothing

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultSyncActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultSyncActions.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultSyncActions.java
index 455a799..1612b6d 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultSyncActions.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/DefaultSyncActions.java
@@ -22,7 +22,7 @@ import org.apache.syncope.common.lib.patch.AnyPatch;
 import org.apache.syncope.common.lib.to.AnyTO;
 import org.apache.syncope.core.provisioning.api.sync.SyncActions;
 import org.apache.syncope.core.provisioning.api.sync.ProvisioningProfile;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 import org.quartz.JobExecutionException;
 
@@ -103,14 +103,14 @@ public abstract class DefaultSyncActions implements SyncActions {
 
     @Override
     public void onError(
-            final ProvisioningProfile<?, ?> profile, final SyncDelta delta, final ProvisioningResult result,
+            final ProvisioningProfile<?, ?> profile, final SyncDelta delta, final ProvisioningReport result,
             final Exception error) throws JobExecutionException {
     }
 
     @Override
     public <A extends AnyTO> void after(
             final ProvisioningProfile<?, ?> profile, final SyncDelta delta, final A any,
-            final ProvisioningResult result)
+            final ProvisioningReport result)
             throws JobExecutionException {
     }
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/GroupSyncResultHandlerImpl.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/GroupSyncResultHandlerImpl.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/GroupSyncResultHandlerImpl.java
index c3b9eda..db05ccd 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/GroupSyncResultHandlerImpl.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/GroupSyncResultHandlerImpl.java
@@ -34,7 +34,7 @@ import org.apache.syncope.core.persistence.api.entity.Any;
 import org.apache.syncope.core.persistence.api.entity.AnyUtils;
 import org.apache.syncope.core.provisioning.api.ProvisioningManager;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.apache.syncope.core.provisioning.api.sync.GroupSyncResultHandler;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 
@@ -90,11 +90,14 @@ public class GroupSyncResultHandlerImpl extends AbstractSyncResultHandler implem
     }
 
     @Override
-    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningResult result) {
+    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningReport result) {
         GroupTO groupTO = GroupTO.class.cast(anyTO);
 
         Map.Entry<Long, List<PropagationStatus>> created = groupProvisioningManager.create(
-                groupTO, groupOwnerMap, Collections.singleton(profile.getTask().getResource().getKey()));
+                groupTO,
+                groupOwnerMap,
+                Collections.singleton(profile.getTask().getResource().getKey()),
+                true);
 
         result.setKey(created.getKey());
         result.setName(getName(anyTO));
@@ -107,11 +110,11 @@ public class GroupSyncResultHandlerImpl extends AbstractSyncResultHandler implem
             final AnyTO before,
             final AnyPatch anyPatch,
             final SyncDelta delta,
-            final ProvisioningResult result) {
+            final ProvisioningReport result) {
 
         GroupPatch groupPatch = GroupPatch.class.cast(anyPatch);
 
-        Map.Entry<Long, List<PropagationStatus>> updated = groupProvisioningManager.update(groupPatch);
+        Map.Entry<Long, List<PropagationStatus>> updated = groupProvisioningManager.update(groupPatch, true);
 
         String groupOwner = null;
         for (AttrPatch attrPatch : groupPatch.getPlainAttrs()) {

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPMembershipSyncActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPMembershipSyncActions.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPMembershipSyncActions.java
index 59e8c42..ff81b02 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPMembershipSyncActions.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPMembershipSyncActions.java
@@ -46,7 +46,7 @@ import org.apache.syncope.core.provisioning.api.propagation.PropagationException
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
 import org.apache.syncope.core.provisioning.api.sync.ProvisioningProfile;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.apache.syncope.core.misc.AuditManager;
 import org.apache.syncope.core.persistence.api.dao.AnyTypeDAO;
 import org.apache.syncope.core.persistence.api.dao.UserDAO;
@@ -317,7 +317,7 @@ public class LDAPMembershipSyncActions extends DefaultSyncActions {
             final ProvisioningProfile<?, ?> profile,
             final SyncDelta delta,
             final A any,
-            final ProvisioningResult result) throws JobExecutionException {
+            final ProvisioningReport result) throws JobExecutionException {
 
         if (!(profile.getTask() instanceof SyncTask)) {
             return;

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPPasswordSyncActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPPasswordSyncActions.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPPasswordSyncActions.java
index c58537e..3f08704 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPPasswordSyncActions.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/LDAPPasswordSyncActions.java
@@ -27,7 +27,7 @@ import org.apache.syncope.common.lib.types.CipherAlgorithm;
 import org.apache.syncope.core.persistence.api.dao.UserDAO;
 import org.apache.syncope.core.persistence.api.entity.user.User;
 import org.apache.syncope.core.provisioning.api.sync.ProvisioningProfile;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 import org.quartz.JobExecutionException;
 import org.slf4j.Logger;
@@ -106,7 +106,7 @@ public class LDAPPasswordSyncActions extends DefaultSyncActions {
             final ProvisioningProfile<?, ?> profile,
             final SyncDelta delta,
             final A any,
-            final ProvisioningResult result) throws JobExecutionException {
+            final ProvisioningReport result) throws JobExecutionException {
 
         if (any instanceof UserTO && encodedPassword != null && cipher != null) {
             User syncopeUser = userDAO.find(any.getKey());

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/PlainAttrsSyncCorrelationRule.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/PlainAttrsSyncCorrelationRule.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/PlainAttrsSyncCorrelationRule.java
index 34fde4d..14ba28e 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/PlainAttrsSyncCorrelationRule.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/PlainAttrsSyncCorrelationRule.java
@@ -18,8 +18,6 @@
  */
 package org.apache.syncope.core.provisioning.java.sync;
 
-import static org.apache.syncope.core.misc.utils.MappingUtils.getMappingItemTransformers;
-
 import java.util.Arrays;
 import java.util.HashMap;
 import java.util.List;
@@ -66,7 +64,9 @@ public class PlainAttrsSyncCorrelationRule implements SyncCorrelationRule {
             }
 
             List<Object> values = attr.getValue();
-            for (MappingItemTransformer transformer : getMappingItemTransformers(mappingItems.get(schema))) {
+            for (MappingItemTransformer transformer
+                    : MappingUtils.getMappingItemTransformers(mappingItems.get(schema))) {
+
                 values = transformer.beforeSync(values);
             }
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/UserSyncResultHandlerImpl.java
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/UserSyncResultHandlerImpl.java b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/UserSyncResultHandlerImpl.java
index 23e209c..530319e 100644
--- a/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/UserSyncResultHandlerImpl.java
+++ b/core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/sync/UserSyncResultHandlerImpl.java
@@ -32,7 +32,7 @@ import org.apache.syncope.core.persistence.api.entity.Any;
 import org.apache.syncope.core.persistence.api.entity.AnyUtils;
 import org.apache.syncope.core.provisioning.api.ProvisioningManager;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.apache.syncope.core.provisioning.api.sync.UserSyncResultHandler;
 import org.identityconnectors.framework.common.objects.SyncDelta;
 
@@ -83,13 +83,13 @@ public class UserSyncResultHandlerImpl extends AbstractSyncResultHandler impleme
     }
 
     @Override
-    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningResult result) {
+    protected AnyTO doCreate(final AnyTO anyTO, final SyncDelta delta, final ProvisioningReport result) {
         UserTO userTO = UserTO.class.cast(anyTO);
 
         Boolean enabled = syncUtilities.readEnabled(delta.getObject(), profile.getTask());
         Map.Entry<Long, List<PropagationStatus>> created =
                 userProvisioningManager.create(userTO, true, true, enabled,
-                        Collections.singleton(profile.getTask().getResource().getKey()));
+                        Collections.singleton(profile.getTask().getResource().getKey()), true);
 
         result.setKey(created.getKey());
         result.setName(getName(anyTO));
@@ -102,16 +102,17 @@ public class UserSyncResultHandlerImpl extends AbstractSyncResultHandler impleme
             final AnyTO before,
             final AnyPatch anyPatch,
             final SyncDelta delta,
-            final ProvisioningResult result) {
+            final ProvisioningReport result) {
 
         UserPatch userPatch = UserPatch.class.cast(anyPatch);
         Boolean enabled = syncUtilities.readEnabled(delta.getObject(), profile.getTask());
 
         Map.Entry<Long, List<PropagationStatus>> updated = userProvisioningManager.update(
-                userPatch, before.getKey(),
+                userPatch,
                 result,
                 enabled,
-                Collections.singleton(profile.getTask().getResource().getKey()));
+                Collections.singleton(profile.getTask().getResource().getKey()),
+                true);
 
         return getAnyTO(updated.getKey());
     }
@@ -119,8 +120,8 @@ public class UserSyncResultHandlerImpl extends AbstractSyncResultHandler impleme
     @Override
     protected void doDelete(final AnyTypeKind kind, final Long key) {
         try {
-            userProvisioningManager.
-                    delete(key, Collections.<String>singleton(profile.getTask().getResource().getKey()));
+            userProvisioningManager.delete(
+                    key, Collections.<String>singleton(profile.getTask().getResource().getKey()), true);
         } catch (Exception e) {
             // A propagation failure doesn't imply a synchronization failure.
             // The propagation exception status will be reported into the propagation task execution.

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/resources/provisioning.properties
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/resources/provisioning.properties b/core/provisioning-java/src/main/resources/provisioning.properties
index 55f9ead..b7e405d 100644
--- a/core/provisioning-java/src/main/resources/provisioning.properties
+++ b/core/provisioning-java/src/main/resources/provisioning.properties
@@ -15,6 +15,10 @@
 # specific language governing permissions and limitations
 # under the License.
 asyncConnectorFacadeExecutor.poolSize=10
+
+# see http://docs.spring.io/spring/docs/current/spring-framework-reference/html/scheduling.html#scheduling-task-namespace-executor
+propagationTaskExecutorAsyncExecutor.poolSize=5-25
+propagationTaskExecutorAsyncExecutor.queueCapacity=100
 propagationTaskExecutor=org.apache.syncope.core.provisioning.java.propagation.PriorityPropagationTaskExecutor
 
 userProvisioningManager=org.apache.syncope.core.provisioning.java.DefaultUserProvisioningManager

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/provisioning-java/src/main/resources/provisioningContext.xml
----------------------------------------------------------------------
diff --git a/core/provisioning-java/src/main/resources/provisioningContext.xml b/core/provisioning-java/src/main/resources/provisioningContext.xml
index 7fcafc7..333f202 100644
--- a/core/provisioning-java/src/main/resources/provisioningContext.xml
+++ b/core/provisioning-java/src/main/resources/provisioningContext.xml
@@ -32,8 +32,14 @@ under the License.
 
   <!-- Used by AsyncConnectorFacade -->
   <task:annotation-driven executor="AsyncConnectorFacadeExecutor"/>
-  <task:executor id="AsyncConnectorFacadeExecutor" pool-size="${asyncConnectorFacadeExecutor.poolSize}"/>
-  
+  <task:executor id="AsyncConnectorFacadeExecutor"
+                 pool-size="${asyncConnectorFacadeExecutor.poolSize}"/>
+
+  <!-- Used by PriorityPropagationTaskExecutor -->
+  <task:executor id="propagationTaskExecutorAsyncExecutor"
+                 pool-size="${propagationTaskExecutorAsyncExecutor.poolSize}"
+                 queue-capacity="${propagationTaskExecutorAsyncExecutor.queueCapacity}"
+                 rejection-policy="ABORT"/>
   <bean class="${propagationTaskExecutor}"/>
   
   <bean class="${userProvisioningManager}"/>
@@ -60,7 +66,7 @@ under the License.
   </bean>
 
   <bean id="scheduler" class="org.springframework.scheduling.quartz.SchedulerFactoryBean"
-        lazy-init="false" depends-on="quartzDataSourceInit">
+      lazy-init="false" depends-on="quartzDataSourceInit">
     <property name="autoStartup" value="true"/>
     <property name="applicationContextSchedulerContextKey" value="applicationContext"/>
     <property name="waitForJobsToCompleteOnShutdown" value="true"/>

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/AddETagFilter.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/AddETagFilter.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/AddETagFilter.java
index 31c4d69..1558267 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/AddETagFilter.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/AddETagFilter.java
@@ -27,6 +27,7 @@ import javax.ws.rs.core.HttpHeaders;
 import javax.ws.rs.ext.Provider;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.syncope.common.lib.to.AbstractAnnotatedBean;
+import org.apache.syncope.common.lib.to.ProvisioningResult;
 
 /**
  * Adds the <tt>ETag</tt> header to any response containing an instance of {@link AbstractAnnotatedBean} as entity.
@@ -37,11 +38,18 @@ public class AddETagFilter implements ContainerResponseFilter {
 
     @Override
     public void filter(final ContainerRequestContext reqCtx, final ContainerResponseContext resCtx) throws IOException {
-        if (resCtx.getEntity() instanceof AbstractAnnotatedBean && resCtx.getEntityTag() == null) {
-            AbstractAnnotatedBean sysInfo = (AbstractAnnotatedBean) resCtx.getEntity();
-            String etagValue = sysInfo.getETagValue();
-            if (StringUtils.isNotBlank(etagValue)) {
-                resCtx.getHeaders().add(HttpHeaders.ETAG, new EntityTag(etagValue).toString());
+        if (resCtx.getEntityTag() == null) {
+            AbstractAnnotatedBean annotated = null;
+            if (resCtx.getEntity() instanceof AbstractAnnotatedBean) {
+                annotated = (AbstractAnnotatedBean) resCtx.getEntity();
+            } else if (resCtx.getEntity() instanceof ProvisioningResult) {
+                annotated = ((ProvisioningResult<?>) resCtx.getEntity()).getAny();
+            }
+            if (annotated != null) {
+                String etagValue = annotated.getETagValue();
+                if (StringUtils.isNotBlank(etagValue)) {
+                    resCtx.getHeaders().add(HttpHeaders.ETAG, new EntityTag(etagValue).toString());
+                }
             }
         }
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractAnyService.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractAnyService.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractAnyService.java
index 4258e64..97f2876 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractAnyService.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractAnyService.java
@@ -36,6 +36,7 @@ import org.apache.syncope.common.lib.to.BulkAction;
 import org.apache.syncope.common.lib.to.BulkActionResult;
 import org.apache.syncope.common.lib.to.PagedResult;
 import org.apache.syncope.common.lib.to.PropagationStatus;
+import org.apache.syncope.common.lib.to.ProvisioningResult;
 import org.apache.syncope.common.lib.types.PatchOperation;
 import org.apache.syncope.common.lib.types.ResourceAssociationAction;
 import org.apache.syncope.common.lib.types.ResourceDeassociationAction;
@@ -156,8 +157,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
     @Override
     public Response create(final TO anyTO) {
-        TO created = getAnyLogic().create(anyTO);
-        return createResponse(created.getKey(), created);
+        ProvisioningResult<TO> created = getAnyLogic().create(anyTO, isNullPriorityAsync());
+        return createResponse(created);
     }
 
     @Override
@@ -166,7 +167,7 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
         checkETag(any.getETagValue());
 
-        TO updated = getAnyLogic().update(anyPatch);
+        ProvisioningResult<TO> updated = getAnyLogic().update(anyPatch, isNullPriorityAsync());
         return modificationResponse(updated);
     }
 
@@ -197,7 +198,6 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
     }
 
     @Override
-    @SuppressWarnings("unchecked")
     public Response update(final Long key, final SchemaType schemaType, final AttrTO attrTO) {
         addUpdateOrReplaceAttr(key, schemaType, attrTO, PatchOperation.ADD_REPLACE);
         return modificationResponse(read(key, schemaType, attrTO.getSchema()));
@@ -209,8 +209,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
         checkETag(before.getETagValue());
 
-        @SuppressWarnings("unchecked")
-        TO updated = getAnyLogic().update((P) AnyOperations.diff(anyTO, before, false));
+        ProvisioningResult<TO> updated =
+                getAnyLogic().update(AnyOperations.<TO, P>diff(anyTO, before, false), isNullPriorityAsync());
         return modificationResponse(updated);
     }
 
@@ -225,7 +225,7 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
         checkETag(group.getETagValue());
 
-        TO deleted = getAnyLogic().delete(key);
+        ProvisioningResult<TO> deleted = getAnyLogic().delete(key, isNullPriorityAsync());
         return modificationResponse(deleted);
     }
 
@@ -235,22 +235,24 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
         checkETag(any.getETagValue());
 
-        TO updated;
+        ProvisioningResult<TO> updated;
         switch (patch.getAction()) {
             case UNLINK:
-                updated = getAnyLogic().unlink(patch.getKey(), patch.getResources());
+                updated = new ProvisioningResult<>();
+                updated.setAny(getAnyLogic().unlink(patch.getKey(), patch.getResources()));
                 break;
 
             case UNASSIGN:
-                updated = getAnyLogic().unassign(patch.getKey(), patch.getResources());
+                updated = getAnyLogic().unassign(patch.getKey(), patch.getResources(), isNullPriorityAsync());
                 break;
 
             case DEPROVISION:
-                updated = getAnyLogic().deprovision(patch.getKey(), patch.getResources());
+                updated = getAnyLogic().deprovision(patch.getKey(), patch.getResources(), isNullPriorityAsync());
                 break;
 
             default:
-                updated = getAnyLogic().read(patch.getKey());
+                updated = new ProvisioningResult<>();
+                updated.setAny(getAnyLogic().read(patch.getKey()));
         }
 
         BulkActionResult result = new BulkActionResult();
@@ -258,12 +260,12 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
         if (patch.getAction() == ResourceDeassociationAction.UNLINK) {
             for (String resource : patch.getResources()) {
                 result.getResults().put(resource,
-                        updated.getResources().contains(resource)
+                        updated.getAny().getResources().contains(resource)
                                 ? BulkActionResult.Status.FAILURE
                                 : BulkActionResult.Status.SUCCESS);
             }
         } else {
-            for (PropagationStatus propagationStatusTO : updated.getPropagationStatusTOs()) {
+            for (PropagationStatus propagationStatusTO : updated.getPropagationStatuses()) {
                 result.getResults().put(propagationStatusTO.getResource(),
                         BulkActionResult.Status.valueOf(propagationStatusTO.getStatus().toString()));
             }
@@ -278,12 +280,13 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
 
         checkETag(any.getETagValue());
 
-        TO updated;
+        ProvisioningResult<TO> updated;
         switch (patch.getAction()) {
             case LINK:
-                updated = getAnyLogic().link(
+                updated = new ProvisioningResult<>();
+                updated.setAny(getAnyLogic().link(
                         patch.getKey(),
-                        patch.getResources());
+                        patch.getResources()));
                 break;
 
             case ASSIGN:
@@ -291,7 +294,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
                         patch.getKey(),
                         patch.getResources(),
                         patch.getValue() != null,
-                        patch.getValue());
+                        patch.getValue(),
+                        isNullPriorityAsync());
                 break;
 
             case PROVISION:
@@ -299,11 +303,13 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
                         patch.getKey(),
                         patch.getResources(),
                         patch.getValue() != null,
-                        patch.getValue());
+                        patch.getValue(),
+                        isNullPriorityAsync());
                 break;
 
             default:
-                updated = getAnyLogic().read(patch.getKey());
+                updated = new ProvisioningResult<>();
+                updated.setAny(getAnyLogic().read(patch.getKey()));
         }
 
         BulkActionResult result = new BulkActionResult();
@@ -311,12 +317,12 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
         if (patch.getAction() == ResourceAssociationAction.LINK) {
             for (String resource : patch.getResources()) {
                 result.getResults().put(resource,
-                        updated.getResources().contains(resource)
+                        updated.getAny().getResources().contains(resource)
                                 ? BulkActionResult.Status.FAILURE
                                 : BulkActionResult.Status.SUCCESS);
             }
         } else {
-            for (PropagationStatus propagationStatusTO : updated.getPropagationStatusTOs()) {
+            for (PropagationStatus propagationStatusTO : updated.getPropagationStatuses()) {
                 result.getResults().put(propagationStatusTO.getResource(),
                         BulkActionResult.Status.valueOf(propagationStatusTO.getStatus().toString()));
             }
@@ -336,7 +342,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
                 for (String key : bulkAction.getTargets()) {
                     try {
                         result.getResults().put(
-                                String.valueOf(logic.delete(Long.valueOf(key)).getKey()),
+                                String.valueOf(logic.delete(Long.valueOf(key), isNullPriorityAsync()).
+                                        getAny().getKey()),
                                 BulkActionResult.Status.SUCCESS);
                     } catch (Exception e) {
                         LOG.error("Error performing delete for user {}", key, e);
@@ -353,7 +360,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
                         statusPatch.setType(StatusPatchType.SUSPEND);
                         try {
                             result.getResults().put(
-                                    String.valueOf(((UserLogic) logic).status(statusPatch).getKey()),
+                                    String.valueOf(((UserLogic) logic).
+                                            status(statusPatch, isNullPriorityAsync()).getAny().getKey()),
                                     BulkActionResult.Status.SUCCESS);
                         } catch (Exception e) {
                             LOG.error("Error performing suspend for user {}", key, e);
@@ -370,7 +378,8 @@ public abstract class AbstractAnyService<TO extends AnyTO, P extends AnyPatch>
                     statusPatch.setType(StatusPatchType.REACTIVATE);
                     try {
                         result.getResults().put(
-                                String.valueOf(((UserLogic) logic).status(statusPatch).getKey()),
+                                String.valueOf(((UserLogic) logic).
+                                        status(statusPatch, isNullPriorityAsync()).getAny().getKey()),
                                 BulkActionResult.Status.SUCCESS);
                     } catch (Exception e) {
                         LOG.error("Error performing reactivate for user {}", key, e);

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractServiceImpl.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractServiceImpl.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractServiceImpl.java
index 9265bcb..85f035f 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractServiceImpl.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/AbstractServiceImpl.java
@@ -28,6 +28,7 @@ import javax.ws.rs.core.MultivaluedMap;
 import javax.ws.rs.core.Response;
 import javax.ws.rs.core.UriBuilder;
 import javax.ws.rs.core.UriInfo;
+import org.apache.commons.lang3.BooleanUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.cxf.jaxrs.ext.MessageContext;
 import org.apache.cxf.jaxrs.ext.search.SearchBean;
@@ -36,6 +37,7 @@ import org.apache.cxf.jaxrs.ext.search.SearchContext;
 import org.apache.syncope.common.lib.AbstractBaseBean;
 import org.apache.syncope.common.lib.SyncopeClientException;
 import org.apache.syncope.common.lib.to.PagedResult;
+import org.apache.syncope.common.lib.to.ProvisioningResult;
 import org.apache.syncope.common.lib.types.ClientExceptionType;
 import org.apache.syncope.common.rest.api.service.JAXRSService;
 import org.apache.syncope.common.rest.api.Preference;
@@ -61,27 +63,31 @@ abstract class AbstractServiceImpl implements JAXRSService {
     @Context
     protected SearchContext searchContext;
 
+    protected boolean isNullPriorityAsync() {
+        return BooleanUtils.toBoolean(messageContext.getHttpHeaders().getHeaderString(RESTHeaders.NULL_PRIORITY_ASYNC));
+    }
+
     /**
-     * Reads <tt>Prefer</tt> header from request and parses into a <tt>Preference</tt> instance.
+     * Reads {@code Prefer} header from request and parses into a {@code Preference} instance.
      *
-     * @return a <tt>Preference</tt> instance matching the passed <tt>Prefer</tt> header,
-     * or <tt>Preference.NONE</tt> if missing.
+     * @return a {@code Preference} instance matching the passed {@code Prefer} header,
+     * or {@code Preference.NONE} if missing.
      */
     protected Preference getPreference() {
         return Preference.fromString(messageContext.getHttpHeaders().getHeaderString(RESTHeaders.PREFER));
     }
 
     /**
-     * Builds response to successful <tt>create</tt> request, taking into account any <tt>Prefer</tt> header.
+     * Builds response to successful {@code create} request, taking into account any {@code Prefer} header.
      *
-     * @param id identifier of the created entity
-     * @param entity the entity just created
-     * @return response to successful <tt>create</tt> request
+     * @param provisioningResult the entity just created
+     * @return response to successful {@code create} request
      */
-    protected Response createResponse(final Object id, final Object entity) {
+    protected Response createResponse(final ProvisioningResult<?> provisioningResult) {
+        String entityId = String.valueOf(provisioningResult.getAny().getKey());
         Response.ResponseBuilder builder = Response.
-                created(uriInfo.getAbsolutePathBuilder().path(String.valueOf(id)).build()).
-                header(RESTHeaders.RESOURCE_KEY, id);
+                created(uriInfo.getAbsolutePathBuilder().path(entityId).build()).
+                header(RESTHeaders.RESOURCE_KEY, entityId);
 
         switch (getPreference()) {
             case RETURN_NO_CONTENT:
@@ -90,7 +96,7 @@ abstract class AbstractServiceImpl implements JAXRSService {
             case RETURN_CONTENT:
             case NONE:
             default:
-                builder = builder.entity(entity);
+                builder = builder.entity(provisioningResult);
                 break;
 
         }
@@ -102,7 +108,7 @@ abstract class AbstractServiceImpl implements JAXRSService {
     }
 
     /**
-     * Builds response to successful modification request, taking into account any <tt>Prefer</tt> header.
+     * Builds response to successful modification request, taking into account any {@code Prefer} header.
      *
      * @param entity the entity just modified
      * @return response to successful modification request

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/ResourceServiceImpl.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/ResourceServiceImpl.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/ResourceServiceImpl.java
index 39dbba9..a7e88d3 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/ResourceServiceImpl.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/ResourceServiceImpl.java
@@ -148,11 +148,11 @@ public class ResourceServiceImpl extends AbstractServiceImpl implements Resource
             try {
                 switch (patch.getAction()) {
                     case DEPROVISION:
-                        associator.deprovision(anyKey, resources);
+                        associator.deprovision(anyKey, resources, isNullPriorityAsync());
                         break;
 
                     case UNASSIGN:
-                        associator.unassign(anyKey, resources);
+                        associator.unassign(anyKey, resources, isNullPriorityAsync());
                         break;
 
                     case UNLINK:

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserSelfServiceImpl.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserSelfServiceImpl.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserSelfServiceImpl.java
index ea69e69..3ccfd82 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserSelfServiceImpl.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserSelfServiceImpl.java
@@ -23,6 +23,7 @@ import org.apache.commons.lang3.tuple.Pair;
 import org.apache.syncope.common.lib.AnyOperations;
 import org.apache.syncope.common.lib.SyncopeClientException;
 import org.apache.syncope.common.lib.patch.UserPatch;
+import org.apache.syncope.common.lib.to.ProvisioningResult;
 import org.apache.syncope.common.lib.to.UserTO;
 import org.apache.syncope.common.lib.types.ClientExceptionType;
 import org.apache.syncope.common.rest.api.RESTHeaders;
@@ -49,8 +50,8 @@ public class UserSelfServiceImpl extends AbstractServiceImpl implements UserSelf
             throw sce;
         }
 
-        UserTO created = logic.selfCreate(userTO, storePassword);
-        return createResponse(created.getKey(), created);
+        ProvisioningResult<UserTO> created = logic.selfCreate(userTO, storePassword, isNullPriorityAsync());
+        return createResponse(created);
     }
 
     @Override
@@ -65,7 +66,7 @@ public class UserSelfServiceImpl extends AbstractServiceImpl implements UserSelf
 
     @Override
     public Response update(final UserPatch patch) {
-        UserTO updated = logic.selfUpdate(patch);
+        ProvisioningResult<UserTO> updated = logic.selfUpdate(patch, isNullPriorityAsync());
         return modificationResponse(updated);
     }
 
@@ -77,13 +78,13 @@ public class UserSelfServiceImpl extends AbstractServiceImpl implements UserSelf
 
     @Override
     public Response delete() {
-        UserTO deleted = logic.selfDelete();
+        ProvisioningResult<UserTO> deleted = logic.selfDelete(isNullPriorityAsync());
         return modificationResponse(deleted);
     }
 
     @Override
     public Response changePassword(final String password) {
-        UserTO updated = logic.changePassword(password);
+        ProvisioningResult<UserTO> updated = logic.changePassword(password, isNullPriorityAsync());
         return modificationResponse(updated);
     }
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserServiceImpl.java
----------------------------------------------------------------------
diff --git a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserServiceImpl.java b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserServiceImpl.java
index 7be0f29..0f62925 100644
--- a/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserServiceImpl.java
+++ b/core/rest-cxf/src/main/java/org/apache/syncope/core/rest/cxf/service/UserServiceImpl.java
@@ -22,6 +22,7 @@ import javax.ws.rs.core.HttpHeaders;
 import javax.ws.rs.core.Response;
 import org.apache.syncope.common.lib.patch.StatusPatch;
 import org.apache.syncope.common.lib.patch.UserPatch;
+import org.apache.syncope.common.lib.to.ProvisioningResult;
 import org.apache.syncope.common.lib.to.UserTO;
 import org.apache.syncope.common.rest.api.RESTHeaders;
 import org.apache.syncope.common.rest.api.service.UserService;
@@ -64,8 +65,8 @@ public class UserServiceImpl extends AbstractAnyService<UserTO, UserPatch> imple
 
     @Override
     public Response create(final UserTO userTO, final boolean storePassword) {
-        UserTO created = logic.create(userTO, storePassword);
-        return createResponse(created.getKey(), created);
+        ProvisioningResult<UserTO> created = logic.create(userTO, storePassword, isNullPriorityAsync());
+        return createResponse(created);
     }
 
     @Override
@@ -74,7 +75,7 @@ public class UserServiceImpl extends AbstractAnyService<UserTO, UserPatch> imple
 
         checkETag(user.getETagValue());
 
-        UserTO updated = logic.status(statusPatch);
+        ProvisioningResult<UserTO> updated = logic.status(statusPatch, isNullPriorityAsync());
         return modificationResponse(updated);
     }
 }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelAnyObjectProvisioningManager.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelAnyObjectProvisioningManager.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelAnyObjectProvisioningManager.java
index 4ba890a..3e2f9f8 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelAnyObjectProvisioningManager.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelAnyObjectProvisioningManager.java
@@ -36,19 +36,20 @@ public class CamelAnyObjectProvisioningManager
         extends AbstractCamelProvisioningManager implements AnyObjectProvisioningManager {
 
     @Override
-    public Pair<Long, List<PropagationStatus>> create(final AnyObjectTO any) {
-        return create(any, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> create(final AnyObjectTO any, final boolean nullPriorityAsync) {
+        return create(any, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
     public Pair<Long, List<PropagationStatus>> create(
-            final AnyObjectTO anyObjectTO, final Set<String> excludedResources) {
+            final AnyObjectTO anyObjectTO, final Set<String> excludedResources, final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:createAnyObjectPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:createAnyObject", anyObjectTO, props);
 
@@ -62,19 +63,20 @@ public class CamelAnyObjectProvisioningManager
     }
 
     @Override
-    public Pair<Long, List<PropagationStatus>> update(final AnyObjectPatch anyPatch) {
-        return update(anyPatch, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> update(final AnyObjectPatch anyPatch, final boolean nullPriorityAsync) {
+        return update(anyPatch, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
     public Pair<Long, List<PropagationStatus>> update(
-            final AnyObjectPatch anyPatch, final Set<String> excludedResources) {
+            final AnyObjectPatch anyPatch, final Set<String> excludedResources, final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:updateAnyObjectPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:updateAnyObject", anyPatch, props);
 
@@ -88,19 +90,22 @@ public class CamelAnyObjectProvisioningManager
     }
 
     @Override
-    public List<PropagationStatus> delete(final Long anyObjectObjectKey) {
-        return delete(anyObjectObjectKey, Collections.<String>emptySet());
+    public List<PropagationStatus> delete(final Long anyObjectObjectKey, final boolean nullPriorityAsync) {
+        return delete(anyObjectObjectKey, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> delete(final Long anyObjectKey, final Set<String> excludedResources) {
+    public List<PropagationStatus> delete(
+            final Long key, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deleteAnyObjectPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
-        sendMessage("direct:deleteAnyObject", anyObjectKey, props);
+        sendMessage("direct:deleteAnyObject", key, props);
 
         Exchange exchange = pollingConsumer.receive();
 
@@ -143,11 +148,14 @@ public class CamelAnyObjectProvisioningManager
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> provision(final Long key, final Collection<String> resources) {
+    public List<PropagationStatus> provision(
+            final Long key, final Collection<String> resources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:provisionAnyObjectPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:provisionAnyObject", key, props);
 
@@ -162,13 +170,16 @@ public class CamelAnyObjectProvisioningManager
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> deprovision(final Long anyObjectKey, final Collection<String> resources) {
+    public List<PropagationStatus> deprovision(
+            final Long key, final Collection<String> resources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deprovisionAnyObjectPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
-        sendMessage("direct:deprovisionAnyObject", anyObjectKey, props);
+        sendMessage("direct:deprovisionAnyObject", key, props);
 
         Exchange exchange = pollingConsumer.receive();
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelGroupProvisioningManager.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelGroupProvisioningManager.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelGroupProvisioningManager.java
index ea022bb..7cdf9d1 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelGroupProvisioningManager.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelGroupProvisioningManager.java
@@ -36,17 +36,20 @@ public class CamelGroupProvisioningManager
         extends AbstractCamelProvisioningManager implements GroupProvisioningManager {
 
     @Override
-    public Pair<Long, List<PropagationStatus>> create(final GroupTO any) {
-        return create(any, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> create(final GroupTO any, final boolean nullPriorityAsync) {
+        return create(any, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> create(final GroupTO groupTO, final Set<String> excludedResources) {
+    public Pair<Long, List<PropagationStatus>> create(
+            final GroupTO groupTO, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:createGroupPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:createGroup", groupTO, props);
 
@@ -61,14 +64,18 @@ public class CamelGroupProvisioningManager
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> create(final GroupTO groupTO, final Map<Long, String> groupOwnerMap,
-            final Set<String> excludedResources) {
+    public Pair<Long, List<PropagationStatus>> create(
+            final GroupTO groupTO,
+            final Map<Long, String> groupOwnerMap,
+            final Set<String> excludedResources,
+            final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:createGroupInSyncPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("groupOwnerMap", groupOwnerMap);
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:createGroupInSync", groupTO, props);
 
@@ -82,19 +89,20 @@ public class CamelGroupProvisioningManager
     }
 
     @Override
-    public Pair<Long, List<PropagationStatus>> update(final GroupPatch anyPatch) {
-        return update(anyPatch, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> update(final GroupPatch anyPatch, final boolean nullPriorityAsync) {
+        return update(anyPatch, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
     public Pair<Long, List<PropagationStatus>> update(
-            final GroupPatch anyPatch, final Set<String> excludedResources) {
+            final GroupPatch anyPatch, final Set<String> excludedResources, final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:updateGroupPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:updateGroup", anyPatch, props);
 
@@ -108,19 +116,22 @@ public class CamelGroupProvisioningManager
     }
 
     @Override
-    public List<PropagationStatus> delete(final Long groupObjectKey) {
-        return delete(groupObjectKey, Collections.<String>emptySet());
+    public List<PropagationStatus> delete(final Long key, final boolean nullPriorityAsync) {
+        return delete(key, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> delete(final Long groupKey, final Set<String> excludedResources) {
+    public List<PropagationStatus> delete(
+            final Long key, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deleteGroupPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
-        sendMessage("direct:deleteGroup", groupKey, props);
+        sendMessage("direct:deleteGroup", key, props);
 
         Exchange exchange = pollingConsumer.receive();
 
@@ -163,11 +174,14 @@ public class CamelGroupProvisioningManager
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> provision(final Long key, final Collection<String> resources) {
+    public List<PropagationStatus> provision(
+            final Long key, final Collection<String> resources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:provisionGroupPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:provisionGroup", key, props);
 
@@ -182,11 +196,14 @@ public class CamelGroupProvisioningManager
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> deprovision(final Long key, final Collection<String> resources) {
+    public List<PropagationStatus> deprovision(
+            final Long key, final Collection<String> resources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deprovisionGroupPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:deprovisionGroup", key, props);
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelUserProvisioningManager.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelUserProvisioningManager.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelUserProvisioningManager.java
index 436d80d..1a918a5 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelUserProvisioningManager.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/CamelUserProvisioningManager.java
@@ -36,7 +36,7 @@ import org.apache.syncope.common.lib.to.UserTO;
 import org.apache.syncope.common.lib.types.PropagationByResource;
 import org.apache.syncope.core.provisioning.api.UserProvisioningManager;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningResult;
+import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -45,24 +45,33 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
     private static final Logger LOG = LoggerFactory.getLogger(CamelUserProvisioningManager.class);
 
     @Override
-    public Pair<Long, List<PropagationStatus>> create(final UserTO userTO) {
-        return create(userTO, true, false, null, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> create(final UserTO userTO, final boolean nullPriorityAsync) {
+        return create(userTO, true, false, null, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
-    public Pair<Long, List<PropagationStatus>> create(final UserTO userTO, final boolean storePassword) {
-        return create(userTO, storePassword, false, null, Collections.<String>emptySet());
+    public Pair<Long, List<PropagationStatus>> create(
+            final UserTO userTO, final boolean storePassword, final boolean nullPriorityAsync) {
+
+        return create(userTO, storePassword, false, null, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
-    public Pair<Long, List<PropagationStatus>> create(final UserTO userTO, final Set<String> excludedResources) {
-        return create(userTO, false, false, null, excludedResources);
+    public Pair<Long, List<PropagationStatus>> create(
+            final UserTO userTO, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
+        return create(userTO, false, false, null, excludedResources, nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> create(final UserTO userTO, final boolean storePassword,
-            final boolean disablePwdPolicyCheck, final Boolean enabled, final Set<String> excludedResources) {
+    public Pair<Long, List<PropagationStatus>> create(
+            final UserTO userTO,
+            final boolean storePassword,
+            final boolean disablePwdPolicyCheck,
+            final Boolean enabled,
+            final Set<String> excludedResources,
+            final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:createPort");
 
@@ -71,6 +80,7 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
         props.put("disablePwdPolicyCheck", disablePwdPolicyCheck);
         props.put("enabled", enabled);
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:createUser", userTO, props);
 
@@ -85,10 +95,13 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> update(final UserPatch userPatch) {
+    public Pair<Long, List<PropagationStatus>> update(final UserPatch userPatch, final boolean nullPriorityAsync) {
         PollingConsumer pollingConsumer = getConsumer("direct:updatePort");
 
-        sendMessage("direct:updateUser", userPatch);
+        Map<String, Object> props = new HashMap<>();
+        props.put("nullPriorityAsync", nullPriorityAsync);
+
+        sendMessage("direct:updateUser", userPatch, props);
 
         Exchange exchange = pollingConsumer.receive();
 
@@ -100,24 +113,29 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
     }
 
     @Override
-    public Pair<Long, List<PropagationStatus>> update(final UserPatch anyPatch, final Set<String> excludedResources) {
-        return update(anyPatch, anyPatch.getKey(), new ProvisioningResult(), null, excludedResources);
+    public Pair<Long, List<PropagationStatus>> update(
+            final UserPatch anyPatch, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
+        return update(anyPatch, new ProvisioningReport(), null, excludedResources, nullPriorityAsync);
     }
 
     @Override
-    public List<PropagationStatus> delete(final Long userKey) {
-        return delete(userKey, Collections.<String>emptySet());
+    public List<PropagationStatus> delete(final Long key, final boolean nullPriorityAsync) {
+        return delete(key, Collections.<String>emptySet(), nullPriorityAsync);
     }
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> delete(final Long userKey, final Set<String> excludedResources) {
+    public List<PropagationStatus> delete(
+            final Long key, final Set<String> excludedResources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deletePort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
-        sendMessage("direct:deleteUser", userKey, props);
+        sendMessage("direct:deleteUser", key, props);
 
         Exchange exchange = pollingConsumer.receive();
 
@@ -146,13 +164,16 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> activate(final StatusPatch statusPatch) {
+    public Pair<Long, List<PropagationStatus>> activate(
+            final StatusPatch statusPatch, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:statusPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("token", statusPatch.getToken());
-        props.put("userKey", statusPatch.getKey());
+        props.put("key", statusPatch.getKey());
         props.put("statusPatch", statusPatch);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         if (statusPatch.isOnSyncope()) {
             sendMessage("direct:activateUser", statusPatch.getKey(), props);
@@ -173,12 +194,15 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> reactivate(final StatusPatch statusPatch) {
+    public Pair<Long, List<PropagationStatus>> reactivate(
+            final StatusPatch statusPatch, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:statusPort");
 
         Map<String, Object> props = new HashMap<>();
-        props.put("userKey", statusPatch.getKey());
+        props.put("key", statusPatch.getKey());
         props.put("statusPatch", statusPatch);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         if (statusPatch.isOnSyncope()) {
             sendMessage("direct:reactivateUser", statusPatch.getKey(), props);
@@ -199,12 +223,15 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
     @Override
     @SuppressWarnings("unchecked")
-    public Pair<Long, List<PropagationStatus>> suspend(final StatusPatch statusPatch) {
+    public Pair<Long, List<PropagationStatus>> suspend(
+            final StatusPatch statusPatch, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:statusPort");
 
         Map<String, Object> props = new HashMap<>();
-        props.put("userKey", statusPatch.getKey());
+        props.put("key", statusPatch.getKey());
         props.put("statusPatch", statusPatch);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         if (statusPatch.isOnSyncope()) {
             sendMessage("direct:suspendUser", statusPatch.getKey(), props);
@@ -242,7 +269,11 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
     @Override
     @SuppressWarnings("unchecked")
     public List<PropagationStatus> provision(
-            final Long key, final boolean changePwd, final String password, final Collection<String> resources) {
+            final Long key,
+            final boolean changePwd,
+            final String password,
+            final Collection<String> resources,
+            final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:provisionPort");
 
@@ -251,6 +282,7 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
         props.put("changePwd", changePwd);
         props.put("password", password);
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:provisionUser", key, props);
 
@@ -265,11 +297,14 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
     @Override
     @SuppressWarnings("unchecked")
-    public List<PropagationStatus> deprovision(final Long user, final Collection<String> resources) {
+    public List<PropagationStatus> deprovision(
+            final Long user, final Collection<String> resources, final boolean nullPriorityAsync) {
+
         PollingConsumer pollingConsumer = getConsumer("direct:deprovisionPort");
 
         Map<String, Object> props = new HashMap<>();
         props.put("resources", resources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:deprovisionUser", user, props);
 
@@ -285,16 +320,20 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
     @Override
     @SuppressWarnings("unchecked")
     public Pair<Long, List<PropagationStatus>> update(
-            final UserPatch userPatch, final Long key, final ProvisioningResult result,
-            final Boolean enabled, final Set<String> excludedResources) {
+            final UserPatch userPatch,
+            final ProvisioningReport result,
+            final Boolean enabled,
+            final Set<String> excludedResources,
+            final boolean nullPriorityAsync) {
 
         PollingConsumer pollingConsumer = getConsumer("direct:updateInSyncPort");
 
         Map<String, Object> props = new HashMap<>();
-        props.put("userKey", key);
+        props.put("key", userPatch.getKey());
         props.put("result", result);
         props.put("enabled", enabled);
         props.put("excludedResources", excludedResources);
+        props.put("nullPriorityAsync", nullPriorityAsync);
 
         sendMessage("direct:updateUserInSync", userPatch, props);
 
@@ -302,9 +341,10 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
 
         Exception ex = (Exception) exchange.getProperty(Exchange.EXCEPTION_CAUGHT);
         if (ex != null) {
-            LOG.error("Update of user {} failed, trying to sync its status anyway (if configured)", key, ex);
+            LOG.error("Update of user {} failed, trying to sync its status anyway (if configured)",
+                    nullPriorityAsync, ex);
 
-            result.setStatus(ProvisioningResult.Status.FAILURE);
+            result.setStatus(ProvisioningReport.Status.FAILURE);
             result.setMessage("Update failed, trying to sync status anyway (if configured)\n" + ex.getMessage());
 
             WorkflowResult<Pair<UserPatch, Boolean>> updated = new WorkflowResult<Pair<UserPatch, Boolean>>(
@@ -331,10 +371,10 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
     }
 
     @Override
-    public void requestPasswordReset(final Long userKey) {
+    public void requestPasswordReset(final Long key) {
         PollingConsumer pollingConsumer = getConsumer("direct:requestPwdResetPort");
 
-        sendMessage("direct:requestPwdReset", userKey);
+        sendMessage("direct:requestPwdReset", key);
 
         Exchange exchange = pollingConsumer.receive();
 
@@ -348,7 +388,7 @@ public class CamelUserProvisioningManager extends AbstractCamelProvisioningManag
         PollingConsumer pollingConsumer = getConsumer("direct:confirmPwdResetPort");
 
         Map<String, Object> props = new HashMap<>();
-        props.put("userKey", key);
+        props.put("key", key);
         props.put("token", token);
         props.put("password", password);
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectCreateProcessor.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectCreateProcessor.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectCreateProcessor.java
index 1013d07..443e6aa 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectCreateProcessor.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectCreateProcessor.java
@@ -28,20 +28,15 @@ import org.apache.syncope.common.lib.types.AnyTypeKind;
 import org.apache.syncope.core.misc.spring.ApplicationContextProvider;
 import org.apache.syncope.core.persistence.api.entity.task.PropagationTask;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.propagation.PropagationException;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationReporter;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 
 @Component
 public class AnyObjectCreateProcessor implements Processor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(AnyObjectCreateProcessor.class);
-
     @Autowired
     protected PropagationManager propagationManager;
 
@@ -54,6 +49,7 @@ public class AnyObjectCreateProcessor implements Processor {
         WorkflowResult<Long> created = (WorkflowResult) exchange.getIn().getBody();
         AnyObjectTO any = exchange.getProperty("any", AnyObjectTO.class);
         Set<String> excludedResources = exchange.getProperty("excludedResources", Set.class);
+        Boolean nullPriorityAsync = exchange.getProperty("nullPriorityAsync", Boolean.class);
 
         List<PropagationTask> tasks = propagationManager.getCreateTasks(
                 AnyTypeKind.ANY_OBJECT,
@@ -63,12 +59,7 @@ public class AnyObjectCreateProcessor implements Processor {
                 excludedResources);
         PropagationReporter propagationReporter =
                 ApplicationContextProvider.getBeanFactory().getBean(PropagationReporter.class);
-        try {
-            taskExecutor.execute(tasks, propagationReporter);
-        } catch (PropagationException e) {
-            LOG.error("Error propagation primary resource", e);
-            propagationReporter.onPrimaryResourceFailure(tasks);
-        }
+        taskExecutor.execute(tasks, propagationReporter, nullPriorityAsync);
 
         exchange.getOut().setBody(new ImmutablePair<>(created.getResult(), propagationReporter.getStatuses()));
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeleteProcessor.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeleteProcessor.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeleteProcessor.java
index 7826053..189480b 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeleteProcessor.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeleteProcessor.java
@@ -25,21 +25,16 @@ import org.apache.camel.Processor;
 import org.apache.syncope.common.lib.types.AnyTypeKind;
 import org.apache.syncope.core.misc.spring.ApplicationContextProvider;
 import org.apache.syncope.core.persistence.api.entity.task.PropagationTask;
-import org.apache.syncope.core.provisioning.api.propagation.PropagationException;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationReporter;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
 import org.apache.syncope.core.workflow.api.AnyObjectWorkflowAdapter;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 
 @Component
 public class AnyObjectDeleteProcessor implements Processor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(AnyObjectDeleteProcessor.class);
-
     @Autowired
     protected AnyObjectWorkflowAdapter gwfAdapter;
 
@@ -54,6 +49,7 @@ public class AnyObjectDeleteProcessor implements Processor {
         Long key = exchange.getIn().getBody(Long.class);
         @SuppressWarnings("unchecked")
         Set<String> excludedResources = exchange.getProperty("excludedResources", Set.class);
+        Boolean nullPriorityAsync = exchange.getProperty("nullPriorityAsync", Boolean.class);
 
         List<PropagationTask> tasks = propagationManager.getDeleteTasks(
                 AnyTypeKind.ANY_OBJECT,
@@ -62,12 +58,7 @@ public class AnyObjectDeleteProcessor implements Processor {
                 excludedResources);
         PropagationReporter propagationReporter =
                 ApplicationContextProvider.getBeanFactory().getBean(PropagationReporter.class);
-        try {
-            taskExecutor.execute(tasks, propagationReporter);
-        } catch (PropagationException e) {
-            LOG.error("Error propagation primary resource", e);
-            propagationReporter.onPrimaryResourceFailure(tasks);
-        }
+        taskExecutor.execute(tasks, propagationReporter, nullPriorityAsync);
 
         exchange.setProperty("statuses", propagationReporter.getStatuses());
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeprovisionProcessor.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeprovisionProcessor.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeprovisionProcessor.java
index f08b578..5a6fe52 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeprovisionProcessor.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectDeprovisionProcessor.java
@@ -28,20 +28,15 @@ import org.apache.syncope.common.lib.types.ResourceOperation;
 import org.apache.syncope.core.misc.spring.ApplicationContextProvider;
 import org.apache.syncope.core.persistence.api.dao.AnyObjectDAO;
 import org.apache.syncope.core.persistence.api.entity.task.PropagationTask;
-import org.apache.syncope.core.provisioning.api.propagation.PropagationException;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationReporter;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 
 @Component
 public class AnyObjectDeprovisionProcessor implements Processor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(UserDeprovisionProcessor.class);
-
     @Autowired
     protected PropagationManager propagationManager;
 
@@ -56,6 +51,7 @@ public class AnyObjectDeprovisionProcessor implements Processor {
     public void process(final Exchange exchange) {
         Long key = exchange.getIn().getBody(Long.class);
         List<String> resources = exchange.getProperty("resources", List.class);
+        Boolean nullPriorityAsync = exchange.getProperty("nullPriorityAsync", Boolean.class);
 
         PropagationByResource propByRes = new PropagationByResource();
         propByRes.addAll(ResourceOperation.DELETE, resources);
@@ -67,12 +63,7 @@ public class AnyObjectDeprovisionProcessor implements Processor {
                 CollectionUtils.removeAll(anyObjectDAO.findAllResourceNames(anyObjectDAO.authFind(key)), resources));
         PropagationReporter propagationReporter =
                 ApplicationContextProvider.getBeanFactory().getBean(PropagationReporter.class);
-        try {
-            taskExecutor.execute(tasks, propagationReporter);
-        } catch (PropagationException e) {
-            LOG.error("Error propagation primary resource", e);
-            propagationReporter.onPrimaryResourceFailure(tasks);
-        }
+        taskExecutor.execute(tasks, propagationReporter, nullPriorityAsync);
 
         exchange.getOut().setBody(propagationReporter.getStatuses());
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectProvisionProcessor.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectProvisionProcessor.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectProvisionProcessor.java
index 8170d34..2a8a318 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectProvisionProcessor.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectProvisionProcessor.java
@@ -26,20 +26,15 @@ import org.apache.syncope.common.lib.types.PropagationByResource;
 import org.apache.syncope.common.lib.types.ResourceOperation;
 import org.apache.syncope.core.misc.spring.ApplicationContextProvider;
 import org.apache.syncope.core.persistence.api.entity.task.PropagationTask;
-import org.apache.syncope.core.provisioning.api.propagation.PropagationException;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationReporter;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 
 @Component
 public class AnyObjectProvisionProcessor implements Processor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(AnyObjectProvisionProcessor.class);
-
     @Autowired
     protected PropagationManager propagationManager;
 
@@ -51,6 +46,7 @@ public class AnyObjectProvisionProcessor implements Processor {
     public void process(final Exchange exchange) {
         Long key = exchange.getIn().getBody(Long.class);
         List<String> resources = exchange.getProperty("resources", List.class);
+        Boolean nullPriorityAsync = exchange.getProperty("nullPriorityAsync", Boolean.class);
 
         PropagationByResource propByRes = new PropagationByResource();
         propByRes.addAll(ResourceOperation.UPDATE, resources);
@@ -65,12 +61,7 @@ public class AnyObjectProvisionProcessor implements Processor {
                 null);
         PropagationReporter propagationReporter =
                 ApplicationContextProvider.getBeanFactory().getBean(PropagationReporter.class);
-        try {
-            taskExecutor.execute(tasks, propagationReporter);
-        } catch (PropagationException e) {
-            LOG.error("Error propagation primary resource", e);
-            propagationReporter.onPrimaryResourceFailure(tasks);
-        }
+        taskExecutor.execute(tasks, propagationReporter, nullPriorityAsync);
 
         exchange.getOut().setBody(propagationReporter.getStatuses());
     }

http://git-wip-us.apache.org/repos/asf/syncope/blob/1b81e33c/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectUpdateProcessor.java
----------------------------------------------------------------------
diff --git a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectUpdateProcessor.java b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectUpdateProcessor.java
index 3f2b690..a33296d 100644
--- a/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectUpdateProcessor.java
+++ b/ext/camel/provisioning-camel/src/main/java/org/apache/syncope/core/provisioning/camel/processor/AnyObjectUpdateProcessor.java
@@ -29,20 +29,15 @@ import org.apache.syncope.core.misc.spring.ApplicationContextProvider;
 import org.apache.syncope.core.persistence.api.entity.task.PropagationTask;
 import org.apache.syncope.core.provisioning.api.VirAttrHandler;
 import org.apache.syncope.core.provisioning.api.WorkflowResult;
-import org.apache.syncope.core.provisioning.api.propagation.PropagationException;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationManager;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationReporter;
 import org.apache.syncope.core.provisioning.api.propagation.PropagationTaskExecutor;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 
 @Component
 public class AnyObjectUpdateProcessor implements Processor {
 
-    private static final Logger LOG = LoggerFactory.getLogger(UserUpdateProcessor.class);
-
     @Autowired
     protected PropagationManager propagationManager;
 
@@ -58,6 +53,7 @@ public class AnyObjectUpdateProcessor implements Processor {
         WorkflowResult<Long> updated = (WorkflowResult) exchange.getIn().getBody();
         AnyObjectPatch anyObjectPatch = exchange.getProperty("anyPatch", AnyObjectPatch.class);
         Set<String> excludedResources = exchange.getProperty("excludedResources", Set.class);
+        Boolean nullPriorityAsync = exchange.getProperty("nullPriorityAsync", Boolean.class);
 
         List<PropagationTask> tasks = propagationManager.getUpdateTasks(
                 AnyTypeKind.ANY_OBJECT,
@@ -69,12 +65,7 @@ public class AnyObjectUpdateProcessor implements Processor {
                 excludedResources);
         PropagationReporter propagationReporter =
                 ApplicationContextProvider.getBeanFactory().getBean(PropagationReporter.class);
-        try {
-            taskExecutor.execute(tasks, propagationReporter);
-        } catch (PropagationException e) {
-            LOG.error("Error propagation primary resource", e);
-            propagationReporter.onPrimaryResourceFailure(tasks);
-        }
+        taskExecutor.execute(tasks, propagationReporter, nullPriorityAsync);
 
         exchange.getOut().setBody(new ImmutablePair<>(updated.getResult(), propagationReporter.getStatuses()));
     }


Mime
View raw message