diff --git a/component/api/pom.xml b/component/api/pom.xml
index 495f4c0e5b..9a4c5e532d 100644
--- a/component/api/pom.xml
+++ b/component/api/pom.xml
@@ -57,14 +57,6 @@
io.meeds.kernel
exo.kernel.component.cache
-
- io.meeds.kernel
- exo.kernel.component.command
-
-
- io.meeds.core
- exo.core.component.database
-
io.meeds.core
exo.core.component.organization.api
@@ -198,24 +190,6 @@
org.hibernate.orm
hibernate-core
-
-
- org.slf4j
- slf4j-api
-
-
- org.jboss.spec.javax.transaction
- jboss-transaction-api_1.1_spec
-
-
- org.jboss.logging
- jboss-logging
-
-
- org.javassist
- javassist
-
-
org.liquibase
diff --git a/component/api/src/main/java/org/exoplatform/commons/InitialContextInitializer2.java b/component/api/src/main/java/org/exoplatform/commons/InitialContextInitializer2.java
index e981c6640a..cc91938029 100644
--- a/component/api/src/main/java/org/exoplatform/commons/InitialContextInitializer2.java
+++ b/component/api/src/main/java/org/exoplatform/commons/InitialContextInitializer2.java
@@ -28,6 +28,7 @@
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.services.naming.BindReferencePlugin;
import org.exoplatform.services.naming.InitialContextInitializer;
+import org.exoplatform.services.naming.SimpleContextFactory;
/**
* This code should be moved in the core, for now it is here as it is needed here. It extends the
@@ -42,6 +43,7 @@ public class InitialContextInitializer2 extends InitialContextInitializer implem
public InitialContextInitializer2(InitParams params) throws Exception { // NOSONAR
super(params);
+ System.setProperty("java.naming.factory.initial", SimpleContextFactory.class.getName());
}
@Override
@@ -58,13 +60,4 @@ public void addPlugin(ComponentPlugin plugin) {
}
}
- @Override
- public void start() {
- // Nothing to start
- }
-
- @Override
- public void stop() {
- // Nothing to stop
- }
}
diff --git a/component/common/pom.xml b/component/common/pom.xml
index d9fb882fce..c6880e55cb 100644
--- a/component/common/pom.xml
+++ b/component/common/pom.xml
@@ -52,16 +52,6 @@
lombok
provided
-
-
- io.meeds.kernel
- exo.kernel.component.ext.cache.impl.infinispan.v8
-
- test
-
diff --git a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleListener.java b/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleListener.java
deleted file mode 100644
index eb1102fa64..0000000000
--- a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleListener.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.gatein.common.transaction;
-
-/**
- * Listener for perform some actions at the specified point of JTA transaction lifecycle.
- * Transaction lifecycle needs to be managed through {@link JTAUserTransactionLifecycleService} to have listeners executed.
- *
- * For now, we have shared instance of one registered listener for all transactions, so listener implementations need to be
- * thread-safe
- *
- * @author Marek Posolda
- */
-public interface JTAUserTransactionLifecycleListener {
- /**
- * Callback method to be executed before start of JTA transaction
- */
- void beforeBegin();
-
- /**
- * Callback method to be executed after start of JTA transaction
- */
- void afterBegin();
-}
diff --git a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleService.java b/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleService.java
deleted file mode 100644
index 8365f5ef55..0000000000
--- a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleService.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.gatein.common.transaction;
-
-import javax.transaction.UserTransaction;
-
-
-/**
- * Service provides methods for managing lifecycle of JTA transaction
- *
- * @author Marek Posolda
- */
-public interface JTAUserTransactionLifecycleService {
-
- /**
- * @return instance of UserTransaction
- */
- UserTransaction getUserTransaction();
-
- /**
- * Commit or Rollback JTA transaction according to it's current status
- */
- void finishJTATransaction();
-
- /**
- * Starts JTA transaction if not already started
- */
- void beginJTATransaction();
-
- /**
- * Register listener to perform some operations during transaction lifecycle
- *
- * @param listener to be registered
- */
- void registerListener(JTAUserTransactionLifecycleListener listener);
-}
diff --git a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleServiceImpl.java b/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleServiceImpl.java
deleted file mode 100644
index f73d4a0d55..0000000000
--- a/component/common/src/main/java/org/gatein/common/transaction/JTAUserTransactionLifecycleServiceImpl.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.gatein.common.transaction;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import javax.naming.InitialContext;
-import javax.naming.NamingException;
-import javax.transaction.Status;
-import javax.transaction.UserTransaction;
-
-import org.exoplatform.services.transaction.TransactionService;
-import org.exoplatform.services.log.ExoLogger;
-import org.exoplatform.services.log.Log;
-
-/**
- * Base implementation of {@link JTAUserTransactionLifecycleService} .
- *
- * @author Marek Posolda
- */
-public class JTAUserTransactionLifecycleServiceImpl implements JTAUserTransactionLifecycleService {
- private static final Log log = ExoLogger.getLogger(JTAUserTransactionLifecycleServiceImpl.class);
-
- private UserTransaction userTransaction;
-
- private TransactionService transactionService;
-
- // For now, we have one listener instance for all transactions
- private List listeners = new LinkedList<>();
-
- public JTAUserTransactionLifecycleServiceImpl(TransactionService transactionService) {
- this.transactionService = transactionService;
- }
-
- public JTAUserTransactionLifecycleServiceImpl() {
- }
-
- /**
- * {@inheritDoc}
- */
- public void beginJTATransaction() {
- UserTransaction tx = getUserTransaction();
-
- try {
- if (tx == null) {
- // for test scope, this may happen
- log.debug("UserTransaction is null, ignore transactional behavior");
- } else if (tx.getStatus() == Status.STATUS_NO_TRANSACTION) {
- executeListenersBeforeBegin();
- tx.begin();
- executeListenersAfterBegin();
- } else {
- log.warn("UserTransaction not started as it's in state " + tx.getStatus());
- }
- } catch (Exception e) {
- throw new IllegalStateException("Error when starting transaction", e);
- }
- }
-
- /**
- * {@inheritDoc}
- */
- public void finishJTATransaction() {
- UserTransaction tx = getUserTransaction();
-
- try {
- if (tx == null) {
- // for test scope, this may happen
- log.debug("UserTransaction is null, ignore transactional behavior");
- } else {
- int txStatus = tx.getStatus();
- if (txStatus == Status.STATUS_NO_TRANSACTION) {
- log.warn("UserTransaction can't be finished as it wasn't started");
- } else if (txStatus == Status.STATUS_MARKED_ROLLBACK || txStatus == Status.STATUS_ROLLEDBACK
- || txStatus == Status.STATUS_ROLLING_BACK) {
- log.warn("Going to rollback UserTransaction as it's status is " + txStatus);
- tx.rollback();
- } else {
- tx.commit();
- }
- }
- } catch (Exception e) {
- throw new IllegalStateException("Error when committing transaction", e);
- }
- }
-
- /**
- * Obtain {@link UserTransaction} via JNDI call or via {@link TransactionService} if that fails
- *
- * @return transaction
- */
- public UserTransaction getUserTransaction() {
- // It's fine to reuse same instance of UserTransaction as UserTransaction is singleton in JBoss and most other AS.
- // And new InitialContext().lookup("java:comp/UserTransaction") is quite expensive operation
- if (userTransaction == null) {
- synchronized (this) {
- if (userTransaction == null) {
- try {
- userTransaction = (UserTransaction) new InitialContext().lookup("java:comp/UserTransaction");
- } catch (NamingException ne) {
- log.debug("UserTransaction not found via JNDI. Trying TransactionService");
- userTransaction = transactionService.getUserTransaction();
- }
- }
- }
- }
- return userTransaction;
- }
-
- /**
- * {@inheritDoc}
- */
- public void registerListener(JTAUserTransactionLifecycleListener listener) {
- log.info("Registered listener " + listener);
- listeners.add(listener);
- }
-
- protected void executeListenersBeforeBegin() {
- for (JTAUserTransactionLifecycleListener listener : listeners) {
- if (log.isTraceEnabled()) {
- log.trace("Execute listener " + listener + " before begin of JTA transaction");
- }
- listener.beforeBegin();
- }
- }
-
- protected void executeListenersAfterBegin() {
- for (JTAUserTransactionLifecycleListener listener : listeners) {
- if (log.isTraceEnabled()) {
- log.trace("Execute listener " + listener + " after begin of JTA transaction");
- }
- listener.afterBegin();
- }
- }
-}
diff --git a/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-async-config.xml b/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-async-config.xml
deleted file mode 100644
index b4d9b064f3..0000000000
--- a/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-async-config.xml
+++ /dev/null
@@ -1,61 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-config.xml b/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-config.xml
deleted file mode 100644
index 4278133f8b..0000000000
--- a/component/common/src/main/resources/conf/cache/infinispan/cluster/cache-config.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/common/src/main/resources/conf/cache/infinispan/local/cache-config.xml b/component/common/src/main/resources/conf/cache/infinispan/local/cache-config.xml
deleted file mode 100644
index b3b78ded8e..0000000000
--- a/component/common/src/main/resources/conf/cache/infinispan/local/cache-config.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/common/src/main/resources/conf/jgroups/jgroups-service-tcp.xml b/component/common/src/main/resources/conf/jgroups/jgroups-service-tcp.xml
deleted file mode 100644
index 791e709f6d..0000000000
--- a/component/common/src/main/resources/conf/jgroups/jgroups-service-tcp.xml
+++ /dev/null
@@ -1,106 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/component/common/src/main/resources/conf/jgroups/jgroups-service-udp.xml b/component/common/src/main/resources/conf/jgroups/jgroups-service-udp.xml
deleted file mode 100644
index 780adc67e9..0000000000
--- a/component/common/src/main/resources/conf/jgroups/jgroups-service-udp.xml
+++ /dev/null
@@ -1,108 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/component/common/src/test/java/org/gatein/common/transaction/CounterListener.java b/component/common/src/test/java/org/gatein/common/transaction/CounterListener.java
deleted file mode 100644
index 09f30e7d6a..0000000000
--- a/component/common/src/test/java/org/gatein/common/transaction/CounterListener.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.gatein.common.transaction;
-
-import java.util.concurrent.atomic.AtomicInteger;
-
-
-/**
- * Mock listener
- *
- * @author Marek Posolda
- */
-public class CounterListener implements JTAUserTransactionLifecycleListener {
- private AtomicInteger beforeBeginCounter = new AtomicInteger(0);
- private AtomicInteger afterBeginCounter = new AtomicInteger(0);
-
- @Override
- public void beforeBegin() {
- beforeBeginCounter.incrementAndGet();
- }
-
- @Override
- public void afterBegin() {
- afterBeginCounter.incrementAndGet();
- }
-
- int getBeforeBeginCounter() {
- return beforeBeginCounter.get();
- }
-
- int getAfterBeginCounter() {
- return afterBeginCounter.get();
- }
-}
diff --git a/component/common/src/test/java/org/gatein/common/transaction/JTAUserTransactionTest.java b/component/common/src/test/java/org/gatein/common/transaction/JTAUserTransactionTest.java
deleted file mode 100644
index b00b88db59..0000000000
--- a/component/common/src/test/java/org/gatein/common/transaction/JTAUserTransactionTest.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.gatein.common.transaction;
-
-import javax.transaction.Status;
-import javax.transaction.UserTransaction;
-
-import org.exoplatform.component.test.AbstractKernelTest;
-import org.exoplatform.component.test.ConfigurationUnit;
-import org.exoplatform.component.test.ConfiguredBy;
-import org.exoplatform.component.test.ContainerScope;
-import org.exoplatform.container.PortalContainer;
-
-/**
- * test for {@link JTAUserTransactionLifecycleService}
- *
- * @author Marek Posolda
- */
-@ConfiguredBy({
- @ConfigurationUnit(scope = ContainerScope.ROOT, path = "conf/configuration.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/portal/configuration.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.settings-configuration-local-jta.xml"),
-})
-public class JTAUserTransactionTest extends AbstractKernelTest {
-
- private JTAUserTransactionLifecycleService jtaUserTransactionLifecycleService;
-
- @Override
- protected void setUp() throws Exception {
- PortalContainer container = PortalContainer.getInstance();
- jtaUserTransactionLifecycleService = (JTAUserTransactionLifecycleService) container
- .getComponentInstanceOfType(JTAUserTransactionLifecycleService.class);
- }
-
- public void testTransactionLifecycle() throws Exception {
- UserTransaction tx = jtaUserTransactionLifecycleService.getUserTransaction();
- assertNotNull(tx);
-
- // Test normal workflow with begin/commit
- assertStatus(Status.STATUS_NO_TRANSACTION);
-
- jtaUserTransactionLifecycleService.beginJTATransaction();
- assertStatus(Status.STATUS_ACTIVE);
-
- jtaUserTransactionLifecycleService.finishJTATransaction();
- assertStatus(Status.STATUS_NO_TRANSACTION);
-
- // Test workflow with setRollBackOnly
- jtaUserTransactionLifecycleService.beginJTATransaction();
- assertStatus(Status.STATUS_ACTIVE);
-
- tx.setRollbackOnly();
- jtaUserTransactionLifecycleService.finishJTATransaction();
- assertStatus(Status.STATUS_NO_TRANSACTION);
- }
-
- public void testListener() throws Exception {
- CounterListener counterListener = new CounterListener();
- jtaUserTransactionLifecycleService.registerListener(counterListener);
-
- UserTransaction tx = jtaUserTransactionLifecycleService.getUserTransaction();
- assertNotNull(tx);
-
- assertEquals(counterListener.getBeforeBeginCounter(), 0);
- assertEquals(counterListener.getAfterBeginCounter(), 0);
-
- jtaUserTransactionLifecycleService.beginJTATransaction();
- assertEquals(counterListener.getBeforeBeginCounter(), 1);
- assertEquals(counterListener.getAfterBeginCounter(), 1);
-
- jtaUserTransactionLifecycleService.finishJTATransaction();
- jtaUserTransactionLifecycleService.beginJTATransaction();
- assertEquals(counterListener.getBeforeBeginCounter(), 2);
- assertEquals(counterListener.getAfterBeginCounter(), 2);
-
- jtaUserTransactionLifecycleService.finishJTATransaction();
- assertEquals(counterListener.getBeforeBeginCounter(), 2);
- assertEquals(counterListener.getAfterBeginCounter(), 2);
- }
-
- private void assertStatus(int expectedStatus) throws Exception {
- int status = jtaUserTransactionLifecycleService.getUserTransaction().getStatus();
- assertEquals(expectedStatus, status);
- }
-}
diff --git a/component/common/src/test/resources/conf/exo.portal.component.settings-configuration-local-jta.xml b/component/common/src/test/resources/conf/exo.portal.component.settings-configuration-local-jta.xml
deleted file mode 100644
index e0a6c613ab..0000000000
--- a/component/common/src/test/resources/conf/exo.portal.component.settings-configuration-local-jta.xml
+++ /dev/null
@@ -1,72 +0,0 @@
-
-
-
-
-
- org.gatein.common.transaction.JTAUserTransactionLifecycleService
- org.gatein.common.transaction.JTAUserTransactionLifecycleServiceImpl
-
-
-
- org.infinispan.transaction.lookup.TransactionManagerLookup
- org.exoplatform.services.transaction.infinispan.JBossStandaloneJTAManagerLookup
-
-
-
- org.exoplatform.services.transaction.TransactionService
- org.exoplatform.services.transaction.infinispan.JBossTransactionsService
-
-
- timeout
- 300
-
-
-
-
-
- org.exoplatform.services.cache.CacheService
- cache:type=CacheService
- org.exoplatform.services.cache.impl.CacheServiceImpl
-
-
- cache.config.default
-
-
-
-
-
-
diff --git a/component/identity/pom.xml b/component/identity/pom.xml
index d76ce241bb..e3a3c8c3e6 100644
--- a/component/identity/pom.xml
+++ b/component/identity/pom.xml
@@ -53,16 +53,6 @@
picketlink-idm-ldap
-
- io.meeds.kernel
- exo.kernel.component.ext.cache.impl.infinispan.v8
-
- provided
-
-
${project.groupId}
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/AbstractDAOImpl.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/AbstractDAOImpl.java
index c21ef091fc..1bc9ee0b37 100644
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/AbstractDAOImpl.java
+++ b/component/identity/src/main/java/org/exoplatform/services/organization/idm/AbstractDAOImpl.java
@@ -15,13 +15,8 @@
*/
package org.exoplatform.services.organization.idm;
-import javax.transaction.Status;
-import javax.transaction.UserTransaction;
-
-import org.exoplatform.container.ExoContainerContext;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
-import org.gatein.common.transaction.JTAUserTransactionLifecycleService;
import org.picketlink.idm.api.IdentitySession;
/**
@@ -43,21 +38,7 @@ public AbstractDAOImpl(PicketLinkIDMOrganizationServiceImpl orgService, PicketLi
public void handleException(String messageToLog, Exception e) {
try {
- // Mark JTA transaction to rollback-only if JTA setup is enabled
- if (orgService.getConfiguration().isUseJTA()) {
- try {
- JTAUserTransactionLifecycleService transactionLfService = (JTAUserTransactionLifecycleService) ExoContainerContext
- .getCurrentContainer().getComponentInstanceOfType(JTAUserTransactionLifecycleService.class);
- UserTransaction tx = transactionLfService.getUserTransaction();
- if (tx.getStatus() == Status.STATUS_ACTIVE) {
- tx.setRollbackOnly();
- }
- } catch (Exception tre) {
- log.warn("Unable to set Transaction status to be rollback only", tre);
- }
- } else {
- orgService.recoverFromIDMError();
- }
+ orgService.recoverFromIDMError();
// Always throw the original exception to make sure that top layer services
// are triggered about the error
throw new IllegalStateException(messageToLog, e);
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/Config.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/Config.java
index cfcf4e6055..13c9b1f67a 100644
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/Config.java
+++ b/component/identity/src/main/java/org/exoplatform/services/organization/idm/Config.java
@@ -56,8 +56,6 @@ public class Config {
private boolean useCache = true;
- private boolean useJTA = false;
-
private boolean sortGroups = true;
private boolean sortMemberships = true;
@@ -300,14 +298,6 @@ public void setIgnoreMappedMembershipTypeGroupList(List ignoreMappedMemb
this.ignoreMappedMembershipTypeGroupList = ignoreMappedMembershipTypeGroupList;
}
- public boolean isUseJTA() {
- return useJTA;
- }
-
- public void setUseJTA(boolean useJTA) {
- this.useJTA = useJTA;
- }
-
public String getSlashReplacement() {
return slashReplacement;
}
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/IDMTransactionSyncListener.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/IDMTransactionSyncListener.java
deleted file mode 100644
index eef3b200f7..0000000000
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/IDMTransactionSyncListener.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2012, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.exoplatform.services.organization.idm;
-
-import org.gatein.common.transaction.JTAUserTransactionLifecycleListener;
-
-/**
- * Listener used for sync global JTA transaction and underlying IDM (Hibernate) transaction
- *
- * @author Marek Posolda
- */
-class IDMTransactionSyncListener implements JTAUserTransactionLifecycleListener {
- private PicketLinkIDMService idmService;
-
- public IDMTransactionSyncListener(PicketLinkIDMService idmService) {
- this.idmService = idmService;
- }
-
- @Override
- public void beforeBegin() {
- }
-
- @Override
- public void afterBegin() {
- try {
- // We need this as from Hibernate4 and with JTATransactionFactory, there is need to separately start IDM (Hibernate)
- // transaction as well even if JTA transaction is started
- if (!idmService.getIdentitySession().getTransaction().isActive()) {
- idmService.getIdentitySession().beginTransaction();
- }
- } catch (Exception e) {
- throw new RuntimeException(e);
- }
- }
-}
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/CustomHibernateServiceImpl.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/IdmHibernateService.java
similarity index 90%
rename from component/identity/src/main/java/org/exoplatform/services/organization/idm/CustomHibernateServiceImpl.java
rename to component/identity/src/main/java/org/exoplatform/services/organization/idm/IdmHibernateService.java
index 5be8f82954..0ccf2747b5 100644
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/CustomHibernateServiceImpl.java
+++ b/component/identity/src/main/java/org/exoplatform/services/organization/idm/IdmHibernateService.java
@@ -24,7 +24,6 @@
package org.exoplatform.services.organization.idm;
import java.io.Serializable;
-import java.security.PrivilegedAction;
import java.util.Collection;
import java.util.Iterator;
import java.util.List;
@@ -40,14 +39,12 @@
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.container.xml.PropertiesParam;
import org.exoplatform.container.xml.Property;
-import org.exoplatform.services.database.HibernateService;
-import org.exoplatform.services.database.ObjectQuery;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
-public class CustomHibernateServiceImpl implements HibernateService, ComponentRequestLifecycle {
+public class IdmHibernateService implements ComponentRequestLifecycle {
- private static final Log LOG = ExoLogger.getLogger(CustomHibernateServiceImpl.class);
+ private static final Log LOG = ExoLogger.getLogger(IdmHibernateService.class);
public static final String AUTO_DIALECT = "AUTO";
@@ -57,7 +54,7 @@ public class CustomHibernateServiceImpl implements HibernateService, ComponentRe
private SessionFactory sessionFactory_;
- public CustomHibernateServiceImpl(InitParams initParams) {
+ public IdmHibernateService(InitParams initParams) {
threadLocal_ = new ThreadLocal();
PropertiesParam param = initParams.getPropertiesParam("hibernate.properties");
conf_ = new IdmHibernateConfiguration();
@@ -169,18 +166,6 @@ public Object findOne(Class clazz, Serializable id) throws Exception {
return obj;
}
- public Object findOne(ObjectQuery q) throws Exception {
- Session session = openSession();
- List> l = session.createQuery(q.getHibernateQuery()).list();
- if (l.size() == 0) {
- return null;
- } else if (l.size() > 1) {
- throw new Exception("Expect only one object but found" + l.size());
- } else {
- return l.get(0);
- }
- }
-
public Object create(Object obj) throws Exception {
Session session = openSession();
session.save(obj);
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceImpl.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceImpl.java
index 3431f815c6..678cfb1f70 100644
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceImpl.java
+++ b/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceImpl.java
@@ -22,11 +22,8 @@
import java.util.Collections;
import java.util.List;
-import javax.transaction.Status;
-
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
-import org.gatein.common.transaction.JTAUserTransactionLifecycleService;
import org.gatein.portal.idm.impl.repository.ExoFallbackIdentityStoreRepository;
import org.gatein.portal.idm.impl.repository.ExoLegacyFallbackIdentityStoreRepository;
import org.picketlink.idm.api.Transaction;
@@ -52,336 +49,290 @@
* OrganizationService implementation using PicketLink
*/
public class PicketLinkIDMOrganizationServiceImpl extends BaseOrganizationService implements Startable,
- ComponentRequestLifecycle {
-
- // We may have several portal containers thus we need one PicketLinkIDMService per portal container
- private PicketLinkIDMServiceImpl idmService_;
+ ComponentRequestLifecycle {
- public static final String CONFIGURATION_OPTION = "configuration";
+ // We may have several portal containers thus we need one PicketLinkIDMService
+ // per portal container
+ private PicketLinkIDMServiceImpl idmService_;
- private Config configuration = new Config();
+ public static final String CONFIGURATION_OPTION = "configuration";
- private JTAUserTransactionLifecycleService jtaTransactionLifecycleService;
+ private Config configuration = new Config();
- private OrganizationCacheHandler organizationCacheHandler;
+ private OrganizationCacheHandler organizationCacheHandler;
- private static final Log log =
+ private static final Log log =
ExoLogger.getLogger(PicketLinkIDMOrganizationServiceImpl.class);
- private static final boolean traceLoggingEnabled = log.isTraceEnabled();
-
- // Indicates whether any call to startRequest and endRequest is accepted
- private volatile boolean acceptComponentRequestCall;
-
- public PicketLinkIDMOrganizationServiceImpl(InitParams params, PicketLinkIDMService idmService,
- JTAUserTransactionLifecycleService jtaTransactionLifecycleService, OrganizationCacheHandler organizationCacheHandler) throws Exception {
- this.idmService_ = (PicketLinkIDMServiceImpl) idmService;
- this.jtaTransactionLifecycleService = jtaTransactionLifecycleService;
- this.organizationCacheHandler = organizationCacheHandler;
-
- if (params != null) {
- // Options
- ObjectParameter configurationParam = params.getObjectParam(CONFIGURATION_OPTION);
-
- if (configurationParam != null) {
- this.configuration = (Config) configurationParam.getObject();
- initConfiguration(params);
- }
- }
- if(organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
- groupDAO_ = new CacheableGroupHandlerImpl(organizationCacheHandler, this, idmService, this.configuration.isCountPaginatedUsers());
- userDAO_ = new CacheableUserHandlerImpl(organizationCacheHandler, this, idmService);
- userProfileDAO_ = new CacheableUserProfileHandlerImpl(organizationCacheHandler, this, idmService);
- membershipDAO_ = new CacheableMembershipHandlerImpl(organizationCacheHandler, this, idmService, true);
- membershipTypeDAO_ = new CacheableMembershipTypeHandlerImpl(organizationCacheHandler, this, idmService);
- } else {
- groupDAO_ = new GroupDAOImpl(this, idmService);
- userDAO_ = new UserDAOImpl(this, idmService);
- userProfileDAO_ = new UserProfileDAOImpl(this, idmService);
- membershipDAO_ = new MembershipDAOImpl(this, idmService);
- membershipTypeDAO_ = new MembershipTypeDAOImpl(this, idmService);
- }
+ private static final boolean traceLoggingEnabled = log.isTraceEnabled();
+
+ // Indicates whether any call to startRequest and endRequest is accepted
+ private volatile boolean acceptComponentRequestCall;
+ public PicketLinkIDMOrganizationServiceImpl(InitParams params,
+ PicketLinkIDMService idmService,
+ OrganizationCacheHandler organizationCacheHandler)
+ throws Exception {
+ this.idmService_ = (PicketLinkIDMServiceImpl) idmService;
+ this.organizationCacheHandler = organizationCacheHandler;
+
+ if (params != null) {
+ // Options
+ ObjectParameter configurationParam = params.getObjectParam(CONFIGURATION_OPTION);
+
+ if (configurationParam != null) {
+ this.configuration = (Config) configurationParam.getObject();
+ initConfiguration(params);
+ }
}
- public PicketLinkIDMOrganizationServiceImpl(InitParams params, PicketLinkIDMService idmService,
- JTAUserTransactionLifecycleService jtaTransactionLifecycleService) throws Exception {
- this(params, idmService, jtaTransactionLifecycleService, null);
+ if (organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
+ groupDAO_ = new CacheableGroupHandlerImpl(organizationCacheHandler,
+ this,
+ idmService,
+ this.configuration.isCountPaginatedUsers());
+ userDAO_ = new CacheableUserHandlerImpl(organizationCacheHandler, this, idmService);
+ userProfileDAO_ = new CacheableUserProfileHandlerImpl(organizationCacheHandler, this, idmService);
+ membershipDAO_ = new CacheableMembershipHandlerImpl(organizationCacheHandler, this, idmService, true);
+ membershipTypeDAO_ = new CacheableMembershipTypeHandlerImpl(organizationCacheHandler, this, idmService);
+ } else {
+ groupDAO_ = new GroupDAOImpl(this, idmService);
+ userDAO_ = new UserDAOImpl(this, idmService);
+ userProfileDAO_ = new UserProfileDAOImpl(this, idmService);
+ membershipDAO_ = new MembershipDAOImpl(this, idmService);
+ membershipTypeDAO_ = new MembershipTypeDAOImpl(this, idmService);
}
- public final org.picketlink.idm.api.Group getJBIDMGroup(String groupId) throws Exception {
- String[] ids = groupId.split("/");
- String name = ids[ids.length - 1];
- String parentId = null;
- if (groupId.contains("/")) {
- parentId = groupId.substring(0, groupId.lastIndexOf("/"));
- }
+ }
- String plGroupName = configuration.getPLIDMGroupName(name);
+ public PicketLinkIDMOrganizationServiceImpl(InitParams params, PicketLinkIDMService idmService)
+ throws Exception {
+ this(params, idmService, null);
+ }
- return idmService_.getIdentitySession().getPersistenceManager()
- .findGroup(plGroupName, getConfiguration().getGroupType(parentId));
+ public final org.picketlink.idm.api.Group getJBIDMGroup(String groupId) throws Exception {
+ String[] ids = groupId.split("/");
+ String name = ids[ids.length - 1];
+ String parentId = null;
+ if (groupId.contains("/")) {
+ parentId = groupId.substring(0, groupId.lastIndexOf("/"));
}
- @Override
- public void start() {
- if (configuration.isUseJTA()) {
- jtaTransactionLifecycleService.registerListener(new IDMTransactionSyncListener(idmService_));
- }
- acceptComponentRequestCall = true;
- RequestLifeCycle.begin(this);
- try {
- super.start();
- } catch (Exception e) {
- log.error("Error Starting IDM Service", e);
- } finally {
- RequestLifeCycle.end();
- }
+ String plGroupName = configuration.getPLIDMGroupName(name);
+
+ return idmService_.getIdentitySession()
+ .getPersistenceManager()
+ .findGroup(plGroupName, getConfiguration().getGroupType(parentId));
+ }
+
+ @Override
+ public void start() {
+ acceptComponentRequestCall = true;
+ RequestLifeCycle.begin(this);
+ try {
+ super.start();
+ } catch (Exception e) {
+ log.error("Error Starting IDM Service", e);
+ } finally {
+ RequestLifeCycle.end();
}
+ }
- @Override
- public void stop() {
- // do nothing
- }
+ @Override
+ public void stop() {
+ // do nothing
+ }
- public void startRequest(ExoContainer container) {
- if (!acceptComponentRequestCall) {
- return;
- }
- try {
- if (configuration.isUseJTA()) {
- if (traceLoggingEnabled) {
- log.trace("Starting UserTransaction in method startRequest");
- }
-
- try {
- if(jtaTransactionLifecycleService.getUserTransaction().getStatus() != Status.STATUS_NO_TRANSACTION &&
- jtaTransactionLifecycleService.getUserTransaction().getStatus() != Status.STATUS_ACTIVE){
- //Commit or Rollback JTA transaction according to it's current status
- jtaTransactionLifecycleService.finishJTATransaction();
- }
- } catch (Exception e) {
- log.error(e.getMessage(), e);
- }
- jtaTransactionLifecycleService.beginJTATransaction();
- } else {
-
- if (!idmService_.getIdentitySession().getTransaction().isActive()) {
- idmService_.getIdentitySession().beginTransaction();
- }
- }
- } catch (Exception e) {
- log.error(e.getMessage(), e);
- }
+ public void startRequest(ExoContainer container) {
+ if (!acceptComponentRequestCall) {
+ return;
}
+ try {
+ if (!idmService_.getIdentitySession().getTransaction().isActive()) {
+ idmService_.getIdentitySession().beginTransaction();
+ }
+ } catch (Exception e) {
+ log.error("Error while starting IDM Transaction", e);
+ }
+ }
- public void flush() {
- if (configuration.isUseJTA()) {
- if (traceLoggingEnabled) {
- log.trace("Flushing UserTransaction in method flush");
- }
- // Complete restart of JTA transaction don't have good performance. So we will only sync identitySession (same
- // as for non-jta environment)
- // finishJTATransaction();
- // beginJTATransaction();
- try {
- if (jtaTransactionLifecycleService.getUserTransaction().getStatus() == Status.STATUS_ACTIVE) {
- idmService_.getIdentitySession().save();
- }
- } catch (Exception e) {
- log.error(e.getMessage(), e);
- }
- } else {
- try {
- if (idmService_.getIdentitySession().getTransaction().isActive()) {
- idmService_.getIdentitySession().save();
- }
- } catch (Exception e) {
- log.error("Error while saving transaction", e);
- recoverFromIDMError();
- }
- }
+ public void flush() {
+ try {
+ if (idmService_.getIdentitySession().getTransaction().isActive()) {
+ idmService_.getIdentitySession().save();
+ }
+ } catch (Exception e) {
+ log.error("Error while saving transaction", e);
+ recoverFromIDMError();
}
+ }
- public void endRequest(ExoContainer container) {
- if (!acceptComponentRequestCall) {
- return;
- }
- if (configuration.isUseJTA()) {
- if (traceLoggingEnabled) {
- log.trace("Finishing UserTransaction in method endRequest");
- }
- try {
- jtaTransactionLifecycleService.finishJTATransaction();
- } catch (Exception e) {
- log.error(e.getMessage(), e);
- }
- } else {
- try {
- Transaction transaction = idmService_.getIdentitySession().getTransaction();
- if (transaction.isActive()) {
- transaction.commit();
- }
- } catch (Exception e) {
- log.error(e.getMessage(), e);
- recoverFromIDMError();
- }
- }
+ public void endRequest(ExoContainer container) {
+ if (!acceptComponentRequestCall) {
+ return;
}
+ try {
+ Transaction transaction = idmService_.getIdentitySession().getTransaction();
+ if (transaction.isActive()) {
+ transaction.commit();
+ }
+ } catch (Exception e) {
+ log.error("Error while committing IDM transaction", e);
+ recoverFromIDMError();
+ }
+ }
- public boolean isStarted(ExoContainer container) {
- if(!acceptComponentRequestCall) {
- return false;
- }
+ public boolean isStarted(ExoContainer container) {
+ if (!acceptComponentRequestCall) {
+ return false;
+ }
+ try {
+ return idmService_.getIdentitySession() != null
+ && idmService_.getIdentitySession().getTransaction() != null
+ && idmService_.getIdentitySession()
+ .getTransaction()
+ .isActive();
+ } catch (Exception e) {
+ log.error("Error while checking on Transaction status : ", e);
+ }
+ return false;
+ }
+
+ /**
+ * Recover from an IDM error
+ */
+ public void recoverFromIDMError() {
+ try {
+ // We need to restart Hibernate transaction if it's available. First
+ // rollback old one and then start new one
+ Transaction idmTransaction = idmService_.getIdentitySession().getTransaction();
+ if (idmTransaction != null && idmTransaction.isActive()) {
try {
- if (configuration.isUseJTA()) {
- return jtaTransactionLifecycleService.getUserTransaction() == null ? false :
- jtaTransactionLifecycleService.getUserTransaction().getStatus()== Status.STATUS_ACTIVE;
- } else {
- return (idmService_.getIdentitySession() == null || idmService_.getIdentitySession().getTransaction() == null) ? false :
- idmService_.getIdentitySession().getTransaction().isActive();
- }
- } catch (Exception e) {
- log.error("Error while checking on Transaction status : ", e);
+ idmTransaction.rollback();
+ log.warn("IDM Transaction has been rolled-backed");
+ } catch (Exception e1) {
+ log.warn("Error during IDM Transaction rollback.", e1);
}
- return false;
- }
-
- /**
- * Recover from an IDM error
- * Should be used only for non-JTA environment.
- */
- public void recoverFromIDMError() {
try {
- // We need to restart Hibernate transaction if it's available. First rollback old one and then start new one
- Transaction idmTransaction = idmService_.getIdentitySession().getTransaction();
- if (idmTransaction != null && idmTransaction.isActive()) {
- try {
- idmTransaction.rollback();
- log.warn("IDM Transaction has been rolled-backed");
- } catch (Exception e1) {
- log.warn("Error during IDM Transaction rollback.", e1);
- }
- try {
- idmTransaction.start();
- log.warn("IDM Transaction restarted");
- } catch (Exception e1) {
- log.warn("Error during IDM Transaction restart, a new transaction will be started", e1);
- idmService_.getIdentitySession().beginTransaction();
- }
- } else {
- idmService_.getIdentitySession().beginTransaction();
- log.warn("New IDM Transaction started");
- }
+ idmTransaction.start();
+ log.warn("IDM Transaction restarted");
} catch (Exception e1) {
- log.warn("Error during recovery of old error", e1);
+ log.warn("Error during IDM Transaction restart, a new transaction will be started", e1);
+ idmService_.getIdentitySession().beginTransaction();
}
+ } else {
+ idmService_.getIdentitySession().beginTransaction();
+ log.warn("New IDM Transaction started");
+ }
+ } catch (Exception e1) {
+ log.warn("Error during recovery of old error", e1);
}
+ }
- public Config getConfiguration() {
- return configuration;
- }
+ public Config getConfiguration() {
+ return configuration;
+ }
- public void clearCaches(){
- if(organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
- if(groupDAO_ != null && groupDAO_ instanceof CacheableGroupHandlerImpl){
- ((CacheableGroupHandlerImpl) groupDAO_).clearCache();
- }
- if(userDAO_ != null && userDAO_ instanceof CacheableUserHandlerImpl){
- ((CacheableUserHandlerImpl) userDAO_).clearCache();
- }
- if(userProfileDAO_ != null && userProfileDAO_ instanceof CacheableUserProfileHandlerImpl){
- ((CacheableUserProfileHandlerImpl) userProfileDAO_).clearCache();
- }
- if(membershipDAO_ != null && membershipDAO_ instanceof CacheableMembershipHandlerImpl){
- ((CacheableMembershipHandlerImpl) membershipDAO_).clearCache();
- }
- if(membershipTypeDAO_ != null && membershipTypeDAO_ instanceof CacheableMembershipTypeHandlerImpl){
- ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).clearCache();
- }
- }
+ public void clearCaches() {
+ if (organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
+ if (groupDAO_ != null && groupDAO_ instanceof CacheableGroupHandlerImpl) {
+ ((CacheableGroupHandlerImpl) groupDAO_).clearCache();
+ }
+ if (userDAO_ != null && userDAO_ instanceof CacheableUserHandlerImpl) {
+ ((CacheableUserHandlerImpl) userDAO_).clearCache();
+ }
+ if (userProfileDAO_ != null && userProfileDAO_ instanceof CacheableUserProfileHandlerImpl) {
+ ((CacheableUserProfileHandlerImpl) userProfileDAO_).clearCache();
+ }
+ if (membershipDAO_ != null && membershipDAO_ instanceof CacheableMembershipHandlerImpl) {
+ ((CacheableMembershipHandlerImpl) membershipDAO_).clearCache();
+ }
+ if (membershipTypeDAO_ != null && membershipTypeDAO_ instanceof CacheableMembershipTypeHandlerImpl) {
+ ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).clearCache();
+ }
}
+ }
- public void setEnableCache(boolean enable) {
- if (organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
- if (groupDAO_ != null && groupDAO_ instanceof CacheableGroupHandlerImpl) {
- if (enable) {
- ((CacheableGroupHandlerImpl) groupDAO_).enableCache();
- } else {
- ((CacheableGroupHandlerImpl) groupDAO_).disableCache();
- }
+ public void setEnableCache(boolean enable) {
+ if (organizationCacheHandler != null && (this.configuration == null || this.configuration.isUseCache())) {
+ if (groupDAO_ != null && groupDAO_ instanceof CacheableGroupHandlerImpl) {
+ if (enable) {
+ ((CacheableGroupHandlerImpl) groupDAO_).enableCache();
+ } else {
+ ((CacheableGroupHandlerImpl) groupDAO_).disableCache();
}
- if (userDAO_ != null && userDAO_ instanceof CacheableUserHandlerImpl) {
- if (enable) {
- ((CacheableUserHandlerImpl) userDAO_).enableCache();
- } else {
- ((CacheableUserHandlerImpl) userDAO_).disableCache();
- }
+ }
+ if (userDAO_ != null && userDAO_ instanceof CacheableUserHandlerImpl) {
+ if (enable) {
+ ((CacheableUserHandlerImpl) userDAO_).enableCache();
+ } else {
+ ((CacheableUserHandlerImpl) userDAO_).disableCache();
}
- if (userProfileDAO_ != null && userProfileDAO_ instanceof CacheableUserProfileHandlerImpl) {
- if (enable) {
- ((CacheableUserProfileHandlerImpl) userProfileDAO_).enableCache();
- } else {
- ((CacheableUserProfileHandlerImpl) userProfileDAO_).disableCache();
- }
+ }
+ if (userProfileDAO_ != null && userProfileDAO_ instanceof CacheableUserProfileHandlerImpl) {
+ if (enable) {
+ ((CacheableUserProfileHandlerImpl) userProfileDAO_).enableCache();
+ } else {
+ ((CacheableUserProfileHandlerImpl) userProfileDAO_).disableCache();
}
- if (membershipDAO_ != null && membershipDAO_ instanceof CacheableMembershipHandlerImpl) {
- if (enable) {
- ((CacheableMembershipHandlerImpl) membershipDAO_).enableCache();
- } else {
- ((CacheableMembershipHandlerImpl) membershipDAO_).disableCache();
- }
+ }
+ if (membershipDAO_ != null && membershipDAO_ instanceof CacheableMembershipHandlerImpl) {
+ if (enable) {
+ ((CacheableMembershipHandlerImpl) membershipDAO_).enableCache();
+ } else {
+ ((CacheableMembershipHandlerImpl) membershipDAO_).disableCache();
}
- if (membershipTypeDAO_ != null && membershipTypeDAO_ instanceof CacheableMembershipTypeHandlerImpl) {
- if (enable) {
- ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).enableCache();
- } else {
- ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).disableCache();
- }
+ }
+ if (membershipTypeDAO_ != null && membershipTypeDAO_ instanceof CacheableMembershipTypeHandlerImpl) {
+ if (enable) {
+ ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).enableCache();
+ } else {
+ ((CacheableMembershipTypeHandlerImpl) membershipTypeDAO_).disableCache();
}
}
}
+ }
+
+ public void setConfiguration(Config configuration) {
+ this.configuration = configuration;
+ }
- public void setConfiguration(Config configuration) {
- this.configuration = configuration;
+ private void initConfiguration(InitParams params) {
+ /* Default settings - DB Only */
+ this.configuration.setCountPaginatedUsers(true);
+ this.configuration.setSkipPaginationInMembershipQuery(false);
+
+ IdentityConfigurationMetaData configMD = ((PicketLinkIDMServiceImpl) this.idmService_).getConfigMD();
+ if (configMD == null) {
+ return;
}
- private void initConfiguration(InitParams params) {
- /* Default settings - DB Only */
- this.configuration.setCountPaginatedUsers(true);
- this.configuration.setSkipPaginationInMembershipQuery(false);
-
- IdentityConfigurationMetaData configMD = ((PicketLinkIDMServiceImpl) this.idmService_).getConfigMD();
- if (configMD == null) {
- return;
- }
-
- // Use DB Default settings if External Store API is used, else if Legacy
- // LDAP Store was used, disable paginations
- List repositories = configMD.getRepositories();
- for (IdentityRepositoryConfigurationMetaData identityRepositoryConfigurationMetaData : repositories) {
- if (identityRepositoryConfigurationMetaData.getClassName()
- .equals(ExoLegacyFallbackIdentityStoreRepository.class.getName())) {
- List identityStoreMappings =
- identityRepositoryConfigurationMetaData.getIdentityStoreToIdentityObjectTypeMappings();
- if (identityStoreMappings != null && identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId() != null
- && !identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId()
- .equals(identityStoreMappings.get(0).getIdentityStoreId())) {
- this.configuration.setCountPaginatedUsers(false);
- this.configuration.setSkipPaginationInMembershipQuery(true);
- }
- } else if (identityRepositoryConfigurationMetaData.getClassName()
- .equals(ExoFallbackIdentityStoreRepository.class.getName())) {
- List identityStoreMappings =
- identityRepositoryConfigurationMetaData.getIdentityStoreToIdentityObjectTypeMappings();
- if (identityStoreMappings != null && identityStoreMappings.size() > 0
- && !identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId()
- .equals(identityStoreMappings.get(0).getIdentityStoreId())) {
- IdentityStoreMappingMetaData mappingMetaData = identityStoreMappings.get(0);
- mappingMetaData.getOptions().put("readOnly", Collections.singletonList("true"));
- }
+ // Use DB Default settings if External Store API is used, else if Legacy
+ // LDAP Store was used, disable paginations
+ List repositories = configMD.getRepositories();
+ for (IdentityRepositoryConfigurationMetaData identityRepositoryConfigurationMetaData : repositories) {
+ if (identityRepositoryConfigurationMetaData.getClassName()
+ .equals(ExoLegacyFallbackIdentityStoreRepository.class.getName())) {
+ List identityStoreMappings =
+ identityRepositoryConfigurationMetaData.getIdentityStoreToIdentityObjectTypeMappings();
+ if (identityStoreMappings != null && identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId() != null
+ && !identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId()
+ .equals(identityStoreMappings.get(0).getIdentityStoreId())) {
+ this.configuration.setCountPaginatedUsers(false);
+ this.configuration.setSkipPaginationInMembershipQuery(true);
+ }
+ } else if (identityRepositoryConfigurationMetaData.getClassName()
+ .equals(ExoFallbackIdentityStoreRepository.class.getName())) {
+ List identityStoreMappings =
+ identityRepositoryConfigurationMetaData.getIdentityStoreToIdentityObjectTypeMappings();
+ if (identityStoreMappings != null && identityStoreMappings.size() > 0
+ && !identityRepositoryConfigurationMetaData.getDefaultIdentityStoreId()
+ .equals(identityStoreMappings.get(0).getIdentityStoreId())) {
+ IdentityStoreMappingMetaData mappingMetaData = identityStoreMappings.get(0);
+ mappingMetaData.getOptions().put("readOnly", Collections.singletonList("true"));
}
}
}
+ }
}
diff --git a/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMServiceImpl.java b/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMServiceImpl.java
index 8f1da3e7a0..ec13292e50 100644
--- a/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMServiceImpl.java
+++ b/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMServiceImpl.java
@@ -16,7 +16,6 @@
* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
*/
-
package org.exoplatform.services.organization.idm;
import java.io.InputStream;
@@ -25,31 +24,26 @@
import javax.naming.InitialContext;
import org.apache.commons.lang3.StringUtils;
-import org.exoplatform.commons.utils.PropertyManager;
-import org.exoplatform.container.ExoContainerContext;
-import org.exoplatform.container.configuration.ConfigurationManager;
-import org.exoplatform.container.xml.InitParams;
-import org.exoplatform.container.xml.ValueParam;
-import org.exoplatform.services.database.HibernateService;
-import org.exoplatform.services.log.ExoLogger;
-import org.exoplatform.services.log.Log;
-import org.exoplatform.services.naming.InitialContextInitializer;
import org.gatein.portal.idm.impl.store.attribute.ExtendedAttributeManager;
-import org.infinispan.Cache;
import org.picketlink.idm.api.IdentitySession;
import org.picketlink.idm.api.IdentitySessionFactory;
import org.picketlink.idm.api.SecureRandomProvider;
import org.picketlink.idm.api.cfg.IdentityConfiguration;
-import org.picketlink.idm.cache.APICacheProvider;
import org.picketlink.idm.common.exception.IdentityConfigurationException;
import org.picketlink.idm.impl.api.session.IdentitySessionImpl;
import org.picketlink.idm.impl.configuration.IdentityConfigurationImpl;
import org.picketlink.idm.impl.configuration.jaxb2.JAXB2IdentityConfiguration;
import org.picketlink.idm.impl.credential.DatabaseReadingSaltEncoder;
-import org.picketlink.idm.spi.cache.IdentityStoreCacheProvider;
import org.picketlink.idm.spi.configuration.metadata.IdentityConfigurationMetaData;
import org.picocontainer.Startable;
+import org.exoplatform.container.ExoContainerContext;
+import org.exoplatform.container.configuration.ConfigurationManager;
+import org.exoplatform.container.xml.InitParams;
+import org.exoplatform.container.xml.ValueParam;
+import org.exoplatform.services.log.ExoLogger;
+import org.exoplatform.services.log.Log;
+
/**
* @author Boleslaw Dawidowicz
*/
@@ -61,12 +55,8 @@ public class PicketLinkIDMServiceImpl implements PicketLinkIDMService, Startable
public static final String PARAM_JNDI_NAME_OPTION = "jndiName";
- public static final String PARAM_SKIP_EXPIRATION_STRUCTURE_CACHE_ENTRIES = "skipExpirationOfStructureCacheEntries";
-
public static final String PARAM_USE_SECURE_RANDOM_SERVICE = "useSecureRandomService";
- public static final String PARAM_STALE_CACHE_NODES_LINKS_CLEANER_DELAY = "staleCacheNodesLinksCleanerDelay";
-
public static final int DEFAULT_STALE_CACHE_NODES_LINKS_CLEANER_DELAY = 120000;
public static final String REALM_NAME_OPTION = "portalRealm";
@@ -75,129 +65,120 @@ public class PicketLinkIDMServiceImpl implements PicketLinkIDMService, Startable
public static final String CACHE_CONFIG_STORE_OPTION = "storeCacheConfig";
- private IdentitySessionFactory identitySessionFactory;
+ private IdentitySessionFactory identitySessionFactory;
- private String config;
+ private String config;
- private String realmName = "idm_realm";
+ private String realmName = "idm_realm";
- private IdentityConfiguration identityConfiguration;
+ private IdentityConfiguration identityConfiguration;
private IdentityConfigurationMetaData configMD;
- private HibernateService hibernateService;
- private ExtendedAttributeManager extendedAttributeManager;
+ private IdmHibernateService idmHibernateService;
- public PicketLinkIDMServiceImpl(ExoContainerContext exoContainerContext, InitParams initParams,
- HibernateService hibernateService, ConfigurationManager confManager,
- InitialContextInitializer dependency) throws Exception {
+ private ExtendedAttributeManager extendedAttributeManager;
- ValueParam config = null;
+ public PicketLinkIDMServiceImpl(IdmHibernateService hibernateService,
+ ConfigurationManager confManager,
+ InitParams initParams)
+ throws Exception {
+ ValueParam configValueParam = null;
- ValueParam directoryTypeValueParam = initParams.getValueParam("ldap.type");
- String directoryType = null;
- if(directoryTypeValueParam != null) {
- directoryType = directoryTypeValueParam.getValue();
- }
- if(StringUtils.isNotBlank(directoryType)) {
- config = initParams.getValueParam(PARAM_CONFIG_OPTION + "." + directoryType);
- }
-
- if(config == null) {
- config = initParams.getValueParam(PARAM_CONFIG_OPTION);
- }
-
- ValueParam jndiName = initParams.getValueParam(PARAM_JNDI_NAME_OPTION);
- ValueParam canExpireStructureCacheEntriesParam = initParams
- .getValueParam(PARAM_SKIP_EXPIRATION_STRUCTURE_CACHE_ENTRIES);
- ValueParam staleCacheNodesLinksCleanerDelayParam = initParams
- .getValueParam(PARAM_STALE_CACHE_NODES_LINKS_CLEANER_DELAY);
- ValueParam realmName = initParams.getValueParam(REALM_NAME_OPTION);
- ValueParam apiCacheConfig = initParams.getValueParam(CACHE_CONFIG_API_OPTION);
- ValueParam storeCacheConfig = initParams.getValueParam(CACHE_CONFIG_STORE_OPTION);
- ValueParam useSecureRandomService = initParams.getValueParam(PARAM_USE_SECURE_RANDOM_SERVICE);
-
- this.hibernateService = hibernateService;
-
- if (config == null && jndiName == null) {
- throw new IllegalStateException("Either '" + PARAM_CONFIG_OPTION + "' or '" + PARAM_JNDI_NAME_OPTION
- + "' parameter must " + "be specified");
- }
- if (realmName != null) {
- this.realmName = realmName.getValue();
- }
-
- long staleCacheNodesLinksCleanerDelay = staleCacheNodesLinksCleanerDelayParam == null ? DEFAULT_STALE_CACHE_NODES_LINKS_CLEANER_DELAY
- : Long.parseLong(staleCacheNodesLinksCleanerDelayParam.getValue());
-
- boolean skipExpirationOfStructureCacheEntries = canExpireStructureCacheEntriesParam != null
- && "true".equals(canExpireStructureCacheEntriesParam.getValue());
+ ValueParam directoryTypeValueParam = initParams.getValueParam("ldap.type");
+ String directoryType = null;
+ if (directoryTypeValueParam != null) {
+ directoryType = directoryTypeValueParam.getValue();
+ }
+ if (StringUtils.isNotBlank(directoryType)) {
+ configValueParam = initParams.getValueParam(PARAM_CONFIG_OPTION + "." + directoryType);
+ }
- if (config != null) {
- this.config = config.getValue();
- URL configURL = confManager.getURL(this.config);
+ if (configValueParam == null) {
+ configValueParam = initParams.getValueParam(PARAM_CONFIG_OPTION);
+ }
- if (configURL == null) {
- throw new IllegalStateException("Cannot fine resource: " + this.config);
- }
+ ValueParam jndiName = initParams.getValueParam(PARAM_JNDI_NAME_OPTION);
+ ValueParam realmNameValueParam = initParams.getValueParam(REALM_NAME_OPTION);
+ ValueParam apiCacheConfig = initParams.getValueParam(CACHE_CONFIG_API_OPTION);
+ ValueParam storeCacheConfig = initParams.getValueParam(CACHE_CONFIG_STORE_OPTION);
+ ValueParam useSecureRandomService = initParams.getValueParam(PARAM_USE_SECURE_RANDOM_SERVICE);
- this.configMD = JAXB2IdentityConfiguration.createConfigurationMetaData(confManager
- .getInputStream(this.config));
+ this.idmHibernateService = hibernateService;
- identityConfiguration = new IdentityConfigurationImpl().configure(this.configMD);
+ if (configValueParam == null && jndiName == null) {
+ throw new IllegalStateException("Either '" + PARAM_CONFIG_OPTION + "' or '" + PARAM_JNDI_NAME_OPTION +
+ "' parameter must " + "be specified");
+ }
+ if (realmNameValueParam != null) {
+ this.realmName = realmNameValueParam.getValue();
+ }
- identityConfiguration.getIdentityConfigurationRegistry().register(hibernateService.getSessionFactory(),
- "hibernateSessionFactory");
+ if (configValueParam != null) {
+ this.config = configValueParam.getValue();
+ URL configURL = confManager.getURL(this.config);
- if (apiCacheConfig != null) {
- log.warn("The parameter 'apiCacheProvider' has been deprecated. It has been replaced by caches in Organization Service top layer. Thus, the parameter should be removed.");
+ if (configURL == null) {
+ throw new IllegalStateException("Cannot fine resource: " + this.config);
+ }
- InputStream configStream = confManager.getInputStream(apiCacheConfig.getValue());
+ this.configMD = JAXB2IdentityConfiguration.createConfigurationMetaData(confManager.getInputStream(this.config));
+ identityConfiguration = new IdentityConfigurationImpl().configure(this.configMD);
+ identityConfiguration.getIdentityConfigurationRegistry()
+ .register(hibernateService.getSessionFactory(),
+ "hibernateSessionFactory");
- if (configStream == null) {
- throw new IllegalArgumentException("Infinispan configuration InputStream is null");
- }
+ if (apiCacheConfig != null) {
+ log.warn("The parameter 'apiCacheProvider' has been deprecated. It has been replaced by caches in Organization Service top layer. Thus, the parameter should be removed.");
- configStream.close();
- }
+ InputStream configStream = confManager.getInputStream(apiCacheConfig.getValue());
- if (storeCacheConfig != null) {
- log.warn("The parameter 'storeCacheProvider' has been deprecated. It has been replaced by caches in Organization Service top layer. Thus, the parameter should be removed.");
+ if (configStream == null) {
+ throw new IllegalArgumentException("Infinispan configuration InputStream is null");
+ }
+ configStream.close();
+ }
- InputStream configStream = confManager.getInputStream(storeCacheConfig.getValue());
+ if (storeCacheConfig != null) {
+ log.warn("The parameter 'storeCacheProvider' has been deprecated. It has been replaced by caches in Organization Service top layer. Thus, the parameter should be removed.");
- if (configStream == null) {
- throw new IllegalArgumentException("Infinispan configuration InputStream is null");
- }
- }
+ InputStream configStream = confManager.getInputStream(storeCacheConfig.getValue());
- if (useSecureRandomService != null && "true".equals(useSecureRandomService.getValue())) {
- SecureRandomProvider secureRandomProvider = (SecureRandomProvider)exoContainerContext.getContainer().getComponentInstanceOfType(SecureRandomProvider.class);
- identityConfiguration.getIdentityConfigurationRegistry().register(secureRandomProvider, DatabaseReadingSaltEncoder.DEFAULT_SECURE_RANDOM_PROVIDER_REGISTRY_NAME);
- }
- } else {
- identitySessionFactory = (IdentitySessionFactory) new InitialContext().lookup(jndiName.getValue());
+ if (configStream == null) {
+ throw new IllegalArgumentException("Infinispan configuration InputStream is null");
+ }
}
+ if (useSecureRandomService != null && "true".equals(useSecureRandomService.getValue())) {
+ SecureRandomProvider secureRandomProvider = ExoContainerContext.getService(SecureRandomProvider.class);
+ if (secureRandomProvider != null) {
+ identityConfiguration.getIdentityConfigurationRegistry()
+ .register(secureRandomProvider,
+ DatabaseReadingSaltEncoder.DEFAULT_SECURE_RANDOM_PROVIDER_REGISTRY_NAME);
+ }
+ }
+ } else {
+ identitySessionFactory = (IdentitySessionFactory) new InitialContext().lookup(jndiName.getValue());
+ }
}
+ @Override
public void start() {
- if (identitySessionFactory == null) {
- try {
- identitySessionFactory = identityConfiguration.buildIdentitySessionFactory();
- } catch (IdentityConfigurationException e) {
- throw new RuntimeException(e);
- }
+ if (identitySessionFactory == null) {
+ try {
+ identitySessionFactory = identityConfiguration.buildIdentitySessionFactory();
+ } catch (IdentityConfigurationException e) {
+ throw new IllegalStateException(String.format("Error building configuration: %s", this.config), e);
}
+ }
}
- public void stop() {
- }
-
+ @Override
public IdentitySessionFactory getIdentitySessionFactory() {
return identitySessionFactory;
}
+ @Override
public IdentitySession getIdentitySession() throws Exception {
if(getIdentitySessionFactory() != null) {
return getIdentitySessionFactory().getCurrentIdentitySession(realmName);
@@ -206,6 +187,7 @@ public IdentitySession getIdentitySession() throws Exception {
}
}
+ @Override
public IdentitySession getIdentitySession(String realm) throws Exception {
if (realm == null) {
throw new IllegalArgumentException("Realm name cannot be null");
@@ -226,16 +208,17 @@ public ExtendedAttributeManager getExtendedAttributeManager() throws Exception {
return this.extendedAttributeManager;
}
- public String getRealmName() {
- return realmName;
+ @Override
+ public IdentityConfigurationMetaData getConfigMD() {
+ return this.configMD;
}
- public HibernateService getHibernateService() {
- return hibernateService;
+ public String getRealmName() {
+ return realmName;
}
- public IdentityConfigurationMetaData getConfigMD() {
- return this.configMD;
+ public IdmHibernateService getHibernateService() {
+ return idmHibernateService;
}
public void setConfigMD(IdentityConfigurationMetaData configMD) {
diff --git a/component/identity/src/test/java/org/exoplatform/services/organization/TestBootstrap.java b/component/identity/src/test/java/org/exoplatform/services/organization/TestBootstrap.java
index ca696e982f..81171f6f53 100644
--- a/component/identity/src/test/java/org/exoplatform/services/organization/TestBootstrap.java
+++ b/component/identity/src/test/java/org/exoplatform/services/organization/TestBootstrap.java
@@ -24,15 +24,15 @@
import org.exoplatform.component.test.ConfiguredBy;
import org.exoplatform.component.test.ContainerScope;
import org.exoplatform.container.PortalContainer;
-import org.exoplatform.services.database.HibernateService;
+import org.exoplatform.services.organization.idm.IdmHibernateService;
@ConfiguredBy({ @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.identity-configuration-local.xml") })
public class TestBootstrap extends AbstractKernelTest {
public void testWorkspace() throws Exception {
PortalContainer container = PortalContainer.getInstance();
- HibernateService hibernate = (HibernateService) container.getComponentInstanceOfType(HibernateService.class);
- assertNotNull(hibernate);
+ IdmHibernateService idmHibernateService = container.getComponentInstanceOfType(IdmHibernateService.class);
+ assertNotNull(idmHibernateService);
OrganizationService organization = (OrganizationService) container
.getComponentInstanceOfType(OrganizationService.class);
assertNotNull(organization);
diff --git a/component/identity/src/test/java/org/exoplatform/services/organization/TestOrganizationServiceJTA.java b/component/identity/src/test/java/org/exoplatform/services/organization/TestOrganizationServiceJTA.java
deleted file mode 100644
index f3ea0cf95f..0000000000
--- a/component/identity/src/test/java/org/exoplatform/services/organization/TestOrganizationServiceJTA.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2012 eXo Platform SAS.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.exoplatform.services.organization;
-
-import org.exoplatform.component.test.ConfigurationUnit;
-import org.exoplatform.component.test.ConfiguredBy;
-import org.exoplatform.component.test.ContainerScope;
-import org.exoplatform.component.test.KernelLifeCycle;
-import org.junit.ClassRule;
-
-/**
- * Test of OrganizationService with enabled JTA setup for Hibernate
- *
- * @author Marek Posolda
- */
-@ConfiguredBy({
- @ConfigurationUnit(scope = ContainerScope.ROOT, path = "conf/configuration.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "org/exoplatform/services/organization/TestOrganizationService-configuration.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "org/exoplatform/services/organization/TestOrganizationService-jta-configuration.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.identity-configuration-new-user-listener.xml"),
-})
-public class TestOrganizationServiceJTA extends AbstractTestOrganizationService {
- @ClassRule
- public static KernelLifeCycle kernel = new KernelLifeCycle();
-}
diff --git a/component/identity/src/test/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceWrapper.java b/component/identity/src/test/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceWrapper.java
deleted file mode 100644
index 0402660ba0..0000000000
--- a/component/identity/src/test/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceWrapper.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * This file is part of the Meeds project (https://meeds.io/).
- * Copyright (C) 2020 - 2022 Meeds Association contact@meeds.io
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 3 of the License, or (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- */
-package org.exoplatform.services.organization.idm;
-
-import org.gatein.common.transaction.JTAUserTransactionLifecycleService;
-
-import org.exoplatform.container.xml.InitParams;
-import org.exoplatform.services.naming.InitialContextInitializer;
-import org.exoplatform.services.organization.cache.OrganizationCacheHandler;
-
-public class PicketLinkIDMOrganizationServiceWrapper extends PicketLinkIDMOrganizationServiceImpl {
-
- public PicketLinkIDMOrganizationServiceWrapper(InitParams params,
- PicketLinkIDMService idmService,
- JTAUserTransactionLifecycleService jtaTransactionLifecycleService,
- OrganizationCacheHandler organizationCacheHandler,
- InitialContextInitializer initialContextInitializer)
- throws Exception {
- super(params, idmService, jtaTransactionLifecycleService, organizationCacheHandler);
- }
-
- public PicketLinkIDMOrganizationServiceWrapper(InitParams params,
- PicketLinkIDMService idmService,
- OrganizationCacheHandler organizationCacheHandler,
- InitialContextInitializer initialContextInitializer)
- throws Exception {
- super(params, idmService, null, organizationCacheHandler);
- }
-
- @Override
- public void start() {// NOSONAR
- super.start();
- }
-}
diff --git a/component/identity/src/test/resources/conf/cache/infinispan.xml b/component/identity/src/test/resources/conf/cache/infinispan.xml
deleted file mode 100644
index facd1f365d..0000000000
--- a/component/identity/src/test/resources/conf/cache/infinispan.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/identity/src/test/resources/conf/exo.portal.component.identity-configuration-local.xml b/component/identity/src/test/resources/conf/exo.portal.component.identity-configuration-local.xml
index 7c5cc9c5fa..f2c1e966e2 100644
--- a/component/identity/src/test/resources/conf/exo.portal.component.identity-configuration-local.xml
+++ b/component/identity/src/test/resources/conf/exo.portal.component.identity-configuration-local.xml
@@ -38,7 +38,7 @@
org.exoplatform.services.organization.OrganizationService
- org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceWrapper
+ org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl
init.service.listener
@@ -572,9 +572,7 @@
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
diff --git a/component/identity/src/test/resources/conf/exo.portal.component.identity-external-ldap-store-configuration.xml b/component/identity/src/test/resources/conf/exo.portal.component.identity-external-ldap-store-configuration.xml
index a218c11c71..9ae0ca779a 100644
--- a/component/identity/src/test/resources/conf/exo.portal.component.identity-external-ldap-store-configuration.xml
+++ b/component/identity/src/test/resources/conf/exo.portal.component.identity-external-ldap-store-configuration.xml
@@ -93,7 +93,7 @@
org.exoplatform.services.organization.OrganizationService
- org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceWrapper
+ org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl
init.service.listener
@@ -200,9 +200,7 @@
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
diff --git a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-configuration.xml b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-configuration.xml
index 1b42d5c52c..73329e3b84 100644
--- a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-configuration.xml
+++ b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-configuration.xml
@@ -33,7 +33,7 @@
org.exoplatform.services.organization.OrganizationService
- org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceWrapper
+ org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl
configuration
@@ -77,9 +77,7 @@
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
diff --git a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-parameterized-configuration.xml b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-parameterized-configuration.xml
index 3f5b068c91..ff2223fe8b 100644
--- a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-parameterized-configuration.xml
+++ b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-parameterized-configuration.xml
@@ -93,7 +93,7 @@
org.exoplatform.services.organization.OrganizationService
- org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceWrapper
+ org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl
init.service.listener
@@ -189,9 +189,7 @@
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
diff --git a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-user-only-configuration.xml b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-user-only-configuration.xml
index 0160421321..d86857045b 100644
--- a/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-user-only-configuration.xml
+++ b/component/identity/src/test/resources/conf/exo.portal.component.identity-ldap-user-only-configuration.xml
@@ -33,7 +33,7 @@
org.exoplatform.services.organization.OrganizationService
- org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceWrapper
+ org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl
configuration
@@ -66,9 +66,7 @@
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
diff --git a/component/identity/src/test/resources/conf/portal/cache-configuration-template.xml b/component/identity/src/test/resources/conf/portal/cache-configuration-template.xml
deleted file mode 100644
index 90d12e81d7..0000000000
--- a/component/identity/src/test/resources/conf/portal/cache-configuration-template.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/identity/src/test/resources/conf/standalone/test-tck-configuration.xml b/component/identity/src/test/resources/conf/standalone/test-tck-configuration.xml
index c5ea965850..109083eb1e 100644
--- a/component/identity/src/test/resources/conf/standalone/test-tck-configuration.xml
+++ b/component/identity/src/test/resources/conf/standalone/test-tck-configuration.xml
@@ -29,7 +29,6 @@
jar:/conf/base-root-configuration.xml
jar:/conf/base-portal-configuration.xml
jar:/conf/exo.portal.component.settings-configuration.xml
- jar:/conf/exo.portal.component.settings-configuration-local-jta.xml
jar:/conf/exo.portal.component.identity-configuration-local.xml
diff --git a/component/identity/src/test/resources/ldap/infinispan.xml b/component/identity/src/test/resources/ldap/infinispan.xml
deleted file mode 100644
index dcd57cee4a..0000000000
--- a/component/identity/src/test/resources/ldap/infinispan.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/component/identity/src/test/resources/ldap/test-identity-config.xml b/component/identity/src/test/resources/ldap/test-identity-config.xml
index bae4494b9d..7c66245456 100644
--- a/component/identity/src/test/resources/ldap/test-identity-config.xml
+++ b/component/identity/src/test/resources/ldap/test-identity-config.xml
@@ -885,14 +885,6 @@
-
-
-
-
- io.meeds.kernel
- exo.kernel.component.ext.cache.impl.infinispan.v8
-
- test
-
diff --git a/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestDataStorage.java b/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestDataStorage.java
index 774b81c6a7..1aa6d9c54a 100644
--- a/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestDataStorage.java
+++ b/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestDataStorage.java
@@ -26,8 +26,6 @@
import java.util.LinkedList;
import java.util.Random;
-import org.gatein.common.transaction.JTAUserTransactionLifecycleService;
-
import org.exoplatform.commons.exception.ObjectNotFoundException;
import org.exoplatform.component.test.AbstractKernelTest;
import org.exoplatform.component.test.ConfigurationUnit;
@@ -67,8 +65,6 @@
import org.exoplatform.services.organization.Group;
import org.exoplatform.services.organization.GroupHandler;
import org.exoplatform.services.organization.OrganizationService;
-import org.exoplatform.services.organization.User;
-import org.exoplatform.services.organization.UserHandler;
/**
* Created by The eXo Platform SARL Author : Tung Pham thanhtungty@gmail.com Nov
@@ -77,7 +73,6 @@
@ConfiguredBy({
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/portal/configuration.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.portal-configuration-local.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.settings-configuration-local-jta.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "org/exoplatform/portal/mop/navigation/configuration.xml"),
})
public class TestDataStorage extends AbstractKernelTest {
@@ -103,8 +98,6 @@ public class TestDataStorage extends AbstractKernelTest {
/** . */
private OrganizationService org;
- private JTAUserTransactionLifecycleService jtaUserTransactionLifecycleService;
-
public TestDataStorage(String name) {
super(name);
}
@@ -127,7 +120,6 @@ public void onEvent(Event event) throws Exception {
events = new LinkedList();
listenerService = (ListenerService) container.getComponentInstanceOfType(ListenerService.class);
org = container.getComponentInstanceOfType(OrganizationService.class);
- jtaUserTransactionLifecycleService = container.getComponentInstanceOfType(JTAUserTransactionLifecycleService.class);
//
listenerService.addListener(EventType.PAGE_CREATED, listener);
@@ -743,26 +735,6 @@ public void testGroupLayout() throws Exception {
assertNull(group);
}
- public void testJTA() throws Exception {
- jtaUserTransactionLifecycleService.beginJTATransaction();
-
- Page page = new Page();
- page.setPageId("portal::test::searchedpage2");
- pageService.savePage(new PageContext(page.getPageKey(), null));
-
- PageContext pageContext = pageService.loadPage(page.getPageKey());
- pageContext.setState(pageContext.getState().builder().displayName("Juuu2 Ziii2").build());
- pageService.savePage(pageContext);
-
- assertPageFound(0, 10, null, null, null, "Juuu2 Ziii2", "portal::test::searchedpage2");
- jtaUserTransactionLifecycleService.finishJTATransaction();
-
- jtaUserTransactionLifecycleService.beginJTATransaction();
- pageService.destroyPage(pageContext.getKey());
- assertPageNotFound(0, 10, null, null, null, "Juuu2 Ziii2");
- jtaUserTransactionLifecycleService.finishJTATransaction();
- }
-
protected void createSite(SiteType type, String siteName) throws Exception {
ContainerData container = new ContainerData(null,
"testcontainer_" + siteName,
diff --git a/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestModelStorage.java b/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestModelStorage.java
index 4ffcc3e8f5..e799dc6605 100644
--- a/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestModelStorage.java
+++ b/component/portal/src/test/java/org/exoplatform/portal/mop/storage/TestModelStorage.java
@@ -25,7 +25,6 @@
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/portal/configuration.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/standalone/portal-configuration.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.portal-configuration-local.xml"),
- @ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/exo.portal.component.settings-configuration-local-jta.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "org/exoplatform/portal/mop/navigation/configuration.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "org/exoplatform/portal/config/conf/configuration.xml"),
@ConfigurationUnit(scope = ContainerScope.PORTAL, path = "conf/portal/test.mop.portal.configuration.xml")
diff --git a/component/test/core/pom.xml b/component/test/core/pom.xml
index 8583e821e7..d76a4ad969 100644
--- a/component/test/core/pom.xml
+++ b/component/test/core/pom.xml
@@ -92,6 +92,12 @@
org.hsqldb
hsqldb
+
+ commons-dbcp
+ commons-dbcp
+
+ compile
+
diff --git a/component/test/core/src/main/resources/conf/base-portal-configuration.xml b/component/test/core/src/main/resources/conf/base-portal-configuration.xml
index 864b065dfb..bb07018560 100644
--- a/component/test/core/src/main/resources/conf/base-portal-configuration.xml
+++ b/component/test/core/src/main/resources/conf/base-portal-configuration.xml
@@ -37,6 +37,4 @@
- org.exoplatform.services.cache.ExoCacheFactory
-
diff --git a/component/test/core/src/test/java/org/exoplatform/component/test/BootstrapTestCase.java b/component/test/core/src/test/java/org/exoplatform/component/test/BootstrapTestCase.java
index 9f141a1e3e..468a8e594d 100644
--- a/component/test/core/src/test/java/org/exoplatform/component/test/BootstrapTestCase.java
+++ b/component/test/core/src/test/java/org/exoplatform/component/test/BootstrapTestCase.java
@@ -26,6 +26,7 @@
import javax.naming.InitialContext;
import javax.sql.DataSource;
+import org.exoplatform.commons.InitialContextInitializer2;
import org.exoplatform.container.PortalContainer;
import org.exoplatform.container.component.RequestLifeCycle;
import org.exoplatform.services.naming.InitialContextInitializer;
@@ -52,8 +53,10 @@ public void testRequestLifeCycle() {
}
public void testDataSource() throws Exception {
- PortalContainer container = PortalContainer.getInstance();
- container.getComponentInstanceOfType(InitialContextInitializer.class);
+ InitialContextInitializer initialContextInitializer = PortalContainer.getInstance().getComponentInstanceOfType(InitialContextInitializer.class);
+ if (initialContextInitializer instanceof InitialContextInitializer2 startable) {
+ startable.start();
+ }
DataSource ds = (DataSource) new InitialContext().lookup("jdbcexo");
assertNotNull(ds);
Connection conn = ds.getConnection();
diff --git a/component/test/core/src/test/resources/conf/test-jdbc-configuration.xml b/component/test/core/src/test/resources/conf/test-jdbc-configuration.xml
index 85b59c4f8a..3c9b133d04 100644
--- a/component/test/core/src/test/resources/conf/test-jdbc-configuration.xml
+++ b/component/test/core/src/test/resources/conf/test-jdbc-configuration.xml
@@ -28,7 +28,7 @@
org.exoplatform.services.naming.InitialContextInitializer
- org.exoplatform.services.naming.InitialContextInitializer
+ org.exoplatform.commons.InitialContextInitializer2
default-properties
diff --git a/component/web/resources/src/main/java/org/gatein/portal/controller/resource/ScriptLoader.java b/component/web/resources/src/main/java/org/gatein/portal/controller/resource/ScriptLoader.java
index d50e789e37..86590ee1d8 100644
--- a/component/web/resources/src/main/java/org/gatein/portal/controller/resource/ScriptLoader.java
+++ b/component/web/resources/src/main/java/org/gatein/portal/controller/resource/ScriptLoader.java
@@ -178,8 +178,7 @@ private String minify(String sourceName, Reader reader, List minifiedRea
SourceFile[] inputs = new SourceFile[] { SourceFile.fromCode(sourceName, code.toString()) };
com.google.javascript.jscomp.Compiler compiler = new Compiler();
- compiler.setErrorManager(new LoggerErrorManager(java.util.logging.Logger.getLogger(ResourceRequestHandler.class
- .getName())));
+ compiler.setErrorManager(new LoggerErrorManager(java.util.logging.Logger.getLogger(ScriptLoader.class.getName())));
Result res = compiler.compile(AbstractCommandLineRunner.getBuiltinExterns(CompilerOptions.Environment.BROWSER),
Arrays.asList(inputs),
options);
diff --git a/web/portal/src/main/webapp/WEB-INF/conf/common/common-configuration.xml b/web/portal/src/main/webapp/WEB-INF/conf/common/common-configuration.xml
index 4876c6b08b..3dd781622a 100644
--- a/web/portal/src/main/webapp/WEB-INF/conf/common/common-configuration.xml
+++ b/web/portal/src/main/webapp/WEB-INF/conf/common/common-configuration.xml
@@ -25,25 +25,9 @@
xsi:schemaLocation="http://www.exoplatform.org/xml/ns/kernel_1_2.xsd http://www.exoplatform.org/xml/ns/kernel_1_2.xsd"
xmlns="http://www.exoplatform.org/xml/ns/kernel_1_2.xsd">
-
- org.exoplatform.services.listener.ListenerService
- org.exoplatform.services.listener.ListenerService
-
-
- org.infinispan.transaction.lookup.TransactionManagerLookup
- org.exoplatform.services.transaction.infinispan.JBossStandaloneJTAManagerLookup
-
-
-
- org.exoplatform.services.transaction.TransactionService
- org.exoplatform.services.transaction.infinispan.JBossTransactionsService
-
-
- timeout
- ${gatein.jcr.transaction.timeout:420}
-
-
+ org.exoplatform.services.listener.ListenerService
+ org.exoplatform.services.listener.ListenerService
@@ -248,25 +232,6 @@
-
- org.exoplatform.services.cache.ExoCacheFactory
- org.exoplatform.services.cache.impl.infinispan.ExoCacheFactoryImpl
-
-
- cache.config.template
- ${exo.cache.config.template:jar:/conf/cache/infinispan/local/cache-config.xml}
-
-
- cache.config.template
- ${exo.cache.config.template:jar:/conf/cache/infinispan/cluster/cache-config.xml}
-
-
- cache.async.config.template
- ${exo.cache.async.config.template:jar:/conf/cache/infinispan/cluster/cache-async-config.xml}
-
-
-
-
org.exoplatform.portal.resource.SkinService
org.exoplatform.portal.resource.SkinService
@@ -323,44 +288,4 @@
org.exoplatform.web.security.AuthenticationRegistryImpl
-
- org.exoplatform.services.cache.ExoCacheFactory
-
- addCreator
- addCreator
- org.exoplatform.services.cache.impl.infinispan.ExoCacheCreatorPlugin
- add Exo Cache Creator
-
-
- Generic-insp-cacheCreator
- The generic cache creator
-
-
-
-
-
-
diff --git a/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml b/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml
index 8977fed665..19529de90a 100644
--- a/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml
+++ b/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml
@@ -29,13 +29,7 @@
- org.gatein.common.transaction.JTAUserTransactionLifecycleService
- org.gatein.common.transaction.JTAUserTransactionLifecycleServiceImpl
-
-
- org.exoplatform.services.database.HibernateService
- database:type=HibernateService
- org.exoplatform.services.organization.idm.CustomHibernateServiceImpl
+ org.exoplatform.services.organization.idm.IdmHibernateService
hibernate.properties
@@ -45,28 +39,9 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -196,10 +171,6 @@
-->
-
-
- false
-
@@ -261,75 +232,4 @@
-
- org.exoplatform.services.cache.CacheService
-
- addExoCacheConfig
- addExoCacheConfig
- org.exoplatform.services.cache.ExoCacheConfigPlugin
- add Exo Cache Config
-
-
- portal.User
- Exo Cache cluster configuration for IDM User entity
-
-
-
-
- portal.Profile
- Exo Cache cluster configuration for IDM User Profile entity
-
-
-
-
- portal.Membership
- Exo Cache cluster configuration for IDM Membership entity
-
-
-
-
- portal.Role
- Exo Cache cluster configuration for IDM Membership Type entity
-
-
-
-
- portal.Group
- Exo Cache cluster configuration for IDM Group entity
-
-
-
-
-
-
diff --git a/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml b/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
index a35cf2477d..8bfc6ace98 100644
--- a/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
+++ b/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
@@ -49,131 +49,6 @@
-
- org.exoplatform.services.cache.CacheService
-
-
-
- addExoCacheConfig
- addExoCacheConfig
- org.exoplatform.services.cache.ExoCacheConfigPlugin
- add Exo Cache Config
-
-
-
- commons.SettingService
- The Cache configuration for the setting service
-
-
-
-
- portal.PortletPreferences
- The cache configuration for Portlet Preferences
-
-
-
- portal.NavigationNode
- The Cache configuration for the MOP session Manager
-
-
-
- portal.NavigationService
- The cache configuration for the navigation Trees service
-
-
-
- portal.SiteService
- The cache configuration for Site layout service
-
-
-
- portal.SiteKeysByFilterService
- The cache configuration for Site layout service
-
-
-
- portal.DescriptionService
- The Cache configuration for the description service
-
-
-
- portal.PageService
- The Cache configuration for the page service
-
-
-
-
- portal.TemplateService
- The Cache configuration for the template service
-
-
-
- portal.ResourceBundleData
-
-
-
-
-
-
-
org.exoplatform.services.listener.ListenerService