From 0ee208a38ef097089672d527378a90fcb3a9f7a2 Mon Sep 17 00:00:00 2001 From: dseurotech Date: Tue, 23 Jul 2024 10:53:17 +0200 Subject: [PATCH] :bug: defining the persistence unit in the right place Signed-off-by: dseurotech --- .../main/resources/META-INF/persistence.xml | 17 +++++++++ commons/src/main/resources/persistence.xml | 36 ------------------- ...tionServiceConfigurationManagerModule.java | 2 +- 3 files changed, 18 insertions(+), 37 deletions(-) delete mode 100644 commons/src/main/resources/persistence.xml diff --git a/commons/src/main/resources/META-INF/persistence.xml b/commons/src/main/resources/META-INF/persistence.xml index 812fb433d4f..63487d5e689 100644 --- a/commons/src/main/resources/META-INF/persistence.xml +++ b/commons/src/main/resources/META-INF/persistence.xml @@ -40,4 +40,21 @@ + + + org.eclipse.persistence.jpa.PersistenceProvider + + org.eclipse.kapua.commons.configuration.ServiceConfigImpl + + + org.eclipse.kapua.commons.model.id.KapuaEid + org.eclipse.kapua.commons.model.AbstractKapuaEntity + org.eclipse.kapua.commons.model.AbstractKapuaNamedEntity + org.eclipse.kapua.commons.model.AbstractKapuaUpdatableEntity + + + + + + diff --git a/commons/src/main/resources/persistence.xml b/commons/src/main/resources/persistence.xml deleted file mode 100644 index 14497986862..00000000000 --- a/commons/src/main/resources/persistence.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - org.eclipse.persistence.jpa.PersistenceProvider - - org.eclipse.kapua.commons.configuration.ServiceConfigImpl - - - org.eclipse.kapua.commons.model.id.KapuaEid - org.eclipse.kapua.commons.model.AbstractKapuaEntity - org.eclipse.kapua.commons.model.AbstractKapuaNamedEntity - org.eclipse.kapua.commons.model.AbstractKapuaUpdatableEntity - - - - - - - diff --git a/service/device/registry/internal/src/main/java/org/eclipse/kapua/service/device/registry/DeviceConnectionServiceConfigurationManagerModule.java b/service/device/registry/internal/src/main/java/org/eclipse/kapua/service/device/registry/DeviceConnectionServiceConfigurationManagerModule.java index 57e6cf4815e..76634373fbb 100644 --- a/service/device/registry/internal/src/main/java/org/eclipse/kapua/service/device/registry/DeviceConnectionServiceConfigurationManagerModule.java +++ b/service/device/registry/internal/src/main/java/org/eclipse/kapua/service/device/registry/DeviceConnectionServiceConfigurationManagerModule.java @@ -59,7 +59,7 @@ ServiceConfigurationManager deviceConnectionServiceConfigurationManager( XmlUtil xmlUtil) { return new ServiceConfigurationManagerCachingWrapper( new DeviceConnectionServiceConfigurationManager( - txManagerFactory.create("kapua-datastore"), + txManagerFactory.create("kapua-service-config"), new CachingServiceConfigRepository( new ServiceConfigImplJpaRepository(jpaRepoConfig), entityCacheFactory.createCache("AbstractKapuaConfigurableServiceCacheId")