From 7616b73b746641b89d3b8939d642026ef00ed8b5 Mon Sep 17 00:00:00 2001 From: Boubaker Khanfir Date: Fri, 8 Nov 2024 11:47:09 +0100 Subject: [PATCH] feat: Centralize Cache configuration in Meeds package - MEED-7742 - Meeds-io/meeds#2537 (#667) This change will centralize the Cache configuration into Meeds package to ease its maintainability and evolutivity. In fact, this will allow to override the Meeds caches configurations by one single file override. --- commons-api/pom.xml | 4 - .../commons/utils/RDBMSMigrationUtils.java | 14 --- .../commons-extension/cache-configuration.xml | 98 ------------------- .../webapp/WEB-INF/conf/configuration.xml | 1 - 4 files changed, 117 deletions(-) delete mode 100644 commons-component-common/src/main/java/org/exoplatform/commons/utils/RDBMSMigrationUtils.java delete mode 100644 commons-extension-webapp/src/main/webapp/WEB-INF/conf/commons-extension/cache-configuration.xml diff --git a/commons-api/pom.xml b/commons-api/pom.xml index 0723a0721e..632f8d08ab 100644 --- a/commons-api/pom.xml +++ b/commons-api/pom.xml @@ -82,10 +82,6 @@ commons-beanutils commons-beanutils-core - - xml-apis - xml-apis - diff --git a/commons-component-common/src/main/java/org/exoplatform/commons/utils/RDBMSMigrationUtils.java b/commons-component-common/src/main/java/org/exoplatform/commons/utils/RDBMSMigrationUtils.java deleted file mode 100644 index 64f81dde39..0000000000 --- a/commons-component-common/src/main/java/org/exoplatform/commons/utils/RDBMSMigrationUtils.java +++ /dev/null @@ -1,14 +0,0 @@ -package org.exoplatform.commons.utils; - -import org.jgroups.util.DefaultThreadFactory; - -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; - -public class RDBMSMigrationUtils { - private static ExecutorService executorService = Executors.newSingleThreadExecutor(new DefaultThreadFactory("COMMONS-RDBMS-MIGRATION", false, false));; - - public static ExecutorService getExecutorService() { - return executorService; - } -} diff --git a/commons-extension-webapp/src/main/webapp/WEB-INF/conf/commons-extension/cache-configuration.xml b/commons-extension-webapp/src/main/webapp/WEB-INF/conf/commons-extension/cache-configuration.xml deleted file mode 100644 index e831aa634d..0000000000 --- a/commons-extension-webapp/src/main/webapp/WEB-INF/conf/commons-extension/cache-configuration.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - org.exoplatform.services.cache.CacheService - - addExoCacheConfig - addExoCacheConfig - org.exoplatform.services.cache.ExoCacheConfigPlugin - The Cache configuration for the setting service - - - - commons.WebNotificationCache - The Cache configuration for the Web Notification Cache - - commons.WebNotificationCache - ${exo.cache.commons.WebNotificationCache.strategy:LIRS} - ${exo.cache.commons.WebNotificationCache.TimeToLive:86400} - ${exo.cache.commons.WebNotificationCache.MaxNodes:100000} - ${exo.cache.commons.WebNotificationCache.cacheMode:replication} - - - - - commons.WebNotificationsCache - The Cache configuration for the Web Notification List Cache - - commons.WebNotificationsCache - ${exo.cache.commons.WebNotificationsCache.strategy:LIRS} - ${exo.cache.commons.WebNotificationsCache.TimeToLive:86400} - ${exo.cache.commons.WebNotificationsCache.MaxNodes:1000} - ${exo.cache.commons.WebNotificationsCache.cacheMode:replication} - - - - - commons.WebNotificationCountCache - The Cache configuration for the Web Notification Count Cache - - commons.WebNotificationCountCache - ${exo.cache.commons.WebNotificationCountCache.strategy:LIRS} - ${exo.cache.commons.WebNotificationCountCache.TimeToLive:86400} - ${exo.cache.commons.WebNotificationCountCache.MaxNodes:1000} - ${exo.cache.commons.WebNotificationCountCache.cacheMode:replication} - - - - - commons.UserSettingService - The Cache configuration for the UserSettingService - - commons.UserSettingService - ${exo.cache.commons.UserSettingService.strategy:LIRS} - ${exo.cache.commons.UserSettingService.MaxNodes:500} - ${exo.cache.commons.UserSettingService.TimeToLive:86400} - ${exo.cache.commons.UserSettingService.cacheMode:asyncInvalidation} - - - - - commons.UserStateService - The Cache configuration for the UserStateService - - commons.UserStateService - ${exo.cache.commons.UserStateService.strategy:LIRS} - ${exo.cache.commons.UserStateService.MaxNodes:1000} - ${exo.cache.commons.UserStateService.TimeToLive:86400} - ${exo.cache.commons.UserStateService.cacheMode:replication} - - - - - - - diff --git a/commons-extension-webapp/src/main/webapp/WEB-INF/conf/configuration.xml b/commons-extension-webapp/src/main/webapp/WEB-INF/conf/configuration.xml index c6c8b330cf..11159b46c3 100644 --- a/commons-extension-webapp/src/main/webapp/WEB-INF/conf/configuration.xml +++ b/commons-extension-webapp/src/main/webapp/WEB-INF/conf/configuration.xml @@ -25,7 +25,6 @@ xmlns="http://www.exoplatform.org/xml/ns/kernel_1_2.xsd"> war:/conf/commons-extension/cometd-configuration.xml war:/conf/commons-extension/common-configuration.xml - war:/conf/commons-extension/cache-configuration.xml war:/conf/commons-extension/webui-configuration.xml war:/conf/commons-extension/notification-configuration.xml war:/conf/commons-extension/resource-bundle-configuration.xml