diff --git a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/inner/ResourceTest.java b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/inner/ResourceTest.java
index 948fd6b9114..61b2f4738ba 100644
--- a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/inner/ResourceTest.java
+++ b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/inner/ResourceTest.java
@@ -66,7 +66,7 @@ public void findById() {
assertEquals("net.tirasa.connid.bundles.soap.WebServiceConnector", connector.getConnectorName());
assertEquals("net.tirasa.connid.bundles.soap", connector.getBundleName());
- Mapping mapping = resource.getProvisionByAnyType(AnyTypeKind.USER.name()).get().getMapping();
+ Mapping mapping = resource.getProvisionByAnyType(AnyTypeKind.USER.name()).orElseThrow().getMapping();
assertFalse(mapping.getItems().isEmpty());
assertTrue(mapping.getItems().stream().
@@ -80,6 +80,12 @@ public void findById() {
}
}
+ @Test
+ public void propagationActions() {
+ ExternalResource resource = resourceDAO.findById("resource-ldap").orElseThrow();
+ assertEquals(2, resource.getPropagationActions().size());
+ }
+
@Test
public void findWithOrgUnit() {
ExternalResource resource = resourceDAO.findById("resource-ldap-orgunit").orElseThrow();
@@ -110,8 +116,8 @@ public void findAll() {
@Test
public void getConnObjectKey() {
ExternalResource resource = resourceDAO.findById("ws-target-resource-2").orElseThrow();
- assertEquals("fullname", resource.getProvisionByAnyType(AnyTypeKind.USER.name()).get().
- getMapping().getConnObjectKeyItem().get().getIntAttrName());
+ assertEquals("fullname", resource.getProvisionByAnyType(AnyTypeKind.USER.name()).orElseThrow().
+ getMapping().getConnObjectKeyItem().orElseThrow().getIntAttrName());
}
@Test
@@ -277,7 +283,8 @@ public void saveWithGroupMappingType() {
entityManager.flush();
assertNotNull(actual);
- assertEquals(3, actual.getProvisionByAnyType(AnyTypeKind.USER.name()).get().getMapping().getItems().size());
+ assertEquals(3, actual.getProvisionByAnyType(AnyTypeKind.USER.name()).orElseThrow().getMapping().getItems().
+ size());
}
@Test
diff --git a/core/persistence-neo4j/pom.xml b/core/persistence-neo4j/pom.xml
index dd4815e8ff6..9860f16f7f3 100644
--- a/core/persistence-neo4j/pom.xml
+++ b/core/persistence-neo4j/pom.xml
@@ -43,12 +43,6 @@ under the License.
org.springframework.boot
spring-boot-starter-data-neo4j
-
-
- org.springframework.data
- spring-data-commons
- 4.0.5
-
org.apache.syncope.core
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AccessPolicyConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AccessPolicyConfConverter.java
new file mode 100644
index 00000000000..487e5060436
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AccessPolicyConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.policy.AccessPolicyConf;
+
+public class AccessPolicyConfConverter extends SerializableConverter {
+
+ public AccessPolicyConfConverter() {
+ super(AccessPolicyConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrListConverter.java
new file mode 100644
index 00000000000..680dd2c4b00
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrListConverter.java
@@ -0,0 +1,47 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Optional;
+import org.apache.syncope.common.lib.Attr;
+import org.apache.syncope.core.provisioning.api.serialization.POJOHelper;
+import org.neo4j.driver.Value;
+import org.neo4j.driver.Values;
+import org.springframework.data.neo4j.core.convert.Neo4jPersistentPropertyConverter;
+import tools.jackson.core.type.TypeReference;
+
+public class AttrListConverter implements Neo4jPersistentPropertyConverter> {
+
+ protected static final TypeReference> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ public Value write(final List source) {
+ return Optional.ofNullable(source).
+ map(POJOHelper::serialize).map(Values::value).orElse(Values.value(List.of()));
+ }
+
+ @Override
+ public List read(final Value source) {
+ return Optional.ofNullable(source).
+ map(data -> POJOHelper.deserialize(source.asString(), TYPEREF)).orElseGet(ArrayList::new);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrReleasePolicyConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrReleasePolicyConfConverter.java
new file mode 100644
index 00000000000..89c58fa475e
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrReleasePolicyConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.policy.AttrReleasePolicyConf;
+
+public class AttrReleasePolicyConfConverter extends SerializableConverter {
+
+ public AttrReleasePolicyConfConverter() {
+ super(AttrReleasePolicyConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrRepoConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrRepoConfConverter.java
new file mode 100644
index 00000000000..fb4094ccb5b
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AttrRepoConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.attr.AttrRepoConf;
+
+public class AttrRepoConfConverter extends SerializableConverter {
+
+ public AttrRepoConfConverter() {
+ super(AttrRepoConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthModuleConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthModuleConfConverter.java
new file mode 100644
index 00000000000..857f3e7c16a
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthModuleConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.auth.AuthModuleConf;
+
+public class AuthModuleConfConverter extends SerializableConverter {
+
+ public AuthModuleConfConverter() {
+ super(AuthModuleConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthPolicyConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthPolicyConfConverter.java
new file mode 100644
index 00000000000..114180278cf
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/AuthPolicyConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.policy.AuthPolicyConf;
+
+public class AuthPolicyConfConverter extends SerializableConverter {
+
+ public AuthPolicyConfConverter() {
+ super(AuthPolicyConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnConfPropertyListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnConfPropertyListConverter.java
new file mode 100644
index 00000000000..b958b3b9f63
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnConfPropertyListConverter.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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import tools.jackson.core.type.TypeReference;
+
+public class ConnConfPropertyListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnPoolConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnPoolConfConverter.java
new file mode 100644
index 00000000000..578369d645c
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnPoolConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.types.ConnPoolConf;
+
+public class ConnPoolConfConverter extends SerializableConverter {
+
+ public ConnPoolConfConverter() {
+ super(ConnPoolConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnectorCapabilitySetConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnectorCapabilitySetConverter.java
new file mode 100644
index 00000000000..010ca80816f
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ConnectorCapabilitySetConverter.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.persistence.neo4j.converters;
+
+import java.util.Set;
+import org.apache.syncope.common.lib.types.ConnectorCapability;
+import tools.jackson.core.type.TypeReference;
+
+public class ConnectorCapabilitySetConverter extends SerializableSetConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthAccountListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthAccountListConverter.java
new file mode 100644
index 00000000000..bbb85eff8a0
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthAccountListConverter.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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.wa.GoogleMfaAuthAccount;
+import tools.jackson.core.type.TypeReference;
+
+public class GoogleMfaAuthAccountListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthTokenListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthTokenListConverter.java
new file mode 100644
index 00000000000..9bc30bca6bd
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/GoogleMfaAuthTokenListConverter.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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.wa.GoogleMfaAuthToken;
+import tools.jackson.core.type.TypeReference;
+
+public class GoogleMfaAuthTokenListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ImpersonationAccountListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ImpersonationAccountListConverter.java
new file mode 100644
index 00000000000..c0935b45374
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ImpersonationAccountListConverter.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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.wa.ImpersonationAccount;
+import tools.jackson.core.type.TypeReference;
+
+public class ImpersonationAccountListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ItemListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ItemListConverter.java
new file mode 100644
index 00000000000..050220abb3d
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ItemListConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.Item;
+import tools.jackson.core.type.TypeReference;
+
+public class ItemListConverter extends SerializableListConverter- {
+
+ protected static final TypeReference
> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/Locale2StringMapConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/Locale2StringMapConverter.java
new file mode 100644
index 00000000000..f8d230ba71f
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/Locale2StringMapConverter.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.persistence.neo4j.converters;
+
+import java.util.HashMap;
+import java.util.Locale;
+import tools.jackson.core.type.TypeReference;
+
+public class Locale2StringMapConverter extends SerializableMapConverter {
+
+ protected static final TypeReference> TYPEREF =
+ new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/MfaTrustedDeviceListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/MfaTrustedDeviceListConverter.java
new file mode 100644
index 00000000000..b2fea9227c4
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/MfaTrustedDeviceListConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.wa.MfaTrustedDevice;
+import tools.jackson.core.type.TypeReference;
+
+public class MfaTrustedDeviceListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCGrantTypeSetConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCGrantTypeSetConverter.java
new file mode 100644
index 00000000000..796e152c671
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCGrantTypeSetConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.Set;
+import org.apache.syncope.common.lib.types.OIDCGrantType;
+import tools.jackson.core.type.TypeReference;
+
+public class OIDCGrantTypeSetConverter extends SerializableSetConverter {
+
+ protected static final TypeReference> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCResponseTypeSetConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCResponseTypeSetConverter.java
new file mode 100644
index 00000000000..f666f81168d
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OIDCResponseTypeSetConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.Set;
+import org.apache.syncope.common.lib.types.OIDCResponseType;
+import tools.jackson.core.type.TypeReference;
+
+public class OIDCResponseTypeSetConverter extends SerializableSetConverter {
+
+ protected static final TypeReference> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OrgUnitConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OrgUnitConverter.java
new file mode 100644
index 00000000000..cc0d6adc553
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/OrgUnitConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.to.OrgUnit;
+
+public class OrgUnitConverter extends SerializableConverter {
+
+ public OrgUnitConverter() {
+ super(OrgUnit.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/PasswordManagementConfConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/PasswordManagementConfConverter.java
new file mode 100644
index 00000000000..3ccff8697a8
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/PasswordManagementConfConverter.java
@@ -0,0 +1,28 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import org.apache.syncope.common.lib.password.PasswordManagementConf;
+
+public class PasswordManagementConfConverter extends SerializableConverter {
+
+ public PasswordManagementConfConverter() {
+ super(PasswordManagementConf.class);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ProvisionListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ProvisionListConverter.java
new file mode 100644
index 00000000000..e08b47521b7
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/ProvisionListConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.Provision;
+import tools.jackson.core.type.TypeReference;
+
+public class ProvisionListConverter extends SerializableListConverter {
+
+ protected static final TypeReference> TYPEREF = new TypeReference>() {
+ };
+
+ @Override
+ protected TypeReference> typeRef() {
+ return TYPEREF;
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableConverter.java
new file mode 100644
index 00000000000..37c92ab2541
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableConverter.java
@@ -0,0 +1,46 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.io.Serializable;
+import java.util.Optional;
+import org.apache.syncope.core.provisioning.api.serialization.POJOHelper;
+import org.neo4j.driver.Value;
+import org.neo4j.driver.Values;
+import org.springframework.data.neo4j.core.convert.Neo4jPersistentPropertyConverter;
+
+abstract class SerializableConverter implements Neo4jPersistentPropertyConverter {
+
+ protected final Class reference;
+
+ protected SerializableConverter(final Class reference) {
+ this.reference = reference;
+ }
+
+ @Override
+ public Value write(final T source) {
+ return Optional.ofNullable(source).map(POJOHelper::serialize).map(Values::value).orElse(Values.NULL);
+ }
+
+ @Override
+ public T read(final Value source) {
+ return Optional.ofNullable(source).
+ map(data -> POJOHelper.deserialize(source.asString(), reference)).orElse(null);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableListConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableListConverter.java
new file mode 100644
index 00000000000..aecfb3359cd
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableListConverter.java
@@ -0,0 +1,46 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Optional;
+import org.apache.syncope.core.provisioning.api.serialization.POJOHelper;
+import org.neo4j.driver.Value;
+import org.neo4j.driver.Values;
+import org.springframework.data.neo4j.core.convert.Neo4jPersistentPropertyConverter;
+import tools.jackson.core.type.TypeReference;
+
+abstract class SerializableListConverter implements Neo4jPersistentPropertyConverter> {
+
+ protected abstract TypeReference> typeRef();
+
+ @Override
+ public Value write(final List source) {
+ return Optional.ofNullable(source).map(POJOHelper::serialize).map(Values::value).
+ orElse(Values.value(List.of()));
+ }
+
+ @Override
+ public List read(final Value source) {
+ return Optional.ofNullable(source).
+ map(data -> POJOHelper.deserialize(source.asString(), typeRef())).orElseGet(ArrayList::new);
+ }
+}
diff --git a/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableMapConverter.java b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableMapConverter.java
new file mode 100644
index 00000000000..f1b1e498021
--- /dev/null
+++ b/core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/converters/SerializableMapConverter.java
@@ -0,0 +1,46 @@
+/*
+ * 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.persistence.neo4j.converters;
+
+import java.io.Serializable;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Optional;
+import org.apache.syncope.core.provisioning.api.serialization.POJOHelper;
+import org.neo4j.driver.Value;
+import org.neo4j.driver.Values;
+import org.springframework.data.neo4j.core.convert.Neo4jPersistentPropertyConverter;
+import tools.jackson.core.type.TypeReference;
+
+abstract class SerializableMapConverter
+ implements Neo4jPersistentPropertyConverter