syncope-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ilgro...@apache.org
Subject [12/17] syncope git commit: Further refactoring as per SYNCOPE-620
Date Wed, 09 Mar 2016 11:52:48 GMT
http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/outer/TaskTest.java
----------------------------------------------------------------------
diff --git a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/outer/TaskTest.java b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/outer/TaskTest.java
index ae07439..6c00347 100644
--- a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/outer/TaskTest.java
+++ b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/outer/TaskTest.java
@@ -50,7 +50,7 @@ import org.apache.syncope.core.persistence.api.entity.task.TaskExec;
 import org.apache.syncope.core.persistence.api.entity.task.AnyTemplateSyncTask;
 import org.apache.syncope.core.persistence.api.entity.user.User;
 import org.apache.syncope.core.persistence.jpa.AbstractTest;
-import org.apache.syncope.core.provisioning.api.sync.SyncActions;
+import org.apache.syncope.core.provisioning.api.syncpull.SyncActions;
 import org.identityconnectors.framework.common.objects.Attribute;
 import org.identityconnectors.framework.common.objects.AttributeBuilder;
 import org.junit.Test;

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/persistence-jpa/src/test/resources/domains/MasterContent.xml
----------------------------------------------------------------------
diff --git a/core/persistence-jpa/src/test/resources/domains/MasterContent.xml b/core/persistence-jpa/src/test/resources/domains/MasterContent.xml
index 0787b63..02f9529 100644
--- a/core/persistence-jpa/src/test/resources/domains/MasterContent.xml
+++ b/core/persistence-jpa/src/test/resources/domains/MasterContent.xml
@@ -1015,7 +1015,7 @@ under the License.
                        template='{"@class":"org.apache.syncope.common.lib.to.UserTO","creator":null,"creationDate":null,"lastModifier":null,"lastChangeDate":null,"key":0,"type":"USER","realm":null,"status":null,"password":null,"token":null,"tokenExpireTime":null,"username":null,"lastLoginDate":null,"changePwdDate":null,"failedLogins":null,"securityQuestion":null,"securityAnswer":null,"auxClasses":[],"derAttrs":[],"virAttrs":[{"schema":"virtualReadOnly","readonly":true,"values":[""]}],"resources":["resource-ldap"],"roles":[],"dynRoles":[],"relationships":[],"memberships":[],"dynGroups":[],"plainAttrs":[]}'/>
   <AnyTemplateSyncTask id="2" syncTask_id="11" anyType_name="GROUP"
                        template='{"@class":"org.apache.syncope.common.lib.to.GroupTO","creator":null,"creationDate":null,"lastModifier":null,"lastChangeDate":null,"key":0,"type":"GROUP","realm":null,"status":null,"name":null,"userOwner":null,"groupOwner":null,"udynMembershipCond":null,"auxClasses":[],"derAttrs":[],"virAttrs":[],"resources":[],"plainAttrs":[{"schema":"show","readonly":false,"values":["true"]}]}'/>
-  <SyncTask_actionsClassNames SyncTask_id="11" actionClassName="org.apache.syncope.core.provisioning.java.sync.LDAPMembershipSyncActions"/>
+  <SyncTask_actionsClassNames SyncTask_id="11" actionClassName="org.apache.syncope.core.provisioning.java.syncpull.LDAPMembershipSyncActions"/>
   <Task DTYPE="SyncTask" type="SYNCHRONIZATION" id="12" name="VirAttrCache test" resource_name="resource-csv"
         destinationRealm_id="1" performCreate="0" performUpdate="1" performDelete="0" syncStatus="0" syncMode="FULL_RECONCILIATION"
         unmatchingRule="PROVISION" matchingRule="UPDATE" active="1"/>

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/persistence-jpa/src/test/resources/domains/TwoDomain.xml
----------------------------------------------------------------------
diff --git a/core/persistence-jpa/src/test/resources/domains/TwoDomain.xml b/core/persistence-jpa/src/test/resources/domains/TwoDomain.xml
index c7e7a9b..506c068 100644
--- a/core/persistence-jpa/src/test/resources/domains/TwoDomain.xml
+++ b/core/persistence-jpa/src/test/resources/domains/TwoDomain.xml
@@ -28,11 +28,11 @@ under the License.
                            http://www.springframework.org/schema/util
                            http://www.springframework.org/schema/util/spring-util.xsd">
   
-  <bean id="TwoContentXML" class="org.apache.syncope.core.misc.spring.ResourceWithFallbackLoader">
+  <bean id="TwoContentXML" class="org.apache.syncope.core.spring.ResourceWithFallbackLoader">
     <property name="primary" value="file:${content.directory}/domains/TwoContent.xml"/>
     <property name="fallback" value="classpath:domains/TwoContent.xml"/>
   </bean>
-  <bean id="TwoProperties" class="org.apache.syncope.core.misc.spring.ResourceWithFallbackLoader">
+  <bean id="TwoProperties" class="org.apache.syncope.core.spring.ResourceWithFallbackLoader">
     <property name="primary" value="file:${content.directory}/domains/Two.properties"/>
     <property name="fallback" value="classpath:domains/Two.properties"/>
   </bean>

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/persistence-jpa/src/test/resources/persistenceTest.xml
----------------------------------------------------------------------
diff --git a/core/persistence-jpa/src/test/resources/persistenceTest.xml b/core/persistence-jpa/src/test/resources/persistenceTest.xml
index 2874cac..b4d7125 100644
--- a/core/persistence-jpa/src/test/resources/persistenceTest.xml
+++ b/core/persistence-jpa/src/test/resources/persistenceTest.xml
@@ -37,7 +37,7 @@ under the License.
     <property name="ignoreUnresolvablePlaceholders" value="true"/>
   </bean>
   
-  <bean class="org.apache.syncope.core.misc.spring.ApplicationContextProvider"/>
+  <bean class="org.apache.syncope.core.spring.ApplicationContextProvider"/>
 
   <bean id="adminUser" class="java.lang.String">
     <constructor-arg value="${adminUser}"/>
@@ -46,10 +46,9 @@ under the License.
     <constructor-arg value="${anonymousUser}"/>
   </bean>
   
-  <context:component-scan base-package="org.apache.syncope.core.misc.policy"/>
-  <context:component-scan base-package="org.apache.syncope.core.misc.security"/>
+  <context:component-scan base-package="org.apache.syncope.core.spring.security"/>
 
-  <bean class="org.apache.syncope.core.misc.security.DefaultPasswordGenerator"/>
+  <bean class="org.apache.syncope.core.spring.security.DefaultPasswordGenerator"/>
 
   <import resource="persistenceContext.xml"/>
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/pom.xml
----------------------------------------------------------------------
diff --git a/core/pom.xml b/core/pom.xml
index 35a4958..2dd6e3f 100644
--- a/core/pom.xml
+++ b/core/pom.xml
@@ -79,7 +79,7 @@ under the License.
   <modules>
     <module>persistence-api</module>
     <module>persistence-jpa</module>
-    <module>misc</module>
+    <module>spring</module>
     <module>provisioning-api</module>
     <module>provisioning-java</module>
     <module>workflow-api</module>

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/pom.xml
----------------------------------------------------------------------
diff --git a/core/provisioning-api/pom.xml b/core/provisioning-api/pom.xml
index 8bc9432..856a932 100644
--- a/core/provisioning-api/pom.xml
+++ b/core/provisioning-api/pom.xml
@@ -39,6 +39,19 @@ under the License.
 
   <dependencies>
     <dependency>
+      <groupId>com.fasterxml.jackson.core</groupId>
+      <artifactId>jackson-core</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>com.fasterxml.jackson.core</groupId>
+      <artifactId>jackson-databind</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>com.fasterxml.jackson.module</groupId>
+      <artifactId>jackson-module-afterburner</artifactId>
+    </dependency>
+    
+    <dependency>
       <groupId>org.quartz-scheduler</groupId>
       <artifactId>quartz</artifactId>
     </dependency>

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/AuditManager.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/AuditManager.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/AuditManager.java
new file mode 100644
index 0000000..58b0303
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/AuditManager.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api;
+
+import org.apache.syncope.common.lib.types.AuditElements;
+
+public interface AuditManager {
+
+    void audit(
+            AuditElements.EventCategoryType type,
+            String category,
+            String subcategory,
+            String event,
+            AuditElements.Result result,
+            Object before,
+            Object output,
+            Object... input);
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/ConnPoolConfUtils.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/ConnPoolConfUtils.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/ConnPoolConfUtils.java
deleted file mode 100644
index 55216ae..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/ConnPoolConfUtils.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api;
-
-import org.apache.syncope.common.lib.to.ConnPoolConfTO;
-import org.apache.syncope.core.persistence.api.entity.ConnPoolConf;
-import org.identityconnectors.common.pooling.ObjectPoolConfiguration;
-
-public final class ConnPoolConfUtils {
-
-    public static ConnPoolConf getConnPoolConf(final ConnPoolConfTO cpcto, final ConnPoolConf cpc) {
-        ObjectPoolConfiguration opc = new ObjectPoolConfiguration();
-
-        cpc.setMaxIdle(cpcto.getMaxIdle() == null ? opc.getMaxIdle() : cpcto.getMaxIdle());
-        cpc.setMaxObjects(cpcto.getMaxObjects() == null ? opc.getMaxObjects() : cpcto.getMaxObjects());
-        cpc.setMaxWait(cpcto.getMaxWait() == null ? opc.getMaxWait() : cpcto.getMaxWait());
-        cpc.setMinEvictableIdleTimeMillis(cpcto.getMinEvictableIdleTimeMillis() == null
-                ? opc.getMinEvictableIdleTimeMillis() : cpcto.getMinEvictableIdleTimeMillis());
-        cpc.setMinIdle(cpcto.getMinIdle() == null ? opc.getMinIdle() : cpcto.getMinIdle());
-
-        return cpc;
-    }
-
-    public static ObjectPoolConfiguration getObjectPoolConfiguration(final ConnPoolConf cpc) {
-        ObjectPoolConfiguration opc = new ObjectPoolConfiguration();
-        updateObjectPoolConfiguration(opc, cpc);
-        return opc;
-    }
-
-    public static void updateObjectPoolConfiguration(
-            final ObjectPoolConfiguration opc, final ConnPoolConf cpc) {
-
-        if (cpc.getMaxIdle() != null) {
-            opc.setMaxIdle(cpc.getMaxIdle());
-        }
-        if (cpc.getMaxObjects() != null) {
-            opc.setMaxObjects(cpc.getMaxObjects());
-        }
-        if (cpc.getMaxWait() != null) {
-            opc.setMaxWait(cpc.getMaxWait());
-        }
-        if (cpc.getMinEvictableIdleTimeMillis() != null) {
-            opc.setMinEvictableIdleTimeMillis(cpc.getMinEvictableIdleTimeMillis());
-        }
-        if (cpc.getMinIdle() != null) {
-            opc.setMinIdle(cpc.getMinIdle());
-        }
-    }
-
-    private ConnPoolConfUtils() {
-        // empty constructor for static utility class
-    }
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/Connector.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/Connector.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/Connector.java
index 7aed2ca..b637508 100644
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/Connector.java
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/Connector.java
@@ -34,7 +34,7 @@ import org.identityconnectors.framework.common.objects.SyncResultsHandler;
 import org.identityconnectors.framework.common.objects.SyncToken;
 import org.identityconnectors.framework.common.objects.Uid;
 import org.identityconnectors.framework.common.objects.filter.Filter;
-import org.apache.syncope.core.provisioning.api.sync.ReconciliationFilterBuilder;
+import org.apache.syncope.core.provisioning.api.syncpull.ReconciliationFilterBuilder;
 
 /**
  * Entry point for making requests on underlying connector bundles.

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/EntitlementsHolder.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/EntitlementsHolder.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/EntitlementsHolder.java
new file mode 100644
index 0000000..d67362f
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/EntitlementsHolder.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * License); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.apache.syncope.common.lib.types.AnyEntitlement;
+
+public final class EntitlementsHolder {
+
+    private static final Object MONITOR = new Object();
+
+    private static EntitlementsHolder INSTANCE;
+
+    public static EntitlementsHolder getInstance() {
+        synchronized (MONITOR) {
+            if (INSTANCE == null) {
+                INSTANCE = new EntitlementsHolder();
+            }
+        }
+        return INSTANCE;
+    }
+
+    private final Set<String> values = Collections.synchronizedSet(new HashSet<String>());
+
+    private EntitlementsHolder() {
+        // private constructor for singleton
+    }
+
+    public void init(final Collection<String> values) {
+        this.values.addAll(values);
+    }
+
+    public String getFor(final String anyTypeKey, final AnyEntitlement operation) {
+        return anyTypeKey + "_" + operation.name();
+    }
+
+    public void addFor(final String anyType) {
+        for (AnyEntitlement operation : AnyEntitlement.values()) {
+            this.values.add(getFor(anyType, operation));
+        }
+    }
+
+    public void removeFor(final String anyType) {
+        for (AnyEntitlement operation : AnyEntitlement.values()) {
+            this.values.remove(getFor(anyType, operation));
+        }
+    }
+
+    public Set<String> getValues() {
+        return Collections.unmodifiableSet(values);
+    }
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/MappingManager.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/MappingManager.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/MappingManager.java
new file mode 100644
index 0000000..4600f9a
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/MappingManager.java
@@ -0,0 +1,78 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api;
+
+import java.util.List;
+import java.util.Set;
+import org.apache.commons.lang3.tuple.Pair;
+import org.apache.syncope.common.lib.to.AnyTO;
+import org.apache.syncope.core.persistence.api.entity.Any;
+import org.apache.syncope.core.persistence.api.entity.AnyUtils;
+import org.apache.syncope.core.persistence.api.entity.PlainAttrValue;
+import org.apache.syncope.core.persistence.api.entity.resource.MappingItem;
+import org.apache.syncope.core.persistence.api.entity.resource.Provision;
+import org.identityconnectors.framework.common.objects.Attribute;
+
+public interface MappingManager {
+
+    /**
+     * Get connObjectKey internal value.
+     *
+     * @param any any object
+     * @param provision provision information
+     * @return connObjectKey internal value
+     */
+    String getConnObjectKeyValue(Any<?> any, Provision provision);
+
+    /**
+     * Get attribute values for the given {@link MappingItem} and any objects.
+     *
+     * @param provision provision information
+     * @param mappingItem mapping item
+     * @param anys any objects
+     * @return attribute values.
+     */
+    List<PlainAttrValue> getIntValues(Provision provision, MappingItem mappingItem, List<Any<?>> anys);
+
+    /**
+     * Prepare attributes for sending to a connector instance.
+     *
+     * @param any given any object
+     * @param password clear-text password
+     * @param changePwd whether password should be included for propagation attributes or not
+     * @param enable whether any object must be enabled or not
+     * @param provision provision information
+     * @return connObjectLink + prepared attributes
+     */
+    Pair<String, Set<Attribute>> prepareAttrs(
+            Any<?> any, String password, boolean changePwd, Boolean enable, Provision provision);
+
+    /**
+     * Set attribute values, according to the given {@link MappingItem}, to any object from attribute received from
+     * connector.
+     *
+     * @param <T> any object
+     * @param mappingItem mapping item
+     * @param attr attribute received from connector
+     * @param anyTO any object
+     * @param anyUtils any utils
+     */
+    <T extends AnyTO> void setIntValues(MappingItem mappingItem, Attribute attr, T anyTO, AnyUtils anyUtils);
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/URIUtils.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/URIUtils.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/URIUtils.java
deleted file mode 100644
index 91fd0c2..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/URIUtils.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api;
-
-import java.io.File;
-import java.net.MalformedURLException;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.net.URL;
-
-public final class URIUtils {
-
-    private URIUtils() {
-        // empty constructor for static utility class
-    }
-
-    /**
-     * Build a valid URI out of the given location.
-     * Only "file", "connid" and "connids" schemes are allowed.
-     * For "file", invalid characters are handled via intermediate transformation into URL.
-     *
-     * @param location the candidate location for URI
-     * @return valid URI for the given location
-     * @throws MalformedURLException if the intermediate URL is not valid
-     * @throws URISyntaxException if the given location does not correspond to a valid URI
-     */
-    public static URI buildForConnId(final String location) throws MalformedURLException, URISyntaxException {
-        final String candidate = location.trim();
-
-        if (!candidate.startsWith("file:")
-                && !candidate.startsWith("connid:") && !candidate.startsWith("connids:")) {
-
-            throw new IllegalArgumentException(candidate + " is not a valid URI for file or connid(s) schemes");
-        }
-
-        URI uri;
-        if (candidate.startsWith("file:")) {
-            uri = new File(new URL(candidate).getFile()).getAbsoluteFile().toURI();
-        } else {
-            uri = new URI(candidate);
-        }
-
-        return uri;
-    }
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/UserProvisioningManager.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/UserProvisioningManager.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/UserProvisioningManager.java
index 1f9b7ef..cf198fe 100644
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/UserProvisioningManager.java
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/UserProvisioningManager.java
@@ -26,7 +26,7 @@ import org.apache.syncope.common.lib.patch.StatusPatch;
 import org.apache.syncope.common.lib.patch.UserPatch;
 import org.apache.syncope.common.lib.to.PropagationStatus;
 import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.core.provisioning.api.sync.ProvisioningReport;
+import org.apache.syncope.core.provisioning.api.syncpull.ProvisioningReport;
 
 public interface UserProvisioningManager extends ProvisioningManager<UserTO, UserPatch> {
 

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeDeserializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeDeserializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeDeserializer.java
new file mode 100644
index 0000000..5c563c9
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeDeserializer.java
@@ -0,0 +1,83 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonParser;
+import com.fasterxml.jackson.databind.DeserializationContext;
+import com.fasterxml.jackson.databind.JsonDeserializer;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.node.ObjectNode;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.common.security.GuardedString;
+import org.identityconnectors.framework.common.objects.Attribute;
+import org.identityconnectors.framework.common.objects.AttributeBuilder;
+import org.identityconnectors.framework.common.objects.Name;
+import org.identityconnectors.framework.common.objects.Uid;
+
+class AttributeDeserializer extends JsonDeserializer<Attribute> {
+
+    @Override
+    public Attribute deserialize(final JsonParser jp, final DeserializationContext ctx)
+            throws IOException {
+
+        ObjectNode tree = jp.readValueAsTree();
+
+        String name = tree.get("name").asText();
+
+        List<Object> values = new ArrayList<Object>();
+        for (Iterator<JsonNode> itor = tree.get("value").iterator(); itor.hasNext();) {
+            JsonNode node = itor.next();
+            if (node.isNull()) {
+                values.add(null);
+            } else if (node.isObject()) {
+                values.add(((ObjectNode) node).traverse(jp.getCodec()).readValueAs(GuardedString.class));
+            } else if (node.isBoolean()) {
+                values.add(node.asBoolean());
+            } else if (node.isDouble()) {
+                values.add(node.asDouble());
+            } else if (node.isLong()) {
+                values.add(node.asLong());
+            } else if (node.isInt()) {
+                values.add(node.asInt());
+            } else {
+                String text = node.asText();
+                if (text.startsWith(AttributeSerializer.BYTE_ARRAY_PREFIX)
+                        && text.endsWith(AttributeSerializer.BYTE_ARRAY_SUFFIX)) {
+
+                    values.add(Base64.decode(StringUtils.substringBetween(
+                            text, AttributeSerializer.BYTE_ARRAY_PREFIX, AttributeSerializer.BYTE_ARRAY_SUFFIX)));
+                } else {
+                    values.add(text);
+                }
+            }
+        }
+
+        return Uid.NAME.equals(name)
+                ? new Uid(values.isEmpty() || values.get(0) == null ? null : values.get(0).toString())
+                : Name.NAME.equals(name)
+                ? new Name(values.isEmpty() || values.get(0) == null ? null : values.get(0).toString())
+                : AttributeBuilder.build(name, values);
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeSerializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeSerializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeSerializer.java
new file mode 100644
index 0000000..f8b0fbf
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/AttributeSerializer.java
@@ -0,0 +1,73 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonGenerator;
+import com.fasterxml.jackson.databind.JsonSerializer;
+import com.fasterxml.jackson.databind.SerializerProvider;
+import java.io.IOException;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.common.security.GuardedString;
+import org.identityconnectors.framework.common.objects.Attribute;
+
+class AttributeSerializer extends JsonSerializer<Attribute> {
+
+    public static final String BYTE_ARRAY_PREFIX = "<binary>";
+
+    public static final String BYTE_ARRAY_SUFFIX = "</binary>";
+
+    @Override
+    public void serialize(final Attribute source, final JsonGenerator jgen, final SerializerProvider sp)
+            throws IOException {
+
+        jgen.writeStartObject();
+
+        jgen.writeStringField("name", source.getName());
+
+        jgen.writeFieldName("value");
+        if (source.getValue() == null) {
+            jgen.writeNull();
+        } else {
+            jgen.writeStartArray();
+            for (Object value : source.getValue()) {
+                if (value == null) {
+                    jgen.writeNull();
+                } else if (value instanceof GuardedString) {
+                    jgen.writeObject(value);
+                } else if (value instanceof Integer) {
+                    jgen.writeNumber((Integer) value);
+                } else if (value instanceof Long) {
+                    jgen.writeNumber((Long) value);
+                } else if (value instanceof Double) {
+                    jgen.writeNumber((Double) value);
+                } else if (value instanceof Boolean) {
+                    jgen.writeBoolean((Boolean) value);
+                } else if (value instanceof byte[]) {
+                    jgen.writeString(BYTE_ARRAY_PREFIX + Base64.encode((byte[]) value) + BYTE_ARRAY_SUFFIX);
+                } else {
+                    jgen.writeString(value.toString());
+                }
+            }
+            jgen.writeEndArray();
+        }
+
+        jgen.writeEndObject();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringDeserializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringDeserializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringDeserializer.java
new file mode 100644
index 0000000..a75319e
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringDeserializer.java
@@ -0,0 +1,93 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonParser;
+import com.fasterxml.jackson.databind.DeserializationContext;
+import com.fasterxml.jackson.databind.JsonDeserializer;
+import com.fasterxml.jackson.databind.node.ObjectNode;
+import java.io.IOException;
+import java.lang.reflect.Field;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.common.security.EncryptorFactory;
+import org.identityconnectors.common.security.GuardedString;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+class GuardedStringDeserializer extends JsonDeserializer<GuardedString> {
+
+    private static final Logger LOG = LoggerFactory.getLogger(GuardedStringDeserializer.class);
+
+    @Override
+    public GuardedString deserialize(final JsonParser jp, final DeserializationContext ctx)
+            throws IOException {
+
+        ObjectNode tree = jp.readValueAsTree();
+
+        boolean readOnly = false;
+        if (tree.has("readOnly")) {
+            readOnly = tree.get("readOnly").asBoolean();
+        }
+        boolean disposed = false;
+        if (tree.has("disposed")) {
+            disposed = tree.get("disposed").asBoolean();
+        }
+        byte[] encryptedBytes = null;
+        if (tree.has("encryptedBytes")) {
+            encryptedBytes = Base64.decode(tree.get("encryptedBytes").asText());
+        }
+        String base64SHA1Hash = null;
+        if (tree.has("base64SHA1Hash")) {
+            base64SHA1Hash = tree.get("base64SHA1Hash").asText();
+        }
+
+        final byte[] clearBytes = EncryptorFactory.getInstance().getDefaultEncryptor().decrypt(encryptedBytes);
+
+        GuardedString dest = new GuardedString(new String(clearBytes).toCharArray());
+
+        try {
+            Field field = GuardedString.class.getDeclaredField("readOnly");
+            field.setAccessible(true);
+            field.setBoolean(dest, readOnly);
+        } catch (Exception e) {
+            LOG.error("Could not set field value to {}", readOnly, e);
+        }
+
+        try {
+            Field field = GuardedString.class.getDeclaredField("disposed");
+            field.setAccessible(true);
+            field.setBoolean(dest, disposed);
+        } catch (Exception e) {
+            LOG.error("Could not set field value to {}", disposed, e);
+        }
+
+        if (base64SHA1Hash != null) {
+            try {
+                Field field = GuardedString.class.getDeclaredField("base64SHA1Hash");
+                field.setAccessible(true);
+                field.set(dest, base64SHA1Hash);
+            } catch (Exception e) {
+                LOG.error("Could not set field value to {}", base64SHA1Hash, e);
+            }
+        }
+
+        return dest;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringSerializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringSerializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringSerializer.java
new file mode 100644
index 0000000..49cc87d
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/GuardedStringSerializer.java
@@ -0,0 +1,89 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonGenerator;
+import com.fasterxml.jackson.databind.JsonSerializer;
+import com.fasterxml.jackson.databind.SerializerProvider;
+import java.io.IOException;
+import java.lang.reflect.Field;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.common.security.EncryptorFactory;
+import org.identityconnectors.common.security.GuardedString;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+class GuardedStringSerializer extends JsonSerializer<GuardedString> {
+
+    private static final Logger LOG = LoggerFactory.getLogger(GuardedStringSerializer.class);
+
+    @Override
+    public void serialize(final GuardedString source, final JsonGenerator jgen, final SerializerProvider sp)
+            throws IOException {
+
+        jgen.writeStartObject();
+
+        boolean readOnly = false;
+        try {
+            Field field = GuardedString.class.getDeclaredField("readOnly");
+            field.setAccessible(true);
+            readOnly = field.getBoolean(source);
+        } catch (Exception e) {
+            LOG.error("Could not get field value", e);
+        }
+        jgen.writeBooleanField("readOnly", readOnly);
+
+        boolean disposed = false;
+        try {
+            Field field = GuardedString.class.getDeclaredField("disposed");
+            field.setAccessible(true);
+            disposed = field.getBoolean(source);
+        } catch (Exception e) {
+            LOG.error("Could not get field value", e);
+        }
+        jgen.writeBooleanField("disposed", disposed);
+
+        final StringBuilder cleartext = new StringBuilder();
+        source.access(new GuardedString.Accessor() {
+
+            @Override
+            public void access(final char[] clearChars) {
+                cleartext.append(clearChars);
+            }
+        });
+        byte[] encryptedBytes =
+                EncryptorFactory.getInstance().getDefaultEncryptor().encrypt(cleartext.toString().getBytes());
+        jgen.writeStringField("encryptedBytes", Base64.encode(encryptedBytes));
+
+        String base64SHA1Hash = null;
+        try {
+            Field field = GuardedString.class.getDeclaredField("base64SHA1Hash");
+            field.setAccessible(true);
+            base64SHA1Hash = field.get(source).toString();
+        } catch (Exception e) {
+            LOG.error("Could not get field value", e);
+        }
+        if (base64SHA1Hash != null) {
+            jgen.writeStringField("base64SHA1Hash", base64SHA1Hash);
+        }
+
+        jgen.writeEndObject();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/POJOHelper.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/POJOHelper.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/POJOHelper.java
new file mode 100644
index 0000000..25e4316
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/POJOHelper.java
@@ -0,0 +1,80 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.Version;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.module.SimpleModule;
+import com.fasterxml.jackson.module.afterburner.AfterburnerModule;
+import org.identityconnectors.common.security.GuardedString;
+import org.identityconnectors.framework.common.objects.Attribute;
+import org.identityconnectors.framework.common.objects.SyncToken;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Helper class for serialization and deserialization of configuration objects (POJOs) in JSON.
+ */
+public final class POJOHelper {
+
+    private static final Logger LOG = LoggerFactory.getLogger(POJOHelper.class);
+
+    private static final ObjectMapper MAPPER;
+
+    static {
+        SimpleModule pojoModule = new SimpleModule("POJOModule", new Version(1, 0, 0, null, null, null));
+        pojoModule.addSerializer(GuardedString.class, new GuardedStringSerializer());
+        pojoModule.addSerializer(Attribute.class, new AttributeSerializer());
+        pojoModule.addSerializer(SyncToken.class, new SyncTokenSerializer());
+        pojoModule.addDeserializer(GuardedString.class, new GuardedStringDeserializer());
+        pojoModule.addDeserializer(Attribute.class, new AttributeDeserializer());
+        pojoModule.addDeserializer(SyncToken.class, new SyncTokenDeserializer());
+
+        MAPPER = new ObjectMapper();
+        MAPPER.registerModule(pojoModule);
+        MAPPER.registerModule(new AfterburnerModule());
+    }
+
+    public static String serialize(final Object object) {
+        String result = null;
+
+        try {
+            result = MAPPER.writeValueAsString(object);
+        } catch (Exception e) {
+            LOG.error("During serialization", e);
+        }
+
+        return result;
+    }
+
+    public static <T extends Object> T deserialize(final String serialized, final Class<T> reference) {
+        T result = null;
+
+        try {
+            result = MAPPER.readValue(serialized, reference);
+        } catch (Exception e) {
+            LOG.error("During deserialization", e);
+        }
+
+        return result;
+    }
+
+    private POJOHelper() {
+    }
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenDeserializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenDeserializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenDeserializer.java
new file mode 100644
index 0000000..3f8dc4d
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenDeserializer.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonParser;
+import com.fasterxml.jackson.databind.DeserializationContext;
+import com.fasterxml.jackson.databind.JsonDeserializer;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.node.ObjectNode;
+import java.io.IOException;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.framework.common.objects.SyncToken;
+
+class SyncTokenDeserializer extends JsonDeserializer<SyncToken> {
+
+    @Override
+    public SyncToken deserialize(final JsonParser jp, final DeserializationContext ctx)
+            throws IOException {
+
+        ObjectNode tree = jp.readValueAsTree();
+
+        Object value = null;
+        if (tree.has("value")) {
+            JsonNode node = tree.get("value");
+            value = node.isNull()
+                    ? null
+                    : node.isBoolean()
+                            ? node.asBoolean()
+                            : node.isDouble()
+                                    ? node.asDouble()
+                                    : node.isLong()
+                                            ? node.asLong()
+                                            : node.isInt()
+                                                    ? node.asInt()
+                                                    : node.asText();
+
+            if (value instanceof String) {
+                String base64 = (String) value;
+                try {
+                    value = Base64.decode(base64);
+                } catch (RuntimeException e) {
+                    value = base64;
+                }
+            }
+        }
+
+        return new SyncToken(value);
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenSerializer.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenSerializer.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenSerializer.java
new file mode 100644
index 0000000..f9d2ee5
--- /dev/null
+++ b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/serialization/SyncTokenSerializer.java
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.core.provisioning.api.serialization;
+
+import com.fasterxml.jackson.core.JsonGenerator;
+import com.fasterxml.jackson.databind.JsonSerializer;
+import com.fasterxml.jackson.databind.SerializerProvider;
+import java.io.IOException;
+import org.identityconnectors.common.Base64;
+import org.identityconnectors.framework.common.objects.SyncToken;
+
+class SyncTokenSerializer extends JsonSerializer<SyncToken> {
+
+    @Override
+    public void serialize(final SyncToken source, final JsonGenerator jgen, final SerializerProvider sp)
+            throws IOException {
+
+        jgen.writeStartObject();
+
+        jgen.writeFieldName("value");
+
+        if (source.getValue() == null) {
+            jgen.writeNull();
+        } else if (source.getValue() instanceof Boolean) {
+            jgen.writeBoolean((Boolean) source.getValue());
+        } else if (source.getValue() instanceof Double) {
+            jgen.writeNumber((Double) source.getValue());
+        } else if (source.getValue() instanceof Long) {
+            jgen.writeNumber((Long) source.getValue());
+        } else if (source.getValue() instanceof Integer) {
+            jgen.writeNumber((Integer) source.getValue());
+        } else if (source.getValue() instanceof byte[]) {
+            jgen.writeString(Base64.encode((byte[]) source.getValue()));
+        } else {
+            jgen.writeString(source.getValue().toString());
+        }
+
+        jgen.writeEndObject();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectPushResultHandler.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectPushResultHandler.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectPushResultHandler.java
deleted file mode 100644
index 6691db3..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectPushResultHandler.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-public interface AnyObjectPushResultHandler extends SyncopePushResultHandler {
-
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectSyncResultHandler.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectSyncResultHandler.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectSyncResultHandler.java
deleted file mode 100644
index e0ad1d8..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/AnyObjectSyncResultHandler.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-public interface AnyObjectSyncResultHandler extends SyncopeSyncResultHandler {
-
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupPushResultHandler.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupPushResultHandler.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupPushResultHandler.java
deleted file mode 100644
index d22d4e7..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupPushResultHandler.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-public interface GroupPushResultHandler extends SyncopePushResultHandler {
-
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupSyncResultHandler.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupSyncResultHandler.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupSyncResultHandler.java
deleted file mode 100644
index 907c29c..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/GroupSyncResultHandler.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import java.util.Map;
-
-public interface GroupSyncResultHandler extends SyncopeSyncResultHandler {
-
-    Map<Long, String> getGroupOwnerMap();
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/IgnoreProvisionException.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/IgnoreProvisionException.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/IgnoreProvisionException.java
deleted file mode 100644
index 8bc9da5..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/IgnoreProvisionException.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-/**
- * Raised by {@link SyncActions} or {@link PushActions} methods when the given any object is to be ignored for
- * synchronization / push.
- */
-public class IgnoreProvisionException extends RuntimeException {
-
-    private static final long serialVersionUID = -8803817097998786364L;
-
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningActions.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningActions.java
deleted file mode 100644
index 02e6979..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningActions.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import org.quartz.JobExecutionException;
-
-public interface ProvisioningActions {
-
-    /**
-     * Action to be executed before to start the synchronization task execution.
-     *
-     * @param profile sync profile
-     * @throws JobExecutionException in case of generic failure
-     */
-    void beforeAll(final ProvisioningProfile<?, ?> profile) throws JobExecutionException;
-
-    /**
-     * Action to be executed after the synchronization task completion.
-     *
-     * @param profile sync profile
-     * @throws JobExecutionException in case of generic failure
-     */
-    void afterAll(final ProvisioningProfile<?, ?> profile) throws JobExecutionException;
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningProfile.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningProfile.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningProfile.java
deleted file mode 100644
index 2e6e055..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningProfile.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import org.apache.syncope.common.lib.types.ConflictResolutionAction;
-import org.apache.syncope.core.persistence.api.entity.task.ProvisioningTask;
-import org.apache.syncope.core.provisioning.api.Connector;
-
-public class ProvisioningProfile<T extends ProvisioningTask, A extends ProvisioningActions> {
-
-    /**
-     * Syncing connector.
-     */
-    private final Connector connector;
-
-    private final T task;
-
-    private final List<ProvisioningReport> results = new ArrayList<>();
-
-    private boolean dryRun;
-
-    private ConflictResolutionAction resAct;
-
-    private final List<A> actions = new ArrayList<>();
-
-    public ProvisioningProfile(final Connector connector, final T task) {
-        this.connector = connector;
-        this.task = task;
-    }
-
-    public Connector getConnector() {
-        return connector;
-    }
-
-    public T getTask() {
-        return task;
-    }
-
-    public Collection<ProvisioningReport> getResults() {
-        return results;
-    }
-
-    public boolean isDryRun() {
-        return dryRun;
-    }
-
-    public void setDryRun(final boolean dryRun) {
-        this.dryRun = dryRun;
-    }
-
-    public ConflictResolutionAction getResAct() {
-        return resAct;
-    }
-
-    public void setResAct(final ConflictResolutionAction resAct) {
-        this.resAct = resAct;
-    }
-
-    public List<A> getActions() {
-        return actions;
-    }
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningReport.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningReport.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningReport.java
deleted file mode 100644
index 9e3c28a..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ProvisioningReport.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import java.util.Collection;
-
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
-import org.apache.commons.lang3.builder.ToStringStyle;
-import org.apache.syncope.common.lib.types.ResourceOperation;
-import org.apache.syncope.common.lib.types.TraceLevel;
-
-public class ProvisioningReport {
-
-    public enum Status {
-
-        SUCCESS,
-        IGNORE,
-        FAILURE
-
-    }
-
-    private String message;
-
-    private Status status;
-
-    private String anyType;
-
-    private ResourceOperation operation;
-
-    private Long key;
-
-    private String name;
-
-    public String getMessage() {
-        return message;
-    }
-
-    public void setMessage(final String message) {
-        this.message = message;
-    }
-
-    public String getName() {
-        return name;
-    }
-
-    public void setName(final String name) {
-        this.name = name;
-    }
-
-    public Long getKey() {
-        return key;
-    }
-
-    public void setKey(final Long key) {
-        this.key = key;
-    }
-
-    public Status getStatus() {
-        return status;
-    }
-
-    public void setStatus(final Status status) {
-        this.status = status;
-    }
-
-    public String getAnyType() {
-        return anyType;
-    }
-
-    public void setAnyType(final String anyType) {
-        this.anyType = anyType;
-    }
-
-    public ResourceOperation getOperation() {
-        return operation;
-    }
-
-    public void setOperation(final ResourceOperation operation) {
-        this.operation = operation;
-    }
-
-    @Override
-    public String toString() {
-        return new ReflectionToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE).toString();
-    }
-
-    /**
-     * Human readable report string, using the given trace level.
-     *
-     * @param level trace level
-     * @return String for certain levels, null for level NONE
-     */
-    public String getReportString(final TraceLevel level) {
-        if (level == TraceLevel.SUMMARY) {
-            // No per entry log in this case.
-            return null;
-        } else if (level == TraceLevel.FAILURES && status == Status.FAILURE) {
-            // only report failures
-            return String.format("Failed %s (id/name): %d/%s with message: %s", operation, key, name, message);
-        } else {
-            // All
-            return String.format("%s %s (id/name): %d/%s %s", operation, status, key, name,
-                    StringUtils.isBlank(message)
-                            ? ""
-                            : "with message: " + message);
-        }
-    }
-
-    /**
-     * Helper method to invoke logging per synchronization result for the given trace level.
-     *
-     * @param results synchronization result
-     * @param level trace level
-     * @return report as string
-     */
-    public static String produceReport(final Collection<ProvisioningReport> results, final TraceLevel level) {
-        StringBuilder sb = new StringBuilder();
-        for (ProvisioningReport result : results) {
-            sb.append(result.getReportString(level)).append('\n');
-        }
-        return sb.toString();
-    }
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/PushActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/PushActions.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/PushActions.java
deleted file mode 100644
index c6d75ae..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/PushActions.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import org.apache.syncope.core.persistence.api.entity.Any;
-import org.quartz.JobExecutionException;
-
-/**
- * Interface for actions to be performed during push.
- * All methods can throw {@link IgnoreProvisionException} to make the current any ignored by the push process.
- */
-public interface PushActions extends ProvisioningActions {
-
-    /**
-     * Action to be executed before to assign (link &amp; provision) a synchronized any object to the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeAssign(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to provision a synchronized any object to the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeProvision(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to update a synchronized any object on the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be updated.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeUpdate(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to link a synchronized any object to the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeLink(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to unlink a synchronized any object from the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeUnlink(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to unassign a synchronized any object from the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeUnassign(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to unassign a synchronized any object from the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeDeprovision(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before delete a synchronized any object locally and from the resource.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any any object to be created.
-     * @return any.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> A beforeDelete(
-            ProvisioningProfile<?, ?> profile,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed after any object push goes on error.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any synchronized any object.
-     * @param result operation result.
-     * @param error error being reported
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> void onError(
-            ProvisioningProfile<?, ?> profile,
-            A any,
-            ProvisioningReport result,
-            Exception error) throws JobExecutionException;
-
-    /**
-     * Action to be executed after each local any object push.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the push being executed.
-     * @param any synchronized any object.
-     * @param result operation result.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends Any<?>> void after(
-            ProvisioningProfile<?, ?> profile,
-            A any,
-            ProvisioningReport result) throws JobExecutionException;
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ReconciliationFilterBuilder.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ReconciliationFilterBuilder.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ReconciliationFilterBuilder.java
deleted file mode 100644
index 874215b..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/ReconciliationFilterBuilder.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import org.identityconnectors.framework.common.objects.filter.Filter;
-
-/**
- * Interface to be implemented for performing filtered reconciliation of a
- * {@link org.apache.syncope.core.persistence.api.entity.task.SyncTask}.
- */
-public interface ReconciliationFilterBuilder {
-
-    Filter build();
-}

http://git-wip-us.apache.org/repos/asf/syncope/blob/28569df5/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/SyncActions.java
----------------------------------------------------------------------
diff --git a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/SyncActions.java b/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/SyncActions.java
deleted file mode 100644
index 2440a1a..0000000
--- a/core/provisioning-api/src/main/java/org/apache/syncope/core/provisioning/api/sync/SyncActions.java
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.core.provisioning.api.sync;
-
-import org.apache.syncope.common.lib.patch.AnyPatch;
-import org.apache.syncope.common.lib.to.AnyTO;
-import org.identityconnectors.framework.common.objects.SyncDelta;
-import org.quartz.JobExecutionException;
-
-/**
- * Interface for actions to be performed during synchronization.
- * All methods can throw {@link IgnoreProvisionException} to make the current any object ignored by the synchronization
- * process.
- */
-public interface SyncActions extends ProvisioningActions {
-
-    /**
-     * Action to be executed before to create a synchronized user / group locally.
-     * User/group is created locally upon synchronization in case of the un-matching rule
-     * {@link org.apache.syncope.common.lib.types.UnmatchingRule#PROVISION} (default un-matching rule) is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeProvision(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before creating (and linking to the resource) a synchronized user / group locally.
-     * User/group is created locally and linked to the synchronized resource upon synchronization in case of the
-     * un-matching rule {@link org.apache.syncope.common.lib.types.UnmatchingRule#ASSIGN} is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeAssign(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before unlinking resource from the synchronized user / group and de-provisioning.
-     * User/group is unlinked and de-provisioned from the synchronized resource upon synchronization in case of the
-     * matching rule {@link org.apache.syncope.common.lib.types.MatchingRule#UNASSIGN} is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeUnassign(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before de-provisioning action only.
-     * User/group is de-provisioned (without unlinking) from the synchronized resource upon synchronization in case of
-     * the matching rule {@link org.apache.syncope.common.lib.types.MatchingRule#DEPROVISION} is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeDeprovision(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before unlinking resource from the synchronized user / group.
-     * User/group is unlinked (without de-provisioning) from the synchronized resource upon synchronization in case of
-     * the matching rule {@link org.apache.syncope.common.lib.types.MatchingRule#UNLINK} is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeUnlink(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before linking resource to the synchronized user / group.
-     * User/group is linked (without updating) to the synchronized resource upon synchronization in case of
-     * the matching rule {@link org.apache.syncope.common.lib.types.MatchingRule#LINK} is applied.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @return synchronization information used for user status evaluation and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeLink(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed before to update a synchronized user / group locally.
-     * User/group is updated upon synchronization in case of the matching rule
-     * {@link org.apache.syncope.common.lib.types.MatchingRule#UPDATE} (default matching rule) is applied.
-     *
-     * @param <M> concrete any object
-     * @param <P> any object modifications
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object
-     * @param anyPatch modification
-     * @return synchronization information used for logging and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure.
-     */
-    <M extends AnyTO, P extends AnyPatch> SyncDelta beforeUpdate(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            M any,
-            P anyPatch)
-            throws JobExecutionException;
-
-    /**
-     * Action to be executed before to delete a synchronized user / group locally.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information
-     * @param any any object to be deleted
-     * @return synchronization information used for logging and to be passed to the 'after' method.
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> SyncDelta beforeDelete(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any) throws JobExecutionException;
-
-    /**
-     * Action to be executed when user / group synchronization goes on error.
-     *
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information (may be modified by
-     * 'beforeProvision/beforeUpdate/beforeDelete')
-     * @param result global synchronization results at the current synchronization step
-     * @param error error being reported
-     * @throws JobExecutionException in case of generic failure
-     */
-    void onError(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            ProvisioningReport result,
-            Exception error) throws JobExecutionException;
-
-    /**
-     * Action to be executed after each local user / group synchronization.
-     *
-     * @param <A> concrete any object
-     * @param profile profile of the synchronization being executed.
-     * @param delta retrieved synchronization information (may be modified by beforeProvision / beforeUpdate /
-     * beforeDelete)
-     * @param any any object
-     * @param result global synchronization results at the current synchronization step
-     * @throws JobExecutionException in case of generic failure
-     */
-    <A extends AnyTO> void after(
-            ProvisioningProfile<?, ?> profile,
-            SyncDelta delta,
-            A any,
-            ProvisioningReport result) throws JobExecutionException;
-}


Mime
View raw message