exo-jcr SVN: r5778 - in jcr/branches/1.14.6-GA-JBAS7: exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/config and 12 other directories.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:35:19 -0500 (Sat, 03 Mar 2012)
New Revision: 5778
Modified:
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/transaction/infinispan/JBossStandaloneJTAManagerLookup.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryContainer.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryServiceImpl.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/config/RepositoryServiceConfigurationImpl.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/SearchManager.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexingConfigurationImpl.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/SearchIndex.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/ext/action/SessionActionCatalog.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/GenericConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OracleConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OraclePoolConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/GenericCQConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OraclePoolConnectionFactory.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableSimpleFileValueStorage.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableTreeFileValueStorage.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupChainImpl.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupManagerImpl.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobRepositoryRestore.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/resource/UnifiedNodeReference.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/listcode/FtpSystemCoderManager.java
jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.statistics/src/main/java/org/exoplatform/services/jcr/statistics/JCRAPIAspectConfig.java
Log:
EXOJCR-1777: applied patches
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryContainer.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryContainer.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryContainer.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -19,6 +19,7 @@
package org.exoplatform.services.jcr.impl;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.container.jmx.MX4JComponentAdapterFactory;
@@ -290,7 +291,7 @@
workspaceContainer.registerComponentImplementation(StandaloneStoragePluginProvider.class);
try
{
- final Class<?> containerType = Class.forName(wsConfig.getContainer().getType());
+ final Class<?> containerType = Tools.forName(wsConfig.getContainer().getType(), RepositoryContainer.class);
workspaceContainer.registerComponentImplementation(containerType);
if (isSystem)
{
@@ -309,7 +310,7 @@
String className = wsConfig.getCache().getType();
if (className != null && className.length() > 0)
{
- workspaceContainer.registerComponentImplementation(Class.forName(className));
+ workspaceContainer.registerComponentImplementation(Tools.forName(className, RepositoryContainer.class));
}
else
workspaceContainer.registerComponentImplementation(LinkedWorkspaceStorageCacheImpl.class);
@@ -330,7 +331,7 @@
{
try
{
- final Class<?> lockPersister = Class.forName(wsConfig.getLockManager().getPersister().getType());
+ final Class<?> lockPersister = Tools.forName(wsConfig.getLockManager().getPersister().getType(), RepositoryContainer.class);
workspaceContainer.registerComponentImplementation(lockPersister);
}
catch (ClassNotFoundException e)
@@ -345,7 +346,7 @@
{
try
{
- final Class<?> lockManagerType = Class.forName(wsConfig.getLockManager().getType());
+ final Class<?> lockManagerType = Tools.forName(wsConfig.getLockManager().getType(), RepositoryContainer.class);
workspaceContainer.registerComponentImplementation(lockManagerType);
}
catch (ClassNotFoundException e)
@@ -376,7 +377,7 @@
{
try
{
- final Class<?> am = Class.forName(wsConfig.getAccessManager().getType());
+ final Class<?> am = Tools.forName(wsConfig.getAccessManager().getType(), RepositoryContainer.class);
workspaceContainer.registerComponentImplementation(am);
}
catch (ClassNotFoundException e)
@@ -393,7 +394,7 @@
// use user defined
try
{
- initilizerType = Class.forName(wsConfig.getInitializer().getType());
+ initilizerType = Tools.forName(wsConfig.getInitializer().getType(), RepositoryContainer.class);
}
catch (ClassNotFoundException e)
{
@@ -655,7 +656,7 @@
}
try
{
- final Class<?> authenticationPolicyClass = Class.forName(config.getAuthenticationPolicy());
+ final Class<?> authenticationPolicyClass = Tools.forName(config.getAuthenticationPolicy(), RepositoryContainer.class);
registerComponentImplementation(authenticationPolicyClass);
}
catch (ClassNotFoundException e)
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryServiceImpl.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryServiceImpl.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/RepositoryServiceImpl.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -19,6 +19,7 @@
package org.exoplatform.services.jcr.impl;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.ExoContainerContext;
import org.exoplatform.container.PortalContainer;
@@ -519,7 +520,7 @@
try
{
- Class<?> listenerType = Class.forName(sk.getListenerClassName());
+ Class<?> listenerType = Tools.forName(sk.getListenerClassName(), this);
wc.registerComponentImplementation(listenerType);
ItemsPersistenceListener listener =
(ItemsPersistenceListener)wc.getComponentInstanceOfType(listenerType);
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/config/RepositoryServiceConfigurationImpl.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/config/RepositoryServiceConfigurationImpl.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/config/RepositoryServiceConfigurationImpl.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -20,6 +20,7 @@
import org.exoplatform.commons.utils.PrivilegedFileHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.configuration.ConfigurationManager;
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.container.xml.ValueParam;
@@ -87,7 +88,7 @@
try
{
Class<ConfigurationPersister> configurationPersisterClass =
- (Class<ConfigurationPersister>)Class.forName(cn);
+ (Class<ConfigurationPersister>)Tools.forName(cn, this);
configurationPersister = configurationPersisterClass.newInstance();
configurationPersister.init(params.getPropertiesParam("working-conf"));
}
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/SearchManager.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/SearchManager.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/SearchManager.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -23,6 +23,7 @@
import org.apache.lucene.search.WildcardQuery;
import org.exoplatform.commons.utils.PrivilegedFileHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainerContext;
import org.exoplatform.container.configuration.ConfigurationManager;
import org.exoplatform.management.annotations.Managed;
@@ -843,7 +844,7 @@
{
try
{
- Class<?> changesFilterClass = Class.forName(changesFilterClassName);
+ Class<?> changesFilterClass = Tools.forName(changesFilterClassName, this);
// Set recoveryFilterUsed, if changes filter implements LocalIndex strategy
if (changesFilterClass != null)
{
@@ -877,7 +878,7 @@
try
{
String queryImplClassName = handler.getQueryClass();
- Object obj = Class.forName(queryImplClassName).newInstance();
+ Object obj = Tools.forName(queryImplClassName, this).newInstance();
if (obj instanceof AbstractQueryImpl)
{
return (AbstractQueryImpl)obj;
@@ -945,8 +946,7 @@
if (changesFilterClassName != null)
{
changesFilterClass =
- (Class<? extends IndexerChangesFilter>)Class.forName(changesFilterClassName, true, this.getClass()
- .getClassLoader());
+ (Class<? extends IndexerChangesFilter>)Tools.forName(changesFilterClassName, this);
}
Constructor<? extends IndexerChangesFilter> constuctor =
changesFilterClass.getConstructor(SearchManager.class, SearchManager.class, QueryHandlerEntry.class,
@@ -1009,7 +1009,7 @@
try
{
- Class<?> qHandlerClass = Class.forName(className, true, this.getClass().getClassLoader());
+ Class<?> qHandlerClass = Tools.forName(className, this);
try
{
// We first try a constructor with the workspace id
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexingConfigurationImpl.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexingConfigurationImpl.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexingConfigurationImpl.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -17,6 +17,7 @@
package org.exoplatform.services.jcr.impl.core.query.lucene;
import org.apache.lucene.analysis.Analyzer;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.core.NamespaceAccessor;
import org.exoplatform.services.jcr.core.nodetype.NodeTypeDataManager;
import org.exoplatform.services.jcr.dataflow.ItemDataConsumer;
@@ -151,7 +152,7 @@
String analyzerClassName = analyzerNode.getAttributes().getNamedItem("class").getNodeValue();
try
{
- Class clazz = Class.forName(analyzerClassName);
+ Class<?> clazz = Tools.forName(analyzerClassName, this);
if (clazz == JcrStandartAnalyzer.class)
{
log.warn("Not allowed to configure " + JcrStandartAnalyzer.class.getName()
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/SearchIndex.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/SearchIndex.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/SearchIndex.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -38,6 +38,7 @@
import org.exoplatform.commons.utils.PrivilegedFileHelper;
import org.exoplatform.commons.utils.PrivilegedSystemHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.configuration.ConfigurationManager;
import org.exoplatform.services.document.DocumentReaderService;
import org.exoplatform.services.jcr.config.QueryHandlerEntry;
@@ -770,8 +771,7 @@
try
{
filterClass =
- (Class<? extends AbstractRecoveryFilter>)Class.forName(recoveryFilterClassName, true, this.getClass()
- .getClassLoader());
+ (Class<? extends AbstractRecoveryFilter>)Tools.forName(recoveryFilterClassName, this);
Constructor<? extends AbstractRecoveryFilter> constuctor = filterClass.getConstructor(SearchIndex.class);
filter = constuctor.newInstance(this);
recoveryFilters.add(filter);
@@ -1738,7 +1738,7 @@
{
try
{
- Class clazz = Class.forName(directoryManagerClass);
+ Class<?> clazz = Tools.forName(directoryManagerClass, this);
if (!DirectoryManager.class.isAssignableFrom(clazz))
{
throw new IOException(directoryManagerClass + " is not a DirectoryManager implementation");
@@ -2369,7 +2369,7 @@
{
try
{
- Class<?> analyzerClass = Class.forName(analyzerClassName);
+ Class<?> analyzerClass = Tools.forName(analyzerClassName, this);
analyzer.setDefaultAnalyzer((Analyzer)analyzerClass.newInstance());
}
catch (Exception e)
@@ -2718,7 +2718,7 @@
{
try
{
- Class clazz = Class.forName(className);
+ Class clazz = Tools.forName(className, this);
if (ExcerptProvider.class.isAssignableFrom(clazz))
{
excerptProviderClass = clazz;
@@ -2776,7 +2776,7 @@
{
try
{
- Class clazz = Class.forName(className);
+ Class clazz = Tools.forName(className, this);
if (IndexingConfiguration.class.isAssignableFrom(clazz))
{
indexingConfigurationClass = clazz;
@@ -2812,7 +2812,7 @@
{
try
{
- Class clazz = Class.forName(className);
+ Class clazz = Tools.forName(className, this);
if (SynonymProvider.class.isAssignableFrom(clazz))
{
synonymProviderClass = clazz;
@@ -2856,7 +2856,7 @@
{
try
{
- Class clazz = Class.forName(className);
+ Class clazz = Tools.forName(className, this);
if (SpellChecker.class.isAssignableFrom(clazz))
{
spellCheckerClass = clazz;
@@ -2959,7 +2959,7 @@
{
try
{
- Class<?> similarityClass = Class.forName(className);
+ Class<?> similarityClass = Tools.forName(className, this);
similarity = (Similarity)similarityClass.newInstance();
}
catch (Exception e)
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/ext/action/SessionActionCatalog.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/ext/action/SessionActionCatalog.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/ext/action/SessionActionCatalog.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.ext.action;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.services.command.action.Action;
import org.exoplatform.services.command.action.ActionCatalog;
@@ -72,7 +73,7 @@
new SessionEventMatcher(getEventTypes(ac.getEventTypes()), getPaths(ac.getPath()), ac.isDeep(),
getWorkspaces(ac.getWorkspace()), getNames(ac.getNodeTypes()), typeDataManager);
- Action action = (Action)Class.forName(ac.getActionClassName()).newInstance();
+ Action action = (Action)Tools.forName(ac.getActionClassName(), this).newInstance();
addAction(matcher, action);
}
catch (Exception e)
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/GenericConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/GenericConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/GenericConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.WorkspaceStorageConnection;
import org.exoplatform.services.jcr.storage.value.ValueStoragePluginProvider;
@@ -171,7 +172,7 @@
try
{
- Class.forName(dbDriver).newInstance();
+ Tools.forName(dbDriver, this).newInstance();
}
catch (InstantiationException e)
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OracleConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OracleConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OracleConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.value.ValueStoragePluginProvider;
@@ -116,8 +117,8 @@
Object cds = null;
try
{
- Class cdsClass = OracleConnectionFactory.class.getClassLoader().loadClass("oracle.jdbc.pool.OracleDataSource");
- Constructor cdsConstructor = cdsClass.getConstructor(new Class[]{});
+ Class<?> cdsClass = Tools.loadClass("oracle.jdbc.pool.OracleDataSource", this);
+ Constructor<?> cdsConstructor = cdsClass.getConstructor(new Class[]{});
cds = cdsConstructor.newInstance(new Object[]{});
// set cache properties
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OraclePoolConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OraclePoolConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/db/OraclePoolConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.value.ValueStoragePluginProvider;
@@ -111,9 +112,8 @@
Object cpool = null;
try
{
- Class cpoolClass =
- OraclePoolConnectionFactory.class.getClassLoader().loadClass("oracle.jdbc.pool.OracleOCIConnectionPool");
- Constructor cpoolConstructor =
+ Class<?> cpoolClass = Tools.loadClass("oracle.jdbc.pool.OracleOCIConnectionPool", this);
+ Constructor<?> cpoolConstructor =
cpoolClass.getConstructor(new Class[]{String.class, String.class, String.class, Properties.class});
cpool = cpoolConstructor.newInstance(new Object[]{this.dbUserName, this.dbPassword, this.dbUrl, null});
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/GenericCQConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/GenericCQConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/GenericCQConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.storage.jdbc.db.GenericConnectionFactory;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.WorkspaceStorageConnection;
@@ -136,7 +137,7 @@
try
{
- Class.forName(dbDriver).newInstance();
+ Tools.forName(dbDriver, this).newInstance();
}
catch (InstantiationException e)
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.value.ValueStoragePluginProvider;
@@ -118,8 +119,8 @@
Object cds = null;
try
{
- Class cdsClass = OracleConnectionFactory.class.getClassLoader().loadClass("oracle.jdbc.pool.OracleDataSource");
- Constructor cdsConstructor = cdsClass.getConstructor(new Class[]{});
+ Class<?> cdsClass = Tools.loadClass("oracle.jdbc.pool.OracleDataSource", this);
+ Constructor<?> cdsConstructor = cdsClass.getConstructor(new Class[]{});
cds = cdsConstructor.newInstance(new Object[]{});
// set cache properties
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OraclePoolConnectionFactory.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OraclePoolConnectionFactory.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OraclePoolConnectionFactory.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.db;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.impl.util.io.FileCleaner;
import org.exoplatform.services.jcr.storage.value.ValueStoragePluginProvider;
@@ -111,9 +112,8 @@
Object cpool = null;
try
{
- Class cpoolClass =
- OraclePoolConnectionFactory.class.getClassLoader().loadClass("oracle.jdbc.pool.OracleOCIConnectionPool");
- Constructor cpoolConstructor =
+ Class<?> cpoolClass = Tools.loadClass("oracle.jdbc.pool.OracleOCIConnectionPool", this);
+ Constructor<?> cpoolConstructor =
cpoolClass.getConstructor(new Class[]{String.class, String.class, String.class, Properties.class});
cpool = cpoolConstructor.newInstance(new Object[]{this.dbUserName, this.dbPassword, this.dbUrl, null});
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.value;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.config.RepositoryConfigurationException;
import org.exoplatform.services.jcr.config.SimpleParameterEntry;
import org.exoplatform.services.jcr.config.ValueStorageEntry;
@@ -97,7 +98,7 @@
try
{
o =
- Class.forName(storageEntry.getType()).getConstructor(FileCleaner.class)
+ Tools.forName(storageEntry.getType(), this).getConstructor(FileCleaner.class)
.newInstance(holder.getFileCleaner());
}
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableSimpleFileValueStorage.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableSimpleFileValueStorage.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableSimpleFileValueStorage.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.value.fs;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.config.RepositoryConfigurationException;
import org.exoplatform.services.jcr.impl.storage.value.ValueDataResourceHolder;
import org.exoplatform.services.jcr.impl.storage.value.cas.ValueContentAddressStorage;
@@ -58,7 +59,7 @@
// get other vcas specific props and make VCAS
try
{
- vcas = (ValueContentAddressStorage)Class.forName(vcasType).newInstance();
+ vcas = (ValueContentAddressStorage)Tools.forName(vcasType, this).newInstance();
}
catch (Exception e)
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableTreeFileValueStorage.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableTreeFileValueStorage.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/fs/CASableTreeFileValueStorage.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.impl.storage.value.fs;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.config.RepositoryConfigurationException;
import org.exoplatform.services.jcr.impl.storage.value.ValueDataResourceHolder;
import org.exoplatform.services.jcr.impl.storage.value.cas.ValueContentAddressStorage;
@@ -59,7 +60,7 @@
// get other vcas specific props and make VCAS
try
{
- vcas = (ValueContentAddressStorage)Class.forName(vcasType).newInstance();
+ vcas = (ValueContentAddressStorage)Tools.forName(vcasType, this).newInstance();
}
catch (Exception e)
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/transaction/infinispan/JBossStandaloneJTAManagerLookup.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/transaction/infinispan/JBossStandaloneJTAManagerLookup.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/transaction/infinispan/JBossStandaloneJTAManagerLookup.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.transaction.infinispan;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.exoplatform.services.transaction.TransactionService;
@@ -97,9 +98,6 @@
*/
private static Class<?> loadClassStrict(String classname) throws ClassNotFoundException
{
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- if (cl == null)
- cl = ClassLoader.getSystemClassLoader();
- return cl.loadClass(classname);
+ return Tools.loadClass(classname, JBossStandaloneJTAManagerLookup.class);
}
}
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupChainImpl.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupChainImpl.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupChainImpl.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.ext.backup.impl;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.RepositoryService;
import org.exoplatform.services.jcr.config.RepositoryConfigurationException;
import org.exoplatform.services.jcr.core.ManageableRepository;
@@ -109,7 +110,7 @@
try
{
- this.fullBackup = (AbstractFullBackupJob)Class.forName(fullBackupType).newInstance();
+ this.fullBackup = (AbstractFullBackupJob)Tools.forName(fullBackupType, this).newInstance();
}
catch (Exception e)
{
@@ -121,7 +122,7 @@
{
try
{
- this.incrementalBackup = (AbstractIncrementalBackupJob)Class.forName(incrementalBackupType).newInstance();
+ this.incrementalBackup = (AbstractIncrementalBackupJob)Tools.forName(incrementalBackupType, this).newInstance();
}
catch (Exception e)
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupManagerImpl.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupManagerImpl.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/BackupManagerImpl.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -22,6 +22,7 @@
import org.exoplatform.commons.utils.PrivilegedFileHelper;
import org.exoplatform.commons.utils.PrivilegedSystemHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainerContext;
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.container.xml.PropertiesParam;
@@ -719,11 +720,11 @@
try
{
- if ((Class.forName(log.getFullBackupType()).equals(FullBackupJob.class)))
+ if ((Tools.forName(log.getFullBackupType(), this).equals(FullBackupJob.class)))
{
fullbackupType = log.getFullBackupType();
}
- else if ((Class.forName(log.getFullBackupType())
+ else if ((Tools.forName(log.getFullBackupType(), this)
.equals(org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class)))
{
fullbackupType = log.getFullBackupType();
@@ -1006,7 +1007,7 @@
WorkspaceInitializerEntry wiEntry = new WorkspaceInitializerEntry();
- if ((Class.forName(fBackupType).equals(FullBackupJob.class)))
+ if ((Tools.forName(fBackupType, this).equals(FullBackupJob.class)))
{
// set the initializer SysViewWorkspaceInitializer
wiEntry.setType(SysViewWorkspaceInitializer.class.getCanonicalName());
@@ -1016,7 +1017,7 @@
wiEntry.setParameters(wieParams);
}
- else if ((Class.forName(fBackupType)
+ else if ((Tools.forName(fBackupType, this)
.equals(org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class)))
{
// set the initializer RdbmsWorkspaceInitializer
@@ -1679,9 +1680,9 @@
boolean isSameConfigRestore = false;
try
{
- if (Class.forName(
- workspacesMapping.get(repositoryEntry.getWorkspaceEntries().get(0).getName()).getFullBackupType()).equals(
- org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class))
+ if (Tools.forName(
+ workspacesMapping.get(repositoryEntry.getWorkspaceEntries().get(0).getName()).getFullBackupType(), this)
+ .equals(org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class))
{
String newConf = new JsonGeneratorImpl().createJsonObject(repositoryEntry).toString();
String currnetConf =
@@ -1782,7 +1783,7 @@
boolean isSameConfigRestore = false;
try
{
- if (Class.forName(log.getFullBackupType()).equals(
+ if (Tools.forName(log.getFullBackupType(), this).equals(
org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class))
{
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobRepositoryRestore.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobRepositoryRestore.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobRepositoryRestore.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -16,6 +16,7 @@
*/
package org.exoplatform.services.jcr.ext.backup.impl;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.RepositoryService;
import org.exoplatform.services.jcr.config.RepositoryConfigurationException;
import org.exoplatform.services.jcr.config.RepositoryEntry;
@@ -300,11 +301,11 @@
String fullbackupType = null;
try
{
- if ((Class.forName(systemBackupChainLog.getFullBackupType()).equals(FullBackupJob.class)))
+ if ((Tools.forName(systemBackupChainLog.getFullBackupType(), this).equals(FullBackupJob.class)))
{
fullbackupType = systemBackupChainLog.getFullBackupType();
}
- else if ((Class.forName(systemBackupChainLog.getFullBackupType())
+ else if ((Tools.forName(systemBackupChainLog.getFullBackupType(), this)
.equals(org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class)))
{
fullbackupType = systemBackupChainLog.getFullBackupType();
@@ -322,7 +323,7 @@
}
WorkspaceInitializerEntry wiEntry = new WorkspaceInitializerEntry();
- if ((Class.forName(fullbackupType).equals(FullBackupJob.class)))
+ if ((Tools.forName(fullbackupType, this).equals(FullBackupJob.class)))
{
// set the initializer BackupWorkspaceInitializer
wiEntry.setType(BackupWorkspaceInitializer.class.getCanonicalName());
@@ -333,7 +334,7 @@
wiEntry.setParameters(wieParams);
}
- else if ((Class.forName(fullbackupType)
+ else if ((Tools.forName(fullbackupType, this)
.equals(org.exoplatform.services.jcr.ext.backup.impl.rdbms.FullBackupJob.class)))
{
// set the initializer RdbmsBackupWorkspaceInitializer
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/resource/UnifiedNodeReference.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/resource/UnifiedNodeReference.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/resource/UnifiedNodeReference.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -19,6 +19,7 @@
package org.exoplatform.services.jcr.ext.resource;
import org.exoplatform.commons.utils.PrivilegedSystemHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.jcr.datamodel.Identifier;
import java.net.MalformedURLException;
@@ -266,29 +267,7 @@
try
{
String clsName = packagePrefix + "." + JCR_SCHEME + ".Handler";
- Class<?> cls = null;
- try
- {
- cls = Class.forName(clsName);
- }
- catch (ClassNotFoundException e1)
- {
- try
- {
- // try do it with context ClassLoader
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- cls = cl.loadClass(clsName);
- }
- catch (ClassNotFoundException e2)
- {
- // last chance, try use system ClasLoader
- ClassLoader cl = ClassLoader.getSystemClassLoader();
- if (cl != null)
- {
- cls = cl.loadClass(clsName);
- }
- }
- }
+ Class<?> cls = Tools.forName(clsName, UnifiedNodeReference.class);
if (cls != null)
{
handler = (URLStreamHandler)cls.newInstance();
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/listcode/FtpSystemCoderManager.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/listcode/FtpSystemCoderManager.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.ftp/src/main/java/org/exoplatform/services/ftp/listcode/FtpSystemCoderManager.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.ftp.listcode;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.ftp.FtpConst;
import org.exoplatform.services.ftp.config.FtpConfig;
import org.exoplatform.services.log.ExoLogger;
@@ -47,7 +48,8 @@
{
try
{
- FtpSystemCoder coder = (FtpSystemCoder)Class.forName(availableSysemCoders[i][1]).newInstance();
+ FtpSystemCoder coder =
+ (FtpSystemCoder)Tools.forName(availableSysemCoders[i][1], FtpSystemCoderManager.class).newInstance();
return coder;
}
catch (Exception exc)
Modified: jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.statistics/src/main/java/org/exoplatform/services/jcr/statistics/JCRAPIAspectConfig.java
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.statistics/src/main/java/org/exoplatform/services/jcr/statistics/JCRAPIAspectConfig.java 2012-03-03 12:31:37 UTC (rev 5777)
+++ jcr/branches/1.14.6-GA-JBAS7/exo.jcr.component.statistics/src/main/java/org/exoplatform/services/jcr/statistics/JCRAPIAspectConfig.java 2012-03-03 12:35:19 UTC (rev 5778)
@@ -16,6 +16,7 @@
*/
package org.exoplatform.services.jcr.statistics;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.container.xml.ValuesParam;
import org.exoplatform.services.log.ExoLogger;
@@ -68,7 +69,7 @@
try
{
className = (String)o;
- lTargetInterfaces.add(Class.forName(className));
+ lTargetInterfaces.add(Tools.forName(className, this));
}
catch (Exception e)
{
14 years, 1 month
exo-jcr SVN: r5777 - jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:31:37 -0500 (Sat, 03 Mar 2012)
New Revision: 5777
Modified:
jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
Log:
EXOJCR-1777: applied patches
Modified: jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
===================================================================
--- jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 12:29:50 UTC (rev 5776)
+++ jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 12:31:37 UTC (rev 5777)
@@ -1970,14 +1970,14 @@
}
catch (RepositoryException e)
{
- log.error(
+ LOG.error(
"Error indexing subtree " + node.getQPath().getAsString() + ". Check JCR consistency. " + e.getMessage(), e);
return;
}
if (childState == null)
{
- log.error("Error indexing subtree " + node.getQPath().getAsString() + ". Item not found.");
+ LOG.error("Error indexing subtree " + node.getQPath().getAsString() + ". Item not found.");
return;
}
14 years, 1 month
exo-jcr SVN: r5776 - ws/branches/2.2.6-GA-JBAS7.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:29:50 -0500 (Sat, 03 Mar 2012)
New Revision: 5776
Modified:
ws/branches/2.2.6-GA-JBAS7/pom.xml
Log:
EXOJCR-1777: applied patches
Modified: ws/branches/2.2.6-GA-JBAS7/pom.xml
===================================================================
--- ws/branches/2.2.6-GA-JBAS7/pom.xml 2012-03-03 12:29:37 UTC (rev 5775)
+++ ws/branches/2.2.6-GA-JBAS7/pom.xml 2012-03-03 12:29:50 UTC (rev 5776)
@@ -45,8 +45,8 @@
<exo.product.name>exo-ws</exo.product.name>
<exo.product.specification>2.1</exo.product.specification>
- <org.exoplatform.kernel.version>2.3.6-GA</org.exoplatform.kernel.version>
- <org.exoplatform.core.version>2.4.6-GA</org.exoplatform.core.version>
+ <org.exoplatform.kernel.version>2.3.6-GA-JBAS7-SNAPSHOT</org.exoplatform.kernel.version>
+ <org.exoplatform.core.version>2.4.6-GA-JBAS7-SNAPSHOT</org.exoplatform.core.version>
</properties>
<modules>
14 years, 1 month
exo-jcr SVN: r5775 - in core/branches/2.4.6-GA-JBAS7: exo.core.component.database/src/main/java/org/exoplatform/services/database/creator and 1 other directories.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:29:37 -0500 (Sat, 03 Mar 2012)
New Revision: 5775
Modified:
core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/creator/DBCreator.java
core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java
core/branches/2.4.6-GA-JBAS7/pom.xml
Log:
EXOJCR-1777: applied patches
Modified: core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/creator/DBCreator.java
===================================================================
--- core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/creator/DBCreator.java 2012-03-03 12:27:01 UTC (rev 5774)
+++ core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/creator/DBCreator.java 2012-03-03 12:29:37 UTC (rev 5775)
@@ -20,6 +20,7 @@
import org.exoplatform.commons.utils.PrivilegedFileHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.configuration.ConfigurationException;
import org.exoplatform.container.configuration.ConfigurationManager;
import org.exoplatform.container.xml.InitParams;
@@ -481,7 +482,7 @@
Connection conn = null;
try
{
- Class.forName(connectionProperties.get(DRIVER_NAME));
+ Tools.forName(connectionProperties.get(DRIVER_NAME), this);
conn = SecurityHelper.doPrivilegedSQLExceptionAction(new PrivilegedExceptionAction<Connection>()
{
Modified: core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java
===================================================================
--- core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java 2012-03-03 12:27:01 UTC (rev 5774)
+++ core/branches/2.4.6-GA-JBAS7/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java 2012-03-03 12:29:37 UTC (rev 5775)
@@ -21,6 +21,7 @@
import org.exoplatform.commons.exception.ObjectNotFoundException;
import org.exoplatform.commons.utils.PrivilegedSystemHelper;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.container.component.ComponentRequestLifecycle;
@@ -173,7 +174,7 @@
try
{
//load driver class
- Class.forName(conf_.getProperty("hibernate.connection.driver_class")).newInstance();
+ Tools.forName(conf_.getProperty("hibernate.connection.driver_class"), this).newInstance();
}
catch (InstantiationException e)
{
@@ -260,7 +261,7 @@
{
for (String annotation : annotations)
{
- Class clazz = cl.loadClass(annotation);
+ Class<?> clazz = Tools.loadClass(annotation, this);
conf_.addAnnotatedClass(clazz);
}
Modified: core/branches/2.4.6-GA-JBAS7/pom.xml
===================================================================
--- core/branches/2.4.6-GA-JBAS7/pom.xml 2012-03-03 12:27:01 UTC (rev 5774)
+++ core/branches/2.4.6-GA-JBAS7/pom.xml 2012-03-03 12:29:37 UTC (rev 5775)
@@ -39,7 +39,7 @@
<exo.product.specification>2.4</exo.product.specification>
<org.exoplatform.framework.junit.version>1.2.1-GA</org.exoplatform.framework.junit.version>
- <org.exoplatform.kernel.version>2.3.6-GA-JBAS7</org.exoplatform.kernel.version>
+ <org.exoplatform.kernel.version>2.3.6-GA-JBAS7-SNAPSHOT</org.exoplatform.kernel.version>
<!-- Plugins updates -->
<version.source.plugin>2.1.2</version.source.plugin>
14 years, 1 month
exo-jcr SVN: r5774 - in kernel/branches/2.3.6-GA-JBAS7: exo.kernel.commons/src/main/java/org/exoplatform/services/log/impl and 11 other directories.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:27:01 -0500 (Sat, 03 Mar 2012)
New Revision: 5774
Modified:
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/commons/utils/Tools.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/services/log/impl/Log4JConfigurator.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.cache/src/main/java/org/exoplatform/services/cache/impl/CacheServiceImpl.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/CronJob.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/PeriodJob.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/ConcurrentPicoContainer.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/jmx/MX4JComponentAdapter.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/monitor/jvm/J2EEServerInfo.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/util/ContainerUtil.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/xml/ObjectParam.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/services/log/LogConfigurationInitializer.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLCollection.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLMap.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLObject.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/java/org/exoplatform/container/TestExoContainer.java
kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/resources/org/exoplatform/container/test-exo-container.xml
Log:
EXOJCR-1777: applied patches
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/commons/utils/Tools.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/commons/utils/Tools.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/commons/utils/Tools.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,9 @@
*/
package org.exoplatform.commons.utils;
+import org.exoplatform.services.log.ExoLogger;
+import org.exoplatform.services.log.Log;
+
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
@@ -31,7 +34,13 @@
*/
public class Tools
{
+
/**
+ * The logger
+ */
+ private static final Log LOG = ExoLogger.getLogger("org.exoplatform.commons.utils.Tools");
+
+ /**
* All the time zones already registered
*/
private static volatile Map<String, TimeZone> TIME_ZONES = new HashMap<String, TimeZone>();
@@ -191,4 +200,178 @@
}
return tz;
}
+
+ /**
+ * Loads the class using the ClassLoader corresponding to the caller object first,
+ * if class not found we try with Thread's context ClassLoader (TCCL).
+ * If the TCCL doesn't exist or the class still cannot be found, we use the
+ * System class loader.
+ *
+ * @param type FQN of class to load
+ * @param callerObject the object from which we want to load the class
+ * @return Loaded class
+ * @throws ClassNotFoundException
+ */
+ public static Class<?> forName(String type, Object callerObject) throws ClassNotFoundException
+ {
+ return forName(type, callerObject.getClass());
+ }
+
+ /**
+ * Loads the class using the ClassLoader corresponding to the caller class first,
+ * if class not found we try with Thread's context ClassLoader (TCCL).
+ * If the TCCL doesn't exist or the class still cannot be found, we use the
+ * System class loader.
+ *
+ * @param type FQN of class to load
+ * @param callerClass the class from which we want to load the class
+ * @return Loaded class
+ * @throws ClassNotFoundException
+ */
+ public static Class<?> forName(String type, Class<?> callerClass) throws ClassNotFoundException
+ {
+ try
+ {
+ // We first try with the local class loader
+ return Class.forName(type, true, callerClass.getClassLoader());
+ }
+ catch (ClassNotFoundException e)
+ {
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The class " + type + " could not be found in the Class loader of " + callerClass);
+ }
+ // Then we try with the Thread Context Class loader
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
+ try
+ {
+ if (cl != null)
+ {
+ return Class.forName(type, true, cl);
+ }
+ else if (LOG.isTraceEnabled())
+ {
+ LOG.trace("No thread context Class loader could be found to load the class " + type);
+ }
+ }
+ catch (ClassNotFoundException e1)
+ {
+ // ignore me
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The class " + type + " could not be found in the thread context Class loader");
+ }
+ cl = null;
+ }
+ // Finally we test with the system class loader
+ try
+ {
+ cl = ClassLoader.getSystemClassLoader();
+ }
+ catch (Exception e1)
+ {
+ // ignore me
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The system Class loader could not be found to load the class " + type, e1);
+ }
+ }
+ if (cl != null)
+ {
+ return Class.forName(type, true, cl);
+ }
+ else if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The system Class loader could not be found to load the class " + type);
+ }
+ throw e;
+ }
+ }
+
+ /**
+ * Loads the class using the ClassLoader corresponding to the caller object first,
+ * if class not found we try with Thread's context ClassLoader (TCCL).
+ * If the TCCL doesn't exist or the class still cannot be found, we use the
+ * System class loader.
+ *
+ * @param type FQN of class to load
+ * @param callerObject the object from which we want to load the class
+ * @return Loaded class
+ * @throws ClassNotFoundException
+ */
+ public static Class<?> loadClass(String type, Object callerObject) throws ClassNotFoundException
+ {
+ return loadClass(type, callerObject.getClass());
+ }
+
+ /**
+ * Loads the class using the ClassLoader corresponding to the caller class first,
+ * if class not found we try with Thread's context ClassLoader (TCCL).
+ * If the TCCL doesn't exist or the class still cannot be found, we use the
+ * System class loader.
+ *
+ * @param type FQN of class to load
+ * @param callerClass the class from which we want to load the class
+ * @return Loaded class
+ * @throws ClassNotFoundException
+ */
+ public static Class<?> loadClass(String type, Class<?> callerClass) throws ClassNotFoundException
+ {
+ ClassLoader localCl = callerClass.getClassLoader();
+ try
+ {
+ return localCl.loadClass(type);
+ }
+ catch (ClassNotFoundException e)
+ {
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The class " + type + " could not be found in the Class loader of " + callerClass);
+ }
+ // Then we try with the Thread Context Class loader
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
+ try
+ {
+ if (cl != null)
+ {
+ return cl.loadClass(type);
+ }
+ else if (LOG.isTraceEnabled())
+ {
+ LOG.trace("No thread context Class loader could be found to load the class " + type);
+ }
+ }
+ catch (ClassNotFoundException e1)
+ {
+ // ignore me
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The class " + type + " could not be found in the thread context Class loader");
+ }
+ cl = null;
+ }
+ // Finally we test with the system class loader
+ try
+ {
+ cl = ClassLoader.getSystemClassLoader();
+ }
+ catch (Exception e1)
+ {
+ // ignore me
+ if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The system Class loader could not be found to load the class " + type, e1);
+ }
+ }
+ if (cl != null)
+ {
+ return cl.loadClass(type);
+ }
+ else if (LOG.isTraceEnabled())
+ {
+ LOG.trace("The system Class loader could not be found to load the class " + type);
+ }
+ throw e;
+ }
+ }
}
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/services/log/impl/Log4JConfigurator.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/services/log/impl/Log4JConfigurator.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.commons/src/main/java/org/exoplatform/services/log/impl/Log4JConfigurator.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.services.log.impl;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.log.AbstractLogConfigurator;
import java.lang.reflect.Method;
@@ -43,7 +44,7 @@
{
try
{
- Class<?> propertyConfiguratorClass = Class.forName("org.apache.log4j.PropertyConfigurator");
+ Class<?> propertyConfiguratorClass = Tools.forName("org.apache.log4j.PropertyConfigurator", Log4JConfigurator.class);
Method m = propertyConfiguratorClass.getMethod("configure", Properties.class);
m.invoke(null, properties);
}
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.cache/src/main/java/org/exoplatform/services/cache/impl/CacheServiceImpl.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.cache/src/main/java/org/exoplatform/services/cache/impl/CacheServiceImpl.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.cache/src/main/java/org/exoplatform/services/cache/impl/CacheServiceImpl.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.cache.impl;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.management.annotations.ManagedBy;
@@ -47,6 +48,7 @@
* Created by The eXo Platform SAS. Author : Tuan Nguyen
* tuan08(a)users.sourceforge.net Sat, Sep 13, 2003 @ Time: 1:12:22 PM
*/
+@SuppressWarnings("deprecation")
@ManagedBy(CacheServiceManaged.class)
public class CacheServiceImpl implements CacheService
{
@@ -175,9 +177,8 @@
// we assume that we expect to use the default cache factory
try
{
- final ClassLoader cl = Thread.currentThread().getContextClassLoader();
// We check if the given implementation is a known class
- Class implClass = cl.loadClass(safeConfig.getImplementation());
+ Class<?> implClass = Tools.loadClass(safeConfig.getImplementation(), this);
// Implementation is an existing class
if (ExoCache.class.isAssignableFrom(implClass))
{
@@ -259,6 +260,7 @@
/**
* {@inheritDoc}
*/
+ @SuppressWarnings({"rawtypes", "unchecked"})
public ExoCache createCache(ExoCacheConfig config) throws ExoCacheInitException
{
final ExoCache simple = createCacheInstance(config);
@@ -266,11 +268,6 @@
simple.setLabel(config.getLabel());
simple.setMaxSize(config.getMaxSize());
simple.setLiveTime(config.getLiveTime());
- // simple.setReplicated(config.isRepicated());
- // simple.setDistributed(config.isDistributed());
- // if (simple.isDistributed()) {
- // simple.addCacheListener(distrbutedListener_);
- // }
simple.setLogEnabled(config.isLogEnabled());
if (simple.isLogEnabled())
{
@@ -285,7 +282,7 @@
* @return a new instance of ExoCache
* @throws ExoCacheInitException if any exception happens while initializing the cache
*/
- @SuppressWarnings("unchecked")
+ @SuppressWarnings("rawtypes")
private ExoCache createCacheInstance(ExoCacheConfig config) throws ExoCacheInitException
{
if (config.getImplementation() == null)
@@ -296,10 +293,9 @@
else
{
// An implementation has been defined
- final ClassLoader cl = Thread.currentThread().getContextClassLoader();
try
{
- final Class clazz = cl.loadClass(config.getImplementation());
+ final Class<?> clazz = Tools.loadClass(config.getImplementation(), this);
return (ExoCache)clazz.newInstance();
}
catch (ExceptionInInitializerError e)
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/CronJob.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/CronJob.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/CronJob.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.services.scheduler;
import org.exoplatform.commons.utils.ExoProperties;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.component.BaseComponentPlugin;
import org.exoplatform.container.xml.InitParams;
import org.quartz.JobDataMap;
@@ -42,7 +43,7 @@
String jobName = props.getProperty("jobName");
String jobGroup = props.getProperty("groupName");
String jobClass = props.getProperty("job");
- Class clazz = Class.forName(jobClass);
+ Class<?> clazz = Tools.forName(jobClass, this);
jinfo_ = new JobInfo(jobName, jobGroup, clazz);
expression_ = props.getProperty("expression");
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/PeriodJob.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/PeriodJob.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.component.common/src/main/java/org/exoplatform/services/scheduler/PeriodJob.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.services.scheduler;
import org.exoplatform.commons.utils.ExoProperties;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.component.BaseComponentPlugin;
import org.exoplatform.container.xml.InitParams;
import org.quartz.JobDataMap;
@@ -47,7 +48,7 @@
String jobName = props.getProperty("jobName");
String jobGroup = props.getProperty("groupName");
String jobClass = props.getProperty("job");
- Class clazz = Class.forName(jobClass);
+ Class<?> clazz = Tools.forName(jobClass, this);
jinfo_ = new JobInfo(jobName, jobGroup, clazz);
Date startTime = getDate(props.getProperty("startTime"));
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/ConcurrentPicoContainer.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/ConcurrentPicoContainer.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/ConcurrentPicoContainer.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -413,7 +413,7 @@
Map<Object, Object> map = depResolutionCtx.get();
if (map != null)
{
- Object result = map.get(componentType);
+ Object result = map.get(componentAdapter.getComponentKey());
if (result != null)
{
return result;
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/jmx/MX4JComponentAdapter.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/jmx/MX4JComponentAdapter.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/jmx/MX4JComponentAdapter.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.container.jmx;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.component.ComponentLifecycle;
import org.exoplatform.container.component.ComponentPlugin;
@@ -54,7 +55,7 @@
private Log log = ExoLogger.getLogger("exo.kernel.container.MX4JComponentAdapter");
- public MX4JComponentAdapter(Object key, Class implementation)
+ public MX4JComponentAdapter(Object key, Class<?> implementation)
{
super(key, implementation);
}
@@ -83,7 +84,7 @@
if (key instanceof String)
componentKey = (String)key;
else
- componentKey = ((Class)key).getName();
+ componentKey = ((Class<?>)key).getName();
manager = (ConfigurationManager)exocontainer.getComponentInstanceOfType(ConfigurationManager.class);
component = manager.getComponent(componentKey);
if (component != null)
@@ -150,11 +151,11 @@
try
{
- Class pluginClass = Class.forName(plugin.getType());
+ Class<?> pluginClass = Tools.forName(plugin.getType(), this);
ComponentPlugin cplugin = (ComponentPlugin)container.createComponent(pluginClass, plugin.getInitParams());
cplugin.setName(plugin.getName());
cplugin.setDescription(plugin.getDescription());
- Class clazz = component.getClass();
+ Class<?> clazz = component.getClass();
final Method m = getSetMethod(clazz, plugin.getSetMethod(), pluginClass);
if (m == null)
@@ -195,7 +196,7 @@
* @param pluginClass the {@link Class} of the plugin
* @return the "set method" corresponding to the given context
*/
- private Method getSetMethod(Class clazz, String name, Class pluginClass)
+ private Method getSetMethod(Class<?> clazz, String name, Class<?> pluginClass)
{
Method[] methods = clazz.getMethods();
Method bestCandidate = null;
@@ -204,7 +205,7 @@
{
if (name.equals(m.getName()))
{
- Class[] types = m.getParameterTypes();
+ Class<?>[] types = m.getParameterTypes();
if (types != null && types.length == 1 && ComponentPlugin.class.isAssignableFrom(types[0]))
{
int currentDepth = getClosestMatchDepth(pluginClass, types[0]);
@@ -230,7 +231,7 @@
* @param type the class from which the plugin must be assignable
* @return The total amount of times we had to up the hierarchy of the plugin
*/
- private static int getClosestMatchDepth(Class pluginClass, Class type)
+ private static int getClosestMatchDepth(Class<?> pluginClass, Class<?> type)
{
return getClosestMatchDepth(pluginClass, type, 0);
}
@@ -243,7 +244,7 @@
* @param depth the current amount of times that we had to up the hierarchy of the plugin
* @return The total amount of times we had to up the hierarchy of the plugin
*/
- private static int getClosestMatchDepth(Class pluginClass, Class type, int depth)
+ private static int getClosestMatchDepth(Class<?> pluginClass, Class<?> type, int depth)
{
if (pluginClass == null || pluginClass.isAssignableFrom(type))
{
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/monitor/jvm/J2EEServerInfo.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/monitor/jvm/J2EEServerInfo.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/monitor/jvm/J2EEServerInfo.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.container.monitor.jvm;
-import org.exoplatform.commons.utils.PrivilegedSystemHelper;
import org.exoplatform.commons.utils.SecurityHelper;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -27,9 +26,7 @@
import java.lang.management.ManagementFactory;
import java.lang.reflect.Method;
import java.net.URI;
-import java.net.URISyntaxException;
import java.security.PrivilegedAction;
-import java.security.PrivilegedExceptionAction;
import javax.management.MBeanServer;
@@ -71,142 +68,139 @@
public J2EEServerInfo()
{
-
- String jonasHome = PrivilegedSystemHelper.getProperty("jonas.base");
- String jbossHome = PrivilegedSystemHelper.getProperty("jboss.home.dir");
- String jettyHome = PrivilegedSystemHelper.getProperty("jetty.home");
- String websphereHome = PrivilegedSystemHelper.getProperty("was.install.root");
- String weblogicHome = PrivilegedSystemHelper.getProperty("wls.home");
- String glassfishHome = PrivilegedSystemHelper.getProperty("com.sun.aas.instanceRoot");
- String catalinaHome = PrivilegedSystemHelper.getProperty("catalina.home");
- String testHome = PrivilegedSystemHelper.getProperty("maven.exoplatform.dir");
-
- // The name of the configuration directory
- final String confDirName = PrivilegedSystemHelper.getProperty(EXO_CONF_DIR_NAME_PARAM, "exo-conf");
- if (jonasHome != null)
+ SecurityHelper.doPrivilegedAction(new PrivilegedAction<Void>()
{
- serverName_ = "jonas";
- serverHome_ = jonasHome;
- }
- else if (jbossHome != null)
- {
- serverName_ = "jboss";
- serverHome_ = jbossHome;
-
- // try find and use jboss.server.config.url
- // based on http://www.jboss.org/community/docs/DOC-10730
- String jbossConfigUrl = PrivilegedSystemHelper.getProperty("jboss.server.config.url");
- if (jbossConfigUrl != null)
+ public Void run()
{
- try
+
+ String jonasHome = System.getProperty("jonas.base");
+ String jbossHome = System.getProperty("jboss.home.dir");
+ String jettyHome = System.getProperty("jetty.home");
+ String websphereHome = System.getProperty("was.install.root");
+ String weblogicHome = System.getProperty("wls.home");
+ String glassfishHome = System.getProperty("com.sun.aas.instanceRoot");
+ String catalinaHome = System.getProperty("catalina.home");
+ String testHome = System.getProperty("maven.exoplatform.dir");
+
+ // The name of the configuration directory
+ final String confDirName = System.getProperty(EXO_CONF_DIR_NAME_PARAM, "exo-conf");
+ if (jonasHome != null)
{
- exoConfDir_ = new File(new File(new URI(jbossConfigUrl)), confDirName).getAbsolutePath();
+ serverName_ = "jonas";
+ serverHome_ = jonasHome;
}
- catch (SecurityException e)
+ else if (jbossHome != null)
{
- if (LOG.isTraceEnabled())
+ serverName_ = "jboss";
+ serverHome_ = jbossHome;
+
+ // try find and use jboss.server.config.url
+ // based on http://www.jboss.org/community/docs/DOC-10730
+ String jbossConfigUrl = System.getProperty("jboss.server.config.url");
+ if (jbossConfigUrl != null)
{
- LOG.trace("An exception occurred: " + e.getMessage());
+ try
+ {
+ exoConfDir_ = new File(new File(new URI(jbossConfigUrl)), confDirName).getAbsolutePath();
+ }
+ catch (Throwable e)
+ {
+ // don't care about it
+ }
}
- }
- catch (URISyntaxException e)
- {
- if (LOG.isTraceEnabled())
+ else
{
- LOG.trace("An exception occurred: " + e.getMessage());
+ // New variable that exists only since JBoss AS 7
+ String jbossConfigDir = System.getProperty("jboss.server.config.dir");
+ if (jbossConfigDir != null)
+ {
+ try
+ {
+ exoConfDir_ = new File(jbossConfigDir, confDirName).getAbsolutePath();
+ }
+ catch (Throwable e)
+ {
+ // don't care about it
+ }
+ }
}
- }
- catch (IllegalArgumentException e)
- {
- if (LOG.isTraceEnabled())
+ try
{
- LOG.trace("An exception occurred: " + e.getMessage());
+ Class<?> clazz =
+ Thread.currentThread().getContextClassLoader().loadClass("org.jboss.mx.util.MBeanServerLocator");
+ Method m = clazz.getMethod("locateJBoss");
+ mbeanServer = (MBeanServer)m.invoke(null);
}
- }
- }
-
- //
- try
- {
- Class clazz = SecurityHelper.doPrivilegedExceptionAction(new PrivilegedExceptionAction<Class>()
- {
- public Class run() throws Exception
+ catch (ClassNotFoundException ignore)
{
- return Thread.currentThread().getContextClassLoader()
- .loadClass("org.jboss.mx.util.MBeanServerLocator");
+ // We assume that JBoss AS 7 or higher is currently used
+ // since this class has been removed starting from this version
+ // of JBoss AS
+ LOG.debug(ignore.getLocalizedMessage(), ignore);
}
- });
+ catch (Exception ignore)
+ {
+ LOG.error(ignore.getLocalizedMessage(), ignore);
+ }
+ }
+ else if (jettyHome != null)
+ {
+ serverName_ = "jetty";
+ serverHome_ = jettyHome;
+ }
+ else if (websphereHome != null)
+ {
+ serverName_ = "websphere";
+ serverHome_ = websphereHome;
+ }
+ else if (weblogicHome != null)
+ {
+ serverName_ = "weblogic";
+ serverHome_ = weblogicHome;
+ }
+ else if (glassfishHome != null)
+ {
+ serverName_ = "glassfish";
+ serverHome_ = glassfishHome;
+ }
+ else if (catalinaHome != null)
+ {
+ // Catalina has to be processed at the end as other servers may embed it
+ serverName_ = "tomcat";
+ serverHome_ = catalinaHome;
+ }
+ else if (testHome != null)
+ {
+ serverName_ = "test";
+ serverHome_ = testHome;
+ }
+ else
+ {
+ // throw new UnsupportedOperationException("unknown server platform") ;
+ serverName_ = "standalone";
+ serverHome_ = System.getProperty("user.dir");
+ }
+ if (exoConfDir_ == null)
+ {
+ exoConfDir_ = serverHome_ + "/" + confDirName;
+ }
+ if (mbeanServer == null)
+ {
+ mbeanServer = ManagementFactory.getPlatformMBeanServer();
+ }
- Method m = clazz.getMethod("locateJBoss");
- mbeanServer = (MBeanServer)m.invoke(null);
- }
- catch (Exception ignore)
- {
- LOG.error(ignore.getLocalizedMessage(), ignore);
- }
- }
- else if (jettyHome != null)
- {
- serverName_ = "jetty";
- serverHome_ = jettyHome;
- }
- else if (websphereHome != null)
- {
- serverName_ = "websphere";
- serverHome_ = websphereHome;
- }
- else if (weblogicHome != null)
- {
- serverName_ = "weblogic";
- serverHome_ = weblogicHome;
- }
- else if (glassfishHome != null)
- {
- serverName_ = "glassfish";
- serverHome_ = glassfishHome;
- }
- else if (catalinaHome != null)
- {
- // Catalina has to be processed at the end as other servers may embed it
- serverName_ = "tomcat";
- serverHome_ = catalinaHome;
- }
- else if (testHome != null)
- {
- serverName_ = "test";
- serverHome_ = testHome;
- }
- else
- {
- // throw new UnsupportedOperationException("unknown server platform") ;
- serverName_ = "standalone";
- serverHome_ = PrivilegedSystemHelper.getProperty("user.dir");
- }
- if (exoConfDir_ == null)
- {
- exoConfDir_ = serverHome_ + "/" + confDirName;
- }
- if (mbeanServer == null)
- {
- mbeanServer = SecurityHelper.doPrivilegedAction(new PrivilegedAction<MBeanServer>()
- {
- public MBeanServer run()
+ String exoConfHome = System.getProperty(EXO_CONF_PARAM);
+ if (exoConfHome != null && exoConfHome.length() > 0)
{
- return ManagementFactory.getPlatformMBeanServer();
+ LOG.info("Override exo-conf directory '" + exoConfDir_ + "' with location '" + exoConfHome + "'");
+ exoConfDir_ = exoConfHome;
}
- });
- }
- String exoConfHome = PrivilegedSystemHelper.getProperty(EXO_CONF_PARAM);
- if (exoConfHome != null && exoConfHome.length() > 0)
- {
- LOG.info("Override exo-conf directory '" + exoConfDir_ + "' with location '" + exoConfHome
- + "'");
- exoConfDir_ = exoConfHome;
- }
-
- serverHome_ = serverHome_.replace('\\', '/');
- exoConfDir_ = exoConfDir_.replace('\\', '/');
+ serverHome_ = serverHome_.replace('\\', '/');
+ exoConfDir_ = exoConfDir_.replace('\\', '/');
+ return null;
+ }
+ });
}
/**
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/util/ContainerUtil.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/util/ContainerUtil.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/util/ContainerUtil.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -132,7 +132,7 @@
{
try
{
- Class clazz = Class.forName(plugin.getType());
+ Class<?> clazz = Tools.forName(plugin.getType(), ContainerUtil.class);
org.exoplatform.container.ContainerLifecyclePlugin cplugin =
(org.exoplatform.container.ContainerLifecyclePlugin)container
.createComponent(clazz, plugin.getInitParams());
@@ -146,17 +146,16 @@
}
}
- static public void addComponentLifecyclePlugin(ExoContainer container, ConfigurationManager conf)
+ public static void addComponentLifecyclePlugin(ExoContainer container, ConfigurationManager conf)
{
Collection plugins = conf.getConfiguration().getComponentLifecyclePlugins();
Iterator i = plugins.iterator();
- ClassLoader loader = Thread.currentThread().getContextClassLoader();
while (i.hasNext())
{
ComponentLifecyclePlugin plugin = (ComponentLifecyclePlugin)i.next();
try
{
- Class classType = loader.loadClass(plugin.getType());
+ Class<?> classType = Tools.loadClass(plugin.getType(), ContainerUtil.class);
org.exoplatform.container.component.ComponentLifecyclePlugin instance =
(org.exoplatform.container.component.ComponentLifecyclePlugin)classType.newInstance();
container.addComponentLifecylePlugin(instance);
@@ -168,13 +167,12 @@
}
}
- static public void addComponents(ExoContainer container, ConfigurationManager conf)
+ public static void addComponents(ExoContainer container, ConfigurationManager conf)
{
Collection components = conf.getComponents();
if (components == null)
return;
Iterator i = components.iterator();
- ClassLoader loader = Thread.currentThread().getContextClassLoader();
while (i.hasNext())
{
Component component = (Component)i.next();
@@ -182,7 +180,7 @@
String key = component.getKey();
try
{
- Class classType = loader.loadClass(type);
+ Class<?> classType = Tools.loadClass(type, ContainerUtil.class);
if (key == null)
{
if (component.isMultiInstance())
@@ -199,7 +197,7 @@
{
try
{
- Class keyType = loader.loadClass(key);
+ Class<?> keyType = Tools.loadClass(key, ContainerUtil.class);
if (component.isMultiInstance())
{
container.registerComponent(new ConstructorInjectionComponentAdapter(keyType, classType));
@@ -314,5 +312,5 @@
}
}
return props;
- }
+ }
}
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/xml/ObjectParam.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/xml/ObjectParam.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/container/xml/ObjectParam.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.container.xml;
import org.apache.commons.beanutils.PropertyUtils;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -83,7 +84,7 @@
Property prop = null;
try
{
- Class clazz = Class.forName(type);
+ Class<?> clazz = Tools.forName(type, this);
object_ = clazz.newInstance();
for (int i = 0; i < properties_.size(); i++)
{
@@ -157,7 +158,7 @@
fullName.append(".");
fullName.append(className);
- Class clazz = Class.forName(fullName.toString());
+ Class clazz = Tools.forName(fullName.toString(), this);
return clazz.newInstance();
}
}
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/services/log/LogConfigurationInitializer.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/services/log/LogConfigurationInitializer.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/services/log/LogConfigurationInitializer.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.log;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.container.xml.InitParams;
import org.exoplatform.container.xml.PropertiesParam;
import org.exoplatform.container.xml.ValueParam;
@@ -167,7 +168,7 @@
Properties props;
if (configurer != null && properties != null)
{
- LogConfigurator conf = (LogConfigurator)Class.forName(configurer).newInstance();
+ LogConfigurator conf = (LogConfigurator)Tools.forName(configurer, this).newInstance();
props = new Properties();
props.putAll(properties);
conf.configure(props);
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLCollection.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLCollection.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLCollection.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.xml.object;
+import org.exoplatform.commons.utils.Tools;
import org.jibx.runtime.IBindingFactory;
import org.jibx.runtime.IMarshallingContext;
import org.jibx.runtime.IUnmarshallingContext;
@@ -70,7 +71,7 @@
public Collection getCollection() throws Exception
{
- Class clazz = Class.forName(type_);
+ Class<?> clazz = Tools.forName(type_, this);
Collection collection = (Collection)clazz.newInstance();
for (int i = 0; i < list_.size(); i++)
{
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLMap.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLMap.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLMap.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,8 @@
*/
package org.exoplatform.xml.object;
+import org.exoplatform.commons.utils.Tools;
+
import java.util.ArrayList;
import java.util.Iterator;
import java.util.Map;
@@ -73,7 +75,7 @@
public Map getMap() throws Exception
{
- Class clazz = Class.forName(type_);
+ Class<?> clazz = Tools.forName(type_, this);
Map map = (Map)clazz.newInstance();
for (int i = 0; i < listmap.size(); i++)
{
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLObject.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLObject.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/main/java/org/exoplatform/xml/object/XMLObject.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -19,6 +19,7 @@
package org.exoplatform.xml.object;
import org.exoplatform.commons.utils.SecurityHelper;
+import org.exoplatform.commons.utils.Tools;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.jibx.runtime.BindingDirectory;
@@ -172,7 +173,7 @@
public Object toObject() throws Exception
{
- Class clazz = Class.forName(type);
+ Class<?> clazz = Tools.forName(type, this);
Map fields = getFields(clazz);
Object instance = clazz.newInstance();
Iterator i = fields_.values().iterator();
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/java/org/exoplatform/container/TestExoContainer.java
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/java/org/exoplatform/container/TestExoContainer.java 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/java/org/exoplatform/container/TestExoContainer.java 2012-03-03 12:27:01 UTC (rev 5774)
@@ -18,6 +18,7 @@
import org.exoplatform.commons.utils.PropertyManager;
import org.exoplatform.container.component.BaseComponentPlugin;
+import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.container.configuration.ConfigurationManager;
import org.exoplatform.container.jmx.AbstractTestContainer;
import org.exoplatform.container.support.ContainerBuilder;
@@ -185,6 +186,19 @@
assertEquals(container.getComponentInstanceOfType(SOE1.class), soe2.soe1);
}
+ public void testStackOverFlow4()
+ {
+ final RootContainer container = createRootContainer("test-exo-container.xml", "testStackOverflowError");
+ MyService ms = (MyService)container.getComponentInstanceOfType(MyService.class);
+ assertNotNull(ms);
+ assertTrue(ms instanceof MyServiceImpl);
+ MyServiceImpl msi = (MyServiceImpl)ms;
+ assertNotNull(msi.componentPlugin);
+ assertTrue(msi.componentPlugin instanceof MyPlugin);
+ MyPlugin mp = (MyPlugin) msi.componentPlugin;
+ assertTrue(mp.svc == ms);
+ }
+
public void testCyclicRef()
{
final RootContainer container = createRootContainer("test-exo-container.xml", "testCyclicRef");
@@ -1005,4 +1019,44 @@
this.soe1 = (SOE1)ExoContainerContext.getCurrentContainer().getComponentInstanceOfType(SOE1.class);
}
}
+
+ public static class MyPlugin extends BaseComponentPlugin
+ {
+ MySpecialService svc;
+
+ public MyPlugin(MySpecialService svc)
+ {
+ this.svc = svc;
+ }
+ }
+
+ public static interface MyService
+ {
+ public void addPlugin(ComponentPlugin componentPlugin);
+ }
+
+ public static interface MySpecialService extends MyService
+ {
+ }
+
+ public static class MyServiceImpl implements MySpecialService, Startable
+ {
+ ComponentPlugin componentPlugin;
+ public MyServiceImpl()
+ {
+ }
+
+ public void addPlugin(ComponentPlugin componentPlugin)
+ {
+ this.componentPlugin = componentPlugin;
+ }
+
+ public void stop()
+ {
+ }
+
+ public void start()
+ {
+ }
+ }
}
Modified: kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/resources/org/exoplatform/container/test-exo-container.xml
===================================================================
--- kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/resources/org/exoplatform/container/test-exo-container.xml 2012-03-03 12:24:05 UTC (rev 5773)
+++ kernel/branches/2.3.6-GA-JBAS7/exo.kernel.container/src/test/resources/org/exoplatform/container/test-exo-container.xml 2012-03-03 12:27:01 UTC (rev 5774)
@@ -87,4 +87,18 @@
<component profiles="testStartOrder">
<type>org.exoplatform.container.TestExoContainer$C2</type>
</component>
+ <component profiles="testStackOverflowError">
+ <key>org.exoplatform.container.TestExoContainer$MyService</key>
+ <type>org.exoplatform.container.TestExoContainer$MyServiceImpl</type>
+ </component>
+
+ <external-component-plugins profiles="testStackOverflowError">
+ <target-component>org.exoplatform.container.TestExoContainer$MyService</target-component>
+ <component-plugin>
+ <name>test.plugin</name>
+ <set-method>addPlugin</set-method>
+ <type>org.exoplatform.container.TestExoContainer$MyPlugin</type>
+ <description>User - Ticket Authenticator</description>
+ </component-plugin>
+ </external-component-plugins>
</configuration>
\ No newline at end of file
14 years, 1 month
exo-jcr SVN: r5773 - jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:24:05 -0500 (Sat, 03 Mar 2012)
New Revision: 5773
Modified:
jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
Log:
EXOJCR-1778: improved error handling during indexing
Modified: jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
===================================================================
--- jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 12:23:33 UTC (rev 5772)
+++ jcr/branches/1.15.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 12:24:05 UTC (rev 5773)
@@ -1963,12 +1963,22 @@
final AtomicLong count, final NodeData nodeData, final AtomicLong processed) throws RepositoryException,
IOException, InterruptedException
{
- NodeData childState = (NodeData)stateMgr.getItemData(nodeData.getIdentifier());
+ NodeData childState = null;
+ try
+ {
+ childState = (NodeData)stateMgr.getItemData(nodeData.getIdentifier());
+ }
+ catch (RepositoryException e)
+ {
+ log.error(
+ "Error indexing subtree " + node.getQPath().getAsString() + ". Check JCR consistency. " + e.getMessage(), e);
+ return;
+ }
if (childState == null)
{
- handler.getOnWorkspaceInconsistencyHandler().handleMissingChildNode(
- new ItemNotFoundException("Child not found "), handler, nodeData.getQPath(), node, nodeData);
+ log.error("Error indexing subtree " + node.getQPath().getAsString() + ". Item not found.");
+ return;
}
if (nodeData != null)
14 years, 1 month
exo-jcr SVN: r5772 - jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 07:23:33 -0500 (Sat, 03 Mar 2012)
New Revision: 5772
Modified:
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
Log:
EXOJCR-1778: improved error handling during indexing
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 11:02:35 UTC (rev 5771)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/MultiIndex.java 2012-03-03 12:23:33 UTC (rev 5772)
@@ -1933,12 +1933,22 @@
private void createIndex(final Queue<Callable<Void>> tasks, final NodeData node, final ItemDataConsumer stateMgr,
final AtomicLong count, final NodeData nodeData) throws RepositoryException, IOException, InterruptedException
{
- NodeData childState = (NodeData)stateMgr.getItemData(nodeData.getIdentifier());
+ NodeData childState = null;
+ try
+ {
+ childState = (NodeData)stateMgr.getItemData(nodeData.getIdentifier());
+ }
+ catch (RepositoryException e)
+ {
+ log.error(
+ "Error indexing subtree " + node.getQPath().getAsString() + ". Check JCR consistency. " + e.getMessage(), e);
+ return;
+ }
if (childState == null)
{
- handler.getOnWorkspaceInconsistencyHandler().handleMissingChildNode(
- new ItemNotFoundException("Child not found "), handler, nodeData.getQPath(), node, nodeData);
+ log.error("Error indexing subtree " + node.getQPath().getAsString() + ". Item not found.");
+ return;
}
if (nodeData != null)
14 years, 1 month
exo-jcr SVN: r5771 - in jcr/trunk: exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/jbosscache and 7 other directories.
by do-not-reply@jboss.org
Author: areshetnyak
Date: 2012-03-03 06:02:35 -0500 (Sat, 03 Mar 2012)
New Revision: 5771
Modified:
jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/lock/infinispan/ISPNCacheableLockManagerImpl.java
jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/query/ispn/ISPNIndexChangesFilter.java
jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/BufferedISPNCache.java
jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/ISPNCacheWorkspaceStorageCache.java
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/lock/jbosscache/CacheableLockManagerImpl.java
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/jbosscache/JBossCacheIndexChangesFilter.java
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/BufferedJBossCache.java
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/JBossCacheWorkspaceStorageCache.java
jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/TestRepositoryCheckController.java
jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestRepositoryManagement.java
jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceManagement.java
jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceRestore.java
jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/util/TesterConfigurationHelper.java
Log:
EXOJCR-1758 : The problem with eviction and stoping cache on repository stop was fixed.
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/lock/jbosscache/CacheableLockManagerImpl.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/lock/jbosscache/CacheableLockManagerImpl.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/lock/jbosscache/CacheableLockManagerImpl.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -33,8 +33,8 @@
import org.exoplatform.services.jcr.impl.storage.jdbc.DBConstants;
import org.exoplatform.services.jcr.impl.storage.jdbc.DialectDetecter;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory;
+import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory.CacheType;
-import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.exoplatform.services.naming.InitialContextInitializer;
@@ -509,7 +509,9 @@
if (shareable)
{
// The cache cannot be stopped since it can be shared so we evict the root node instead
- cache.evict(lockRoot);
+ cache.getNode(lockRoot).setResident(false);
+ cache.evict(lockRoot, true);
+ cache.getRegion(lockRoot, false).processEvictionQueues();
}
else
{
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/jbosscache/JBossCacheIndexChangesFilter.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/jbosscache/JBossCacheIndexChangesFilter.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/jbosscache/JBossCacheIndexChangesFilter.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -30,8 +30,8 @@
import org.exoplatform.services.jcr.impl.core.query.QueryHandler;
import org.exoplatform.services.jcr.impl.core.query.SearchManager;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory;
+import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory.CacheType;
-import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.jcr.util.IdGenerator;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -231,5 +231,7 @@
{
log.warn("Not all JBoss Cache MBeans were unregistered.");
}
+
+ PrivilegedJBossCacheHelper.stop(cache);
}
}
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/BufferedJBossCache.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/BufferedJBossCache.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/BufferedJBossCache.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -21,6 +21,7 @@
import org.exoplatform.commons.utils.SecurityHelper;
import org.exoplatform.services.jcr.datamodel.ItemData;
import org.exoplatform.services.jcr.impl.core.itemfilters.QPathEntryFilter;
+import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.jboss.cache.Cache;
@@ -748,15 +749,7 @@
*/
public void stop()
{
- PrivilegedAction<Object> action = new PrivilegedAction<Object>()
- {
- public Object run()
- {
- parentCache.stop();
- return null;
- }
- };
- SecurityHelper.doPrivilegedAction(action);
+ PrivilegedJBossCacheHelper.stop(parentCache);
}
public TransactionManager getTransactionManager()
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/JBossCacheWorkspaceStorageCache.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/JBossCacheWorkspaceStorageCache.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/jbosscache/JBossCacheWorkspaceStorageCache.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -51,6 +51,7 @@
import org.exoplatform.services.jcr.impl.dataflow.TransientNodeData;
import org.exoplatform.services.jcr.impl.dataflow.TransientPropertyData;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory;
+import org.exoplatform.services.jcr.jbosscache.PrivilegedJBossCacheHelper;
import org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory.CacheType;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -60,8 +61,8 @@
import org.jboss.cache.CacheStatus;
import org.jboss.cache.Fqn;
import org.jboss.cache.Node;
+import org.jboss.cache.config.EvictionRegionConfig;
import org.jboss.cache.config.Configuration.CacheMode;
-import org.jboss.cache.config.EvictionRegionConfig;
import org.jboss.cache.eviction.ExpirationAlgorithmConfig;
import org.jboss.cache.jmx.JmxRegistrationManager;
import org.picocontainer.Startable;
@@ -124,6 +125,8 @@
private final boolean enabled;
+ private final boolean shareable;
+
public static final String JBOSSCACHE_CONFIG = "jbosscache-configuration";
public static final String JBOSSCACHE_EXPIRATION = "jbosscache-expiration-time";
@@ -562,6 +565,9 @@
enabled = wsConfig.getCache().isEnabled();
+ shareable =
+ wsConfig.getCache().getParameterBoolean(JBOSSCACHE_SHAREABLE, JBOSSCACHE_SHAREABLE_DEFAULT).booleanValue();
+
// create cache using custom factory
ExoJBossCacheFactory<Serializable, Object> factory;
@@ -722,7 +728,53 @@
return null;
}
});
- }
+ }
+
+ if (shareable)
+ {
+ // The cache cannot be stopped since it can be shared so we evict the root node instead
+ cache.getNode(itemsRoot).setResident(false);
+ cache.evict(itemsRoot, true);
+ cache.getRegion(itemsRoot, false).processEvictionQueues();
+
+ cache.getNode(refRoot).setResident(false);;
+ cache.evict(refRoot, true);
+ cache.getRegion(refRoot, false).processEvictionQueues();
+
+ cache.getNode(childNodes).setResident(false);;
+ cache.evict(childNodes, true);
+ cache.getRegion(childNodes, false).processEvictionQueues();
+
+ cache.getNode(childProps).setResident(false);;
+ cache.evict(childProps, true);
+ cache.getRegion(childProps, false).processEvictionQueues();
+
+ cache.getNode(childNodesList).setResident(false);
+ cache.evict(childNodesList, true);
+ cache.getRegion(childNodesList, false).processEvictionQueues();
+
+ cache.getNode(childPropsList).setResident(false);
+ cache.evict(childPropsList, true);
+ cache.getRegion(childPropsList, false).processEvictionQueues();
+
+ cache.getNode(childNodesByPageList).setResident(false);
+ cache.evict(childNodesByPageList, true);
+ cache.getRegion(childNodesByPageList, false).processEvictionQueues();
+
+ cache.getNode(childNodesByPatternList).setResident(false);
+ cache.evict(childNodesByPatternList, true);
+ cache.getRegion(childNodesByPatternList, false).processEvictionQueues();
+
+ cache.getNode(childPropsByPatternList).setResident(false);
+ cache.evict(childPropsByPatternList, true);
+ cache.getRegion(childPropsByPatternList, false).processEvictionQueues();
+
+ }
+ else
+ {
+ PrivilegedJBossCacheHelper.stop(cache);
+ }
+
}
/**
Modified: jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/TestRepositoryCheckController.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/TestRepositoryCheckController.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/TestRepositoryCheckController.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -128,34 +128,54 @@
private void checkConsistentLocksInDataBase(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- lockNode(node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ Node node = addTestNode(repository);
+ lockNode(node);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:lockIsDeep"));
- removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:lockOwner"));
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:lockIsDeep"));
+ removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:lockOwner"));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
private void checkInconsistentLocksInLockTable(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- lockNode(node);
+ Node node = addTestNode(repository);
+ lockNode(node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- clearLockTable(repository);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ clearLockTable(repository);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testCheckValueStorage() throws Exception
@@ -187,14 +207,25 @@
*/
public void testIndexUsecaseWrongDocumentId() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
-
- Node node = addTestNode(repository);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- removeNodeInDB(repository, node);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ Node node = addTestNode(repository);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+
+ removeNodeInDB(repository, node);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -202,14 +233,25 @@
*/
public void testIndexUsecaseMultipleDocuments() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ Node node = addTestNode(repository);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- indexNode(repository, node, ItemState.ADDED);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ indexNode(repository, node, ItemState.ADDED);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -217,14 +259,25 @@
*/
public void testIndexUsecaseDocumentNotExists() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, SINGLE_DB, CACHE_DISABLED);
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ Node node = addTestNode(repository);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- indexNode(repository, node, ItemState.DELETED);
- assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ indexNode(repository, node, ItemState.DELETED);
+ assertTrue(checkController.checkIndex().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -241,33 +294,52 @@
private void checkDBUsecasesTheParentIdIsIdOfThisNode(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ Node node = addTestNode(repository);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- assingItsOwnParent(repository, (ItemImpl)node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ assingItsOwnParent(repository, (ItemImpl)node);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
-
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
private void checkDBUsecasesTheParentIdIsIdOfThisNode2(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- Property prop = addTestProperty(repository, node);
+ Node node = addTestNode(repository);
+ Property prop = addTestProperty(repository, node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- assingItsOwnParent(repository, (ItemImpl)prop);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ assingItsOwnParent(repository, (ItemImpl)prop);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -281,18 +353,28 @@
private void checkSeveralVersionsOfSameItem(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
+ Node node = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- insertPropertyRecord(repository, prop.getInternalIdentifier(), prop.getParentIdentifier(), prop.getName());
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ insertPropertyRecord(repository, prop.getInternalIdentifier(), prop.getParentIdentifier(), prop.getName());
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -306,14 +388,24 @@
private void checkDBUsecasesPropertyWithoutParent(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- insertPropertyRecord(repository, IdGenerator.generate(), IdGenerator.generate(), "testName");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ insertPropertyRecord(repository, IdGenerator.generate(), IdGenerator.generate(), "testName");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -327,18 +419,28 @@
private void checkDBUsecasesIncorrectValueRecords(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
+ Node node = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- updateValueRecord(repository, prop.getInternalIdentifier());
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ updateValueRecord(repository, prop.getInternalIdentifier());
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -352,18 +454,28 @@
private void checkDBUsecasesValueRecordHasNoItemRecord(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
+ Node node = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removeItemRecord(repository, prop.getInternalIdentifier());
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removeItemRecord(repository, prop.getInternalIdentifier());
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -380,30 +492,50 @@
private void checkDBUsecasesPropertiesHasNoSingleValueRecord(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
+ Node node = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)addTestProperty(repository, node);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removeValueRecord(repository, prop.getInternalIdentifier());
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removeValueRecord(repository, prop.getInternalIdentifier());
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
private void checkDBUsecasesPropertiesHasEmptyMultiValueRecord(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- node.setProperty("prop", new String[]{});
- node.save();
+ Node node = addTestNode(repository);
+ node.setProperty("prop", new String[]{});
+ node.save();
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -420,20 +552,30 @@
private void checkDBUsecasesReferencePropertyWithoutReferenceRecord(ManageableRepository repository)
throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- Node node2 = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)node2.setProperty("prop", node);
- node2.save();
+ Node node = addTestNode(repository);
+ Node node2 = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)node2.setProperty("prop", node);
+ node2.save();
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removeReferenceRecord(repository, prop.getInternalIdentifier());
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removeReferenceRecord(repository, prop.getInternalIdentifier());
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -447,16 +589,26 @@
private void checkDBUsecasesNodeHasNotPrimaryTypeProperties(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ Node node = addTestNode(repository);
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:primaryType"));
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removePropertyInDB(repository, (PropertyImpl)node.getProperty("jcr:primaryType"));
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairDataBase("yes");
- assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairDataBase("yes");
+ assertTrue(checkController.checkDataBase().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
/**
@@ -470,20 +622,30 @@
private void checkValueStorageUsecases(ManageableRepository repository) throws Exception
{
- TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
+ try
+ {
+ TesterRepositoryCheckController checkController = new TesterRepositoryCheckController(repository);
- Node node = addTestNode(repository);
- PropertyImpl prop = (PropertyImpl)node.setProperty("prop", new FileInputStream(createBLOBTempFile(300)));
- node.save();
+ Node node = addTestNode(repository);
+ PropertyImpl prop = (PropertyImpl)node.setProperty("prop", new FileInputStream(createBLOBTempFile(300)));
+ node.save();
- assertTrue(checkController.checkValueStorage().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ assertTrue(checkController.checkValueStorage().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
- removeFileFromVS(repository, prop.getInternalIdentifier());
- assertTrue(checkController.checkValueStorage()
- .startsWith(RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
+ removeFileFromVS(repository, prop.getInternalIdentifier());
+ assertTrue(checkController.checkValueStorage().startsWith(
+ RepositoryCheckController.REPORT_NOT_CONSISTENT_MESSAGE));
- checkController.repairValueStorage("yes");
- assertTrue(checkController.checkValueStorage().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ checkController.repairValueStorage("yes");
+ assertTrue(checkController.checkValueStorage().startsWith(RepositoryCheckController.REPORT_CONSISTENT_MESSAGE));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
private Node addTestNode(ManageableRepository repository) throws LoginException, NoSuchWorkspaceException,
Modified: jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestRepositoryManagement.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestRepositoryManagement.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestRepositoryManagement.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -22,9 +22,12 @@
import org.exoplatform.container.xml.PropertiesParam;
import org.exoplatform.services.jcr.JcrImplBaseTest;
import org.exoplatform.services.jcr.RepositoryService;
+import org.exoplatform.services.jcr.config.CacheEntry;
import org.exoplatform.services.jcr.config.RepositoryEntry;
import org.exoplatform.services.jcr.config.RepositoryServiceConfiguration;
+import org.exoplatform.services.jcr.config.SimpleParameterEntry;
import org.exoplatform.services.jcr.config.WorkspaceEntry;
+import org.exoplatform.services.jcr.core.CredentialsImpl;
import org.exoplatform.services.jcr.core.ManageableRepository;
import org.exoplatform.services.jcr.impl.config.JDBCConfigurationPersister;
import org.exoplatform.services.jcr.util.TesterConfigurationHelper;
@@ -36,8 +39,12 @@
import java.io.File;
import java.io.FileOutputStream;
import java.util.ArrayList;
+import java.util.List;
import java.util.concurrent.CountDownLatch;
+import javax.jcr.PathNotFoundException;
+import javax.jcr.Session;
+
/**
* @author <a href="mailto:Sergey.Kabashnyuk@gmail.com">Sergey Kabashnyuk</a>
* @version $Id: TestRepositoryManagement.java 11907 2008-03-13 15:36:21Z ksm $
@@ -56,134 +63,241 @@
private boolean isDefaultWsMultiDb;
private final TesterConfigurationHelper helper;
+
public TestRepositoryManagement()
{
super();
this.helper = TesterConfigurationHelper.getInstance();
}
-
+
public void testAddNewRepository() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
- assertNotNull(repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName()).getRootNode());
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, false, null);
+
+ Session session = null;
+ try
+ {
+ session = repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
+ assertNotNull(session.getRootNode());
+ }
+ finally
+ {
+ if (session != null)
+ {
+ session.logout();
+ }
+ }
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testMarshalUnmarshalRepositoryConfiguration() throws Exception
{
- ManageableRepository newRepository = helper.createRepository(container, false, null);
- final long lockManagerTimeOut =
- newRepository.getConfiguration().getWorkspaceEntries().get(0).getLockManager().getTimeout();
- // 1st marshal configuration
- File tempFile = PrivilegedFileHelper.createTempFile("test-config", "xml");
- PrivilegedFileHelper.deleteOnExit(tempFile);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, false, null);
- IBindingFactory factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
- IMarshallingContext mctx = factory.createMarshallingContext();
+ final long lockManagerTimeOut =
+ repository.getConfiguration().getWorkspaceEntries().get(0).getLockManager().getTimeout();
- FileOutputStream saveStream = new FileOutputStream(tempFile);
- ArrayList<RepositoryEntry> repositoryEntries = new ArrayList<RepositoryEntry>();
- repositoryEntries.add(newRepository.getConfiguration());
+ // 1st marshal configuration
+ File tempFile = PrivilegedFileHelper.createTempFile("test-config", "xml");
+ PrivilegedFileHelper.deleteOnExit(tempFile);
- RepositoryServiceConfiguration newRepositoryServiceConfiguration =
- new RepositoryServiceConfiguration(repositoryService.getConfig().getDefaultRepositoryName(), repositoryEntries);
- mctx.marshalDocument(newRepositoryServiceConfiguration, "ISO-8859-1", null, saveStream);
- saveStream.close();
+ IBindingFactory factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
+ IMarshallingContext mctx = factory.createMarshallingContext();
- // 1st unmarshal
- factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
- IUnmarshallingContext uctx = factory.createUnmarshallingContext();
- RepositoryServiceConfiguration conf =
- (RepositoryServiceConfiguration)uctx.unmarshalDocument(PrivilegedFileHelper.fileInputStream(tempFile), null);
+ FileOutputStream saveStream = new FileOutputStream(tempFile);
+ ArrayList<RepositoryEntry> repositoryEntries = new ArrayList<RepositoryEntry>();
+ repositoryEntries.add(repository.getConfiguration());
- // 1st check
- RepositoryEntry unmarshledRepositoryEntry =
- conf.getRepositoryConfiguration(newRepository.getConfiguration().getName());
- assertEquals(lockManagerTimeOut, unmarshledRepositoryEntry.getWorkspaceEntries().get(0).getLockManager()
- .getTimeout());
+ RepositoryServiceConfiguration newRepositoryServiceConfiguration =
+ new RepositoryServiceConfiguration(repositoryService.getConfig().getDefaultRepositoryName(),
+ repositoryEntries);
+ mctx.marshalDocument(newRepositoryServiceConfiguration, "ISO-8859-1", null, saveStream);
+ saveStream.close();
-
- // 2nd marshal configuration
- tempFile = PrivilegedFileHelper.createTempFile("test-config", "xml");
- PrivilegedFileHelper.deleteOnExit(tempFile);
+ // 1st unmarshal
+ factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
+ IUnmarshallingContext uctx = factory.createUnmarshallingContext();
+ RepositoryServiceConfiguration conf =
+ (RepositoryServiceConfiguration)uctx
+ .unmarshalDocument(PrivilegedFileHelper.fileInputStream(tempFile), null);
- factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
- mctx = factory.createMarshallingContext();
- saveStream = new FileOutputStream(tempFile);
- repositoryEntries = new ArrayList<RepositoryEntry>();
- repositoryEntries.add(newRepository.getConfiguration());
+ // 1st check
+ RepositoryEntry unmarshledRepositoryEntry =
+ conf.getRepositoryConfiguration(repository.getConfiguration().getName());
+ assertEquals(lockManagerTimeOut, unmarshledRepositoryEntry.getWorkspaceEntries().get(0).getLockManager()
+ .getTimeout());
- newRepositoryServiceConfiguration =
- new RepositoryServiceConfiguration(repositoryService.getConfig().getDefaultRepositoryName(), repositoryEntries);
- mctx.marshalDocument(newRepositoryServiceConfiguration, "ISO-8859-1", null, saveStream);
- saveStream.close();
-
- // 2nd unmarshal
- factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
- uctx = factory.createUnmarshallingContext();
- conf = (RepositoryServiceConfiguration)uctx.unmarshalDocument(PrivilegedFileHelper.fileInputStream(tempFile), null);
+ // 2nd marshal configuration
+ tempFile = PrivilegedFileHelper.createTempFile("test-config", "xml");
+ PrivilegedFileHelper.deleteOnExit(tempFile);
- // 2nd check
- unmarshledRepositoryEntry =
- conf.getRepositoryConfiguration(newRepository.getConfiguration().getName());
- assertEquals(lockManagerTimeOut, unmarshledRepositoryEntry.getWorkspaceEntries().get(0).getLockManager()
- .getTimeout());
+ factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
+ mctx = factory.createMarshallingContext();
+ saveStream = new FileOutputStream(tempFile);
+ repositoryEntries = new ArrayList<RepositoryEntry>();
+ repositoryEntries.add(repository.getConfiguration());
+
+ newRepositoryServiceConfiguration =
+ new RepositoryServiceConfiguration(repositoryService.getConfig().getDefaultRepositoryName(),
+ repositoryEntries);
+ mctx.marshalDocument(newRepositoryServiceConfiguration, "ISO-8859-1", null, saveStream);
+ saveStream.close();
+
+ // 2nd unmarshal
+ factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
+ uctx = factory.createUnmarshallingContext();
+ conf =
+ (RepositoryServiceConfiguration)uctx
+ .unmarshalDocument(PrivilegedFileHelper.fileInputStream(tempFile), null);
+
+ // 2nd check
+ unmarshledRepositoryEntry = conf.getRepositoryConfiguration(repository.getConfiguration().getName());
+ assertEquals(lockManagerTimeOut, unmarshledRepositoryEntry.getWorkspaceEntries().get(0).getLockManager()
+ .getTimeout());
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testAddNewRepositoryWithSameName() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
-
+ ManageableRepository repository = null;
try
{
- RepositoryEntry rEntry = helper.createRepositoryEntry(false, null, null, true);
- rEntry.setName(repository.getConfiguration().getName());
+ repository = helper.createRepository(container, false, null);
- helper.createRepository(container, rEntry);
- fail();
+ try
+ {
+ RepositoryEntry rEntry = helper.createRepositoryEntry(false, null, null, true);
+ rEntry.setName(repository.getConfiguration().getName());
+
+ helper.createRepository(container, rEntry);
+ fail();
+ }
+ catch (Exception e)
+ {
+ // ok
+ }
}
- catch (Exception e)
+ finally
{
- // ok
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testCanRemove() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, false, null);
- RepositoryService service = (RepositoryService)container.getComponentInstanceOfType(RepositoryService.class);
+ RepositoryService service = (RepositoryService)container.getComponentInstanceOfType(RepositoryService.class);
- SessionImpl session =
- (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
+ SessionImpl session =
+ (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
- assertFalse(service.canRemoveRepository(repository.getConfiguration().getName()));
- session.logout();
- assertTrue(service.canRemoveRepository(repository.getConfiguration().getName()));
+ assertFalse(service.canRemoveRepository(repository.getConfiguration().getName()));
+ session.logout();
+ assertTrue(service.canRemoveRepository(repository.getConfiguration().getName()));
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testInitNameSpaces() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, false, null);
- SessionImpl session =
- (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
+ SessionImpl session = null;
+ try
+ {
+ session =
+ (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
- assertEquals("http://www.apache.org/jackrabbit/test", session.getNamespaceURI("test"));
- assertEquals("http://www.exoplatform.org/jcr/test/1.0", session.getNamespaceURI("exojcrtest"));
+ assertEquals("http://www.apache.org/jackrabbit/test", session.getNamespaceURI("test"));
+ assertEquals("http://www.exoplatform.org/jcr/test/1.0", session.getNamespaceURI("exojcrtest"));
+ }
+ finally
+ {
+ if (session != null)
+ {
+ session.logout();
+ }
+ }
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testInitNodeTypes() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
+ ManageableRepository repository = null;
+ try
+ {
+ repository = helper.createRepository(container, false, null);
- SessionImpl session =
- (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
+ SessionImpl session = null;
+ try
+ {
+ session =
+ (SessionImpl)repository.login(credentials, repository.getConfiguration().getSystemWorkspaceName());
- // check if nt:folder nodetype exists
- session.getRootNode().addNode("folder", "nt:folder");
- session.save();
+ // check if nt:folder nodetype exists
+ session.getRootNode().addNode("folder", "nt:folder");
+ session.save();
+ }
+ finally
+ {
+ if (session != null)
+ {
+ session.logout();
+ }
+ }
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testRemove() throws Exception
@@ -208,57 +322,82 @@
int theadsCount = 10;
RepositoryCreationThread[] threads = new RepositoryCreationThread[theadsCount];
- CountDownLatch latcher = new CountDownLatch(1);
- for (int i = 0; i < theadsCount; i++)
+ try
{
- threads[i] = new RepositoryCreationThread(latcher);
- threads[i].start();
- }
+ CountDownLatch latcher = new CountDownLatch(1);
- latcher.countDown();
+ for (int i = 0; i < theadsCount; i++)
+ {
+ threads[i] = new RepositoryCreationThread(latcher);
+ threads[i].start();
+ }
- for (int i = 0; i < theadsCount; i++)
- {
- threads[i].join();
- }
+ latcher.countDown();
- PropertiesParam props = new PropertiesParam();
- props.setProperty("dialect", "auto");
- props.setProperty("source-name", "jdbcjcr");
+ for (int i = 0; i < theadsCount; i++)
+ {
+ threads[i].join();
+ }
- JDBCConfigurationPersister persiter = new JDBCConfigurationPersister();
- persiter.init(props);
+ PropertiesParam props = new PropertiesParam();
+ props.setProperty("dialect", "auto");
+ props.setProperty("source-name", "jdbcjcr");
- IBindingFactory factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
- IUnmarshallingContext uctx = factory.createUnmarshallingContext();
- RepositoryServiceConfiguration storedConf =
- (RepositoryServiceConfiguration)uctx.unmarshalDocument(persiter.read(), null);
+ JDBCConfigurationPersister persiter = new JDBCConfigurationPersister();
+ persiter.init(props);
- for (int i = 0; i < theadsCount; i++)
- {
- // test if respository has been created
- ManageableRepository repository = threads[i].getRepository();
- assertNotNull(repository);
+ IBindingFactory factory = BindingDirectory.getFactory(RepositoryServiceConfiguration.class);
+ IUnmarshallingContext uctx = factory.createUnmarshallingContext();
+ RepositoryServiceConfiguration storedConf =
+ (RepositoryServiceConfiguration)uctx.unmarshalDocument(persiter.read(), null);
- // check configuration in persiter
- storedConf.getRepositoryConfiguration(repository.getConfiguration().getName());
-
- // check configuration in RepositoryServic
- assertNotNull(repositoryService.getConfig().getRepositoryConfiguration(repository.getConfiguration().getName()));
-
- // login into newly created repository
- ManageableRepository newRepository = repositoryService.getRepository(repository.getConfiguration().getName());
- assertNotNull(repository.login(credentials, newRepository.getConfiguration().getSystemWorkspaceName())
- .getRootNode());
+ for (int i = 0; i < theadsCount; i++)
+ {
+ // test if respository has been created
+ ManageableRepository repository = threads[i].getRepository();
+ assertNotNull(repository);
+
+ // check configuration in persiter
+ storedConf.getRepositoryConfiguration(repository.getConfiguration().getName());
+
+ // check configuration in RepositoryServic
+ assertNotNull(repositoryService.getConfig().getRepositoryConfiguration(
+ repository.getConfiguration().getName()));
+
+ // login into newly created repository
+ ManageableRepository newRepository =
+ repositoryService.getRepository(repository.getConfiguration().getName());
+
+ Session session = null;
+ try
+ {
+ session = repository.login(credentials, newRepository.getConfiguration().getSystemWorkspaceName());
+ assertNotNull(session.getRootNode());
+ }
+ finally
+ {
+ if (session != null)
+ {
+ session.logout();
+ }
+ }
+ }
}
+ finally
+ {
+ for (int i = 0; i < theadsCount; i++)
+ {
+ helper.removeRepository(container, threads[i].getRepository().getConfiguration().getName());
+ }
+ }
}
private class RepositoryCreationThread extends Thread
{
private CountDownLatch latcher;
- private ManageableRepository repository;
+ private ManageableRepository tRrepository;
RepositoryCreationThread(CountDownLatch latcher)
{
@@ -266,24 +405,142 @@
}
/**
- * {@inheritDoc}
- */
- public void run()
+ * {@inheritDoc}
+ */
+
+
+ public void run()
+ {
+ try
+ {
+ latcher.await();
+ tRrepository = helper.createRepository(container, false, null);
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ public ManageableRepository getRepository()
+ {
+ return tRrepository;
+ }
+ }
+
+ public void testCreateAterRemoveCheckOldContent() throws Exception
+ {
+ ManageableRepository newRepository = null;
+ try
{
+ RepositoryService service = (RepositoryService)container.getComponentInstanceOfType(RepositoryService.class);
+ RepositoryEntry repoEntry = helper.createRepositoryEntry(false, null, null, true);
+
try
{
- latcher.await();
- repository = helper.createRepository(container, false, null);
+ Class
+ .forName("org.exoplatform.services.jcr.impl.dataflow.persistent.infinispan.ISPNCacheWorkspaceStorageCache");
+
+ ArrayList cacheParams = new ArrayList();
+ cacheParams.add(new SimpleParameterEntry("infinispan-configuration",
+ "conf/standalone/cluster/test-infinispan-config.xml"));
+ cacheParams.add(new SimpleParameterEntry("jgroups-configuration", "conf/udp-mux-v3.xml"));
+ cacheParams.add(new SimpleParameterEntry("infinispan-cluster-name", "JCR-cluster-Test"));
+ cacheParams.add(new SimpleParameterEntry("use-distributed-cache", "false"));
+ CacheEntry cacheEntry = new CacheEntry(cacheParams);
+ cacheEntry
+ .setType("org.exoplatform.services.jcr.impl.dataflow.persistent.infinispan.ISPNCacheWorkspaceStorageCache");
+ cacheEntry.setEnabled(true);
+
+ ArrayList<WorkspaceEntry> wsList = repoEntry.getWorkspaceEntries();
+
+ wsList.get(0).setCache(cacheEntry);
+ repoEntry.setWorkspaceEntries(wsList);
}
+ catch (ClassNotFoundException e)
+ {
+ }
+
+ service.createRepository(repoEntry);
+ service.getConfig().retain();
+
+ ManageableRepository repository = service.getRepository(repoEntry.getName());
+
+ // add content
+ Session session =
+ repository.login(new CredentialsImpl("admin", "admin".toCharArray()), repository.getConfiguration()
+ .getSystemWorkspaceName());
+ session.getRootNode().addNode("test");
+ session.save();
+ session.logout();
+
+ // copy repository configuration
+ RepositoryEntry repositoryEntry = helper.copyRepositoryEntry(repository.getConfiguration());
+
+ String newDatasourceName = helper.createDatasource();
+
+ for (WorkspaceEntry ws : repositoryEntry.getWorkspaceEntries())
+ {
+ List<SimpleParameterEntry> parameters = ws.getContainer().getParameters();
+ for (int i = 0; i <= parameters.size(); i++)
+ {
+ SimpleParameterEntry spe = parameters.get(i);
+ if (spe.getName().equals("source-name"))
+ {
+ parameters.add(i, new SimpleParameterEntry(spe.getName(), newDatasourceName));
+ break;
+ }
+ }
+ }
+
+ service.removeRepository(repository.getConfiguration().getName());
+
+ try
+ {
+ service.getRepository(repository.getConfiguration().getName());
+ fail();
+ }
catch (Exception e)
{
- e.printStackTrace();
}
+
+ // create new repository
+ service.createRepository(repositoryEntry);
+ service.getConfig().retain();
+
+ newRepository = service.getRepository(repositoryEntry.getName());
+
+ Session newSession = null;
+ try
+ {
+ newSession =
+ newRepository.login(new CredentialsImpl("admin", "admin".toCharArray()), newRepository
+ .getConfiguration().getSystemWorkspaceName());
+
+ try
+ {
+ newSession.getRootNode().getNode("test");
+ fail("Node 'test' should not exists after remove repository and recreate new.");
+ }
+ catch (PathNotFoundException e)
+ {
+ //ok
+ }
+ }
+ finally
+ {
+ if (newSession != null)
+ {
+ newSession.logout();
+ }
+ }
}
-
- public ManageableRepository getRepository()
+ finally
{
- return repository;
+ if (newRepository != null)
+ {
+ helper.removeRepository(container, newRepository.getConfiguration().getName());
+ }
}
}
}
Modified: jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceManagement.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceManagement.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceManagement.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -52,146 +52,239 @@
// single db test only
public void testAddWorkspaceWithNewDS() throws Exception
{
- ManageableRepository repository = helper.createRepository(container, false, null);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, "not-existed-ds");
- helper.addWorkspace(repository, wsEntry);
- fail();
+ repository = helper.createRepository(container, false, null);
+
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, "not-existed-ds");
+ helper.addWorkspace(repository, wsEntry);
+ fail();
+ }
+ catch (Exception e)
+ {
+ // ok;
+ }
}
- catch (Exception e)
+ finally
{
- // ok;
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testAddWorkspaceWithExistingName() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
- wsEntry.setName(repository.getConfiguration().getSystemWorkspaceName());
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
- helper.addWorkspace(repository, wsEntry);
- fail();
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
+ wsEntry.setName(repository.getConfiguration().getSystemWorkspaceName());
+
+ helper.addWorkspace(repository, wsEntry);
+ fail();
+ }
+ catch (RepositoryConfigurationException e)
+ {
+ // ok;
+ }
}
- catch (RepositoryConfigurationException e)
+ finally
{
- // ok;
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testAddWorkspaceWithIvalidVs() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
- ValueStorageEntry valueStorageEntry = wsEntry.getContainer().getValueStorages().get(0);
-
- ArrayList<SimpleParameterEntry> spe = new ArrayList<SimpleParameterEntry>();
- spe.add(new SimpleParameterEntry("path", "/unknown/path"));
- valueStorageEntry.setParameters(spe);
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
- wsEntry.getContainer().getValueStorages().set(0, valueStorageEntry);
+ ValueStorageEntry valueStorageEntry = wsEntry.getContainer().getValueStorages().get(0);
- helper.addWorkspace(repository, wsEntry);
+ ArrayList<SimpleParameterEntry> spe = new ArrayList<SimpleParameterEntry>();
+ spe.add(new SimpleParameterEntry("path", "/unknown/path"));
+ valueStorageEntry.setParameters(spe);
+
+ wsEntry.getContainer().getValueStorages().set(0, valueStorageEntry);
+
+ helper.addWorkspace(repository, wsEntry);
+ }
+ catch (RepositoryConfigurationException e)
+ {
+ // ok;
+ }
}
- catch (RepositoryConfigurationException e)
+ finally
{
- // ok;
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testCreateWsNoConfig() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
- wsEntry.setContainer(new ContainerEntry(
- "org.exoplatform.services.jcr.impl.storage.jdbc.JDBCWorkspaceDataContainer", new ArrayList()));
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
- helper.addWorkspace(repository, wsEntry);
- fail();
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
+ wsEntry.setContainer(new ContainerEntry(
+ "org.exoplatform.services.jcr.impl.storage.jdbc.JDBCWorkspaceDataContainer", new ArrayList()));
+
+ helper.addWorkspace(repository, wsEntry);
+ fail();
+ }
+ catch (Exception e)
+ {
+ // ok;
+ }
}
- catch (Exception e)
+ finally
{
- // ok;
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testInitNewWS() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
- helper.addWorkspace(repository, wsEntry);
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
- SessionImpl session = (SessionImpl)repository.login(credentials, wsEntry.getName());
- assertNotNull(session.getRootNode());
+ SessionImpl session = null;
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
+ helper.addWorkspace(repository, wsEntry);
+
+ session = (SessionImpl)repository.login(credentials, wsEntry.getName());
+ assertNotNull(session.getRootNode());
+ }
+ catch (RepositoryException e)
+ {
+ e.printStackTrace();
+ fail();
+ }
+ finally
+ {
+ session.logout();
+ }
}
- catch (RepositoryException e)
+ finally
{
- e.printStackTrace();
- fail();
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testMixMultiAndSingleDbWs() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(true, dsName);
- helper.addWorkspace(repository, wsEntry);
- fail();
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
+
+ try
+ {
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(true, dsName);
+ helper.addWorkspace(repository, wsEntry);
+ fail();
+ }
+ catch (Exception e)
+ {
+ // ok;
+ }
}
- catch (Exception e)
+ finally
{
- // ok;
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testRemoveSystemWorkspace() throws Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
-
+ ManageableRepository repository = null;
try
{
- repository.removeWorkspace(repository.getConfiguration().getSystemWorkspaceName());
- fail();
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
+
+ try
+ {
+ repository.removeWorkspace(repository.getConfiguration().getSystemWorkspaceName());
+ fail();
+ }
+ catch (RepositoryException e)
+ {
+ }
}
- catch (RepositoryException e)
+ finally
{
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
}
public void testRemoveWorkspace() throws Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, false, dsName);
- WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
-
- helper.addWorkspace(repository, wsEntry);
- assertEquals(2, repository.getWorkspaceNames().length);
-
- repository.removeWorkspace(wsEntry.getName());
- assertEquals(1, repository.getWorkspaceNames().length);
+ ManageableRepository repository = null;
+ try
+ {
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, false, dsName);
+ WorkspaceEntry wsEntry = helper.createWorkspaceEntry(false, dsName);
+
+ helper.addWorkspace(repository, wsEntry);
+ assertEquals(2, repository.getWorkspaceNames().length);
+
+ repository.removeWorkspace(wsEntry.getName());
+ assertEquals(1, repository.getWorkspaceNames().length);
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
}
Modified: jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceRestore.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceRestore.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/impl/core/TestWorkspaceRestore.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -62,52 +62,74 @@
public void testRestore() throws RepositoryConfigurationException, Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, isDefaultWsMultiDb, dsName);
+ ManageableRepository repository = null;
+ try
+ {
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, isDefaultWsMultiDb, dsName);
- WorkspaceEntry workspaceEntry =
- helper.createWorkspaceEntry(isDefaultWsMultiDb, isDefaultWsMultiDb ? helper.createDatasource() : dsName);
- helper.addWorkspace(repository, workspaceEntry);
+ WorkspaceEntry workspaceEntry =
+ helper.createWorkspaceEntry(isDefaultWsMultiDb, isDefaultWsMultiDb ? helper.createDatasource() : dsName);
+ helper.addWorkspace(repository, workspaceEntry);
- InputStream is = TestWorkspaceManagement.class.getResourceAsStream("/import-export/db1_ws1-20071220_0430.xml");
- repository.importWorkspace(workspaceEntry.getName(), is);
+ InputStream is = TestWorkspaceManagement.class.getResourceAsStream("/import-export/db1_ws1-20071220_0430.xml");
+ repository.importWorkspace(workspaceEntry.getName(), is);
+ }
+ finally
+ {
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
+ }
}
public void testRestoreBadXml() throws Exception
{
- String dsName = helper.createDatasource();
- ManageableRepository repository = helper.createRepository(container, isDefaultWsMultiDb, dsName);
+ ManageableRepository repository = null;
+ try
+ {
+ String dsName = helper.createDatasource();
+ repository = helper.createRepository(container, isDefaultWsMultiDb, dsName);
- WorkspaceEntry workspaceEntry =
- helper.createWorkspaceEntry(isDefaultWsMultiDb, isDefaultWsMultiDb ? helper.createDatasource() : dsName);
- helper.addWorkspace(repository, workspaceEntry);
+ WorkspaceEntry workspaceEntry =
+ helper.createWorkspaceEntry(isDefaultWsMultiDb, isDefaultWsMultiDb ? helper.createDatasource() : dsName);
+ helper.addWorkspace(repository, workspaceEntry);
- Session defSession = repository.login(this.credentials, workspaceEntry.getName());
- Node defRoot = defSession.getRootNode();
+ Session defSession = repository.login(this.credentials, workspaceEntry.getName());
+ Node defRoot = defSession.getRootNode();
- Node node1 = defRoot.addNode("node1");
- node1.setProperty("p1", 2);
- defSession.save();
+ Node node1 = defRoot.addNode("node1");
+ node1.setProperty("p1", 2);
+ defSession.save();
- File content = File.createTempFile("data", ".xml");
- content.deleteOnExit();
- OutputStream os = new BufferedOutputStream(new FileOutputStream(content));
- defSession.exportSystemView(node1.getPath(), os, false, false);
- os.close();
- defSession.logout();
-
- try
- {
- InputStream is = TestWorkspaceManagement.class.getResourceAsStream("/import-export/db1_ws1-20071220_0430.xml");
- repository.importWorkspace(workspaceEntry.getName(), new BufferedInputStream(new FileInputStream(content)));
+ File content = File.createTempFile("data", ".xml");
+ content.deleteOnExit();
+ OutputStream os = new BufferedOutputStream(new FileOutputStream(content));
+ defSession.exportSystemView(node1.getPath(), os, false, false);
+ os.close();
+ defSession.logout();
- fail();
+ try
+ {
+ InputStream is =
+ TestWorkspaceManagement.class.getResourceAsStream("/import-export/db1_ws1-20071220_0430.xml");
+ repository.importWorkspace(workspaceEntry.getName(), new BufferedInputStream(new FileInputStream(content)));
+
+ fail();
+ }
+ catch (RepositoryException e)
+ {
+ // ok
+ }
}
- catch (RepositoryException e)
+ finally
{
- // ok
+ if (repository != null)
+ {
+ helper.removeRepository(container, repository.getConfiguration().getName());
+ }
}
-
}
private void doTestOnWorkspace(String wsName) throws RepositoryException, RepositoryConfigurationException
Modified: jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/util/TesterConfigurationHelper.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/util/TesterConfigurationHelper.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/util/TesterConfigurationHelper.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -33,7 +33,9 @@
import org.exoplatform.services.jcr.config.ValueStorageFilterEntry;
import org.exoplatform.services.jcr.config.WorkspaceEntry;
import org.exoplatform.services.jcr.core.ManageableRepository;
+import org.exoplatform.services.jcr.core.WorkspaceContainerFacade;
import org.exoplatform.services.jcr.impl.core.RepositoryImpl;
+import org.exoplatform.services.jcr.impl.core.SessionRegistry;
import org.exoplatform.services.jcr.impl.storage.jdbc.DialectDetecter;
import org.exoplatform.services.jcr.impl.storage.jdbc.JDBCWorkspaceDataContainer;
import org.exoplatform.services.log.ExoLogger;
@@ -67,6 +69,26 @@
}
/**
+ * Remove repository.
+ * @throws RepositoryConfigurationException
+ */
+ public void removeRepository(ExoContainer container, String repositoryName) throws RepositoryException,
+ RepositoryConfigurationException
+ {
+ RepositoryService service = (RepositoryService)container.getComponentInstanceOfType(RepositoryService.class);
+
+ ManageableRepository mr = service.getRepository(repositoryName);
+ for (String wsName : mr.getWorkspaceNames())
+ {
+ WorkspaceContainerFacade wc = mr.getWorkspaceContainer(wsName);
+ SessionRegistry sessionRegistry = (SessionRegistry)wc.getComponent(SessionRegistry.class);
+ sessionRegistry.closeSessions(wsName);
+ }
+
+ service.removeRepository(repositoryName);
+ }
+
+ /**
* Add new workspace to repository.
*/
public void addWorkspace(ManageableRepository repository, WorkspaceEntry workspaceEntry)
@@ -253,14 +275,35 @@
QueryHandlerEntry qEntry =
new QueryHandlerEntry("org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex", params);
+
// Cache
- ArrayList cacheParams = new ArrayList();
- cacheParams.add(new SimpleParameterEntry("maxSize", "2000"));
- cacheParams.add(new SimpleParameterEntry("liveTime", "20m"));
- CacheEntry cacheEntry = new CacheEntry(cacheParams);
- cacheEntry.setEnabled(cacheEnabled);
- cacheEntry.setType("org.exoplatform.services.jcr.impl.dataflow.persistent.LinkedWorkspaceStorageCacheImpl");
+ CacheEntry cacheEntry = null;
+ try
+ {
+ Class
+ .forName("org.exoplatform.services.jcr.impl.dataflow.persistent.infinispan.ISPNCacheWorkspaceStorageCache");
+
+ //TODO EXOJCR-1784
+ ArrayList cacheParams = new ArrayList();
+ cacheParams.add(new SimpleParameterEntry("maxSize", "2000"));
+ cacheParams.add(new SimpleParameterEntry("liveTime", "20m"));
+ cacheEntry = new CacheEntry(cacheParams);
+ cacheEntry.setEnabled(cacheEnabled);
+ cacheEntry.setType("org.exoplatform.services.jcr.impl.dataflow.persistent.LinkedWorkspaceStorageCacheImpl");
+ }
+ catch (ClassNotFoundException e)
+ {
+ ArrayList cacheParams = new ArrayList();
+ cacheParams.add(new SimpleParameterEntry("jbosscache-configuration",
+ "conf/standalone/test-jbosscache-config.xml"));
+ cacheParams.add(new SimpleParameterEntry("jbosscache-shareable", "true"));
+ cacheEntry = new CacheEntry(cacheParams);
+ cacheEntry
+ .setType("org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache");
+ cacheEntry.setEnabled(cacheEnabled);
+ }
+
// Lock
LockManagerEntry lockManagerEntry = new LockManagerEntry();
lockManagerEntry.putParameterValue("time-out", "15m");
@@ -434,12 +477,13 @@
LockManagerEntry lockManagerEntry = new LockManagerEntry();
lockManagerEntry.setTimeout(900000);
- LockPersisterEntry persisterEntry = new LockPersisterEntry();
- persisterEntry.setType("org.exoplatform.services.jcr.impl.core.lock.FileSystemLockPersister");
- ArrayList lpParams = new ArrayList();
- lpParams.add(new SimpleParameterEntry("path", "target/temp/lock"));
- persisterEntry.setParameters(lpParams);
- lockManagerEntry.setPersister(persisterEntry);
+ LockPersisterEntry lockPersisterEntry = new LockPersisterEntry();
+ lockPersisterEntry.setType("org.exoplatform.services.jcr.impl.core.lock.FileSystemLockPersister");
+ ArrayList<SimpleParameterEntry> lockPersisterParameters = new ArrayList<SimpleParameterEntry>();
+ lockPersisterParameters.add(new SimpleParameterEntry("path", "target/temp/lock/" + wsName));
+ lockPersisterEntry.setParameters(lockPersisterParameters);
+ lockManagerEntry.setPersister(lockPersisterEntry);
+
workspaceEntry.setLockManager(lockManagerEntry);
// workspaceEntry
@@ -468,4 +512,107 @@
return instance;
}
+
+ public RepositoryEntry copyRepositoryEntry(RepositoryEntry configuration)
+ {
+ ArrayList<WorkspaceEntry> workspases = new ArrayList<WorkspaceEntry>();
+
+ for (WorkspaceEntry ws : configuration.getWorkspaceEntries())
+ {
+ workspases.add(copyWorkspaceEntry(ws));
+ }
+
+ RepositoryEntry repository = new RepositoryEntry();
+ repository.setSystemWorkspaceName(configuration.getSystemWorkspaceName());
+ repository.setDefaultWorkspaceName(configuration.getDefaultWorkspaceName());
+ repository.setName(configuration.getName());
+ repository.setSessionTimeOut(configuration.getSessionTimeOut());
+ repository.setAuthenticationPolicy(configuration.getAuthenticationPolicy());
+ repository.setSecurityDomain(configuration.getSecurityDomain());
+
+ for (WorkspaceEntry ws : workspases)
+ {
+ repository.addWorkspace(ws);
+ }
+
+ return repository;
+ }
+
+ private WorkspaceEntry copyWorkspaceEntry(WorkspaceEntry wsEntry)
+ {
+ // container entry
+ ArrayList<SimpleParameterEntry> params = new ArrayList();
+ params.addAll(wsEntry.getContainer().getParameters());
+
+ ContainerEntry containerEntry = new ContainerEntry(wsEntry.getContainer().getType(), (ArrayList)params);
+ containerEntry.setParameters(params);
+
+ // value storage
+ ArrayList<ValueStorageEntry> list = new ArrayList<ValueStorageEntry>();
+ if (wsEntry.getContainer().getValueStorages() != null)
+ {
+ for (ValueStorageEntry vse : wsEntry.getContainer().getValueStorages())
+ {
+ ArrayList<ValueStorageFilterEntry> vsparams = new ArrayList<ValueStorageFilterEntry>();
+
+ for (ValueStorageFilterEntry vsfe : vse.getFilters())
+ {
+ ValueStorageFilterEntry filterEntry = new ValueStorageFilterEntry();
+ filterEntry.setPropertyType(vsfe.getPropertyType());
+ filterEntry.setPropertyName(vsfe.getPropertyName());
+ filterEntry.setMinValueSize(vsfe.getMinValueSize());
+ filterEntry.setAncestorPath(vsfe.getAncestorPath());
+ vsparams.add(filterEntry);
+ }
+
+ ValueStorageEntry valueStorageEntry = new ValueStorageEntry(vse.getType(), vsparams);
+ ArrayList<SimpleParameterEntry> spe = new ArrayList<SimpleParameterEntry>();
+ spe.addAll(vse.getParameters());
+ valueStorageEntry.setId(vse.getId());
+ valueStorageEntry.setParameters(spe);
+ valueStorageEntry.setFilters(vsparams);
+
+ // containerEntry.setValueStorages();
+ containerEntry.setParameters(params);
+ list.add(valueStorageEntry);
+ }
+ }
+
+ containerEntry.setValueStorages(list);
+
+ // Indexer
+ params = new ArrayList();
+ params.addAll(wsEntry.getQueryHandler().getParameters());
+ QueryHandlerEntry qEntry = new QueryHandlerEntry(wsEntry.getQueryHandler().getType(), params);
+
+ // Cache
+ ArrayList cacheParams = new ArrayList();
+ cacheParams.addAll(wsEntry.getCache().getParameters());
+ CacheEntry cacheEntry = new CacheEntry(cacheParams);
+ cacheEntry.setEnabled(wsEntry.getCache().getEnabled());
+ cacheEntry.setType(wsEntry.getCache().getType());
+
+ // Lock
+ LockManagerEntry lockManagerEntry = new LockManagerEntry();
+ lockManagerEntry.setTimeout(wsEntry.getLockManager().getTimeout());
+ if (wsEntry.getLockManager().getPersister() != null)
+ {
+ LockPersisterEntry lockPersisterEntry = new LockPersisterEntry();
+ lockPersisterEntry.setType(wsEntry.getLockManager().getPersister().getType());
+ ArrayList<SimpleParameterEntry> lockPersisterParameters = new ArrayList<SimpleParameterEntry>();
+ lockPersisterParameters.addAll(wsEntry.getLockManager().getPersister().getParameters());
+ lockPersisterEntry.setParameters(lockPersisterParameters);
+ lockManagerEntry.setPersister(lockPersisterEntry);
+ }
+
+ WorkspaceEntry workspaceEntry = new WorkspaceEntry();
+ workspaceEntry.setContainer(containerEntry);
+ workspaceEntry.setCache(cacheEntry);
+ workspaceEntry.setQueryHandler(qEntry);
+ workspaceEntry.setLockManager(lockManagerEntry);
+ workspaceEntry.setName(wsEntry.getName());
+ workspaceEntry.setUniqueName(wsEntry.getUniqueName());
+
+ return workspaceEntry;
+ }
}
Modified: jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/lock/infinispan/ISPNCacheableLockManagerImpl.java
===================================================================
--- jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/lock/infinispan/ISPNCacheableLockManagerImpl.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/lock/infinispan/ISPNCacheableLockManagerImpl.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -119,6 +119,7 @@
configureJDBCCacheLoader(config.getLockManager());
cache = factory.createCache("L" + config.getUniqueName().replace("_", ""), config.getLockManager());
+ PrivilegedISPNCacheHelper.start(cache);
}
else
{
Modified: jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/query/ispn/ISPNIndexChangesFilter.java
===================================================================
--- jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/query/ispn/ISPNIndexChangesFilter.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/core/query/ispn/ISPNIndexChangesFilter.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -28,6 +28,7 @@
import org.exoplatform.services.jcr.impl.core.query.QueryHandler;
import org.exoplatform.services.jcr.impl.core.query.SearchManager;
import org.exoplatform.services.jcr.infinispan.ISPNCacheFactory;
+import org.exoplatform.services.jcr.infinispan.PrivilegedISPNCacheHelper;
import org.exoplatform.services.jcr.util.IdGenerator;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -82,6 +83,7 @@
ISPNCacheFactory<Serializable, Object> factory = new ISPNCacheFactory<Serializable, Object>(cfm);
config.putParameterValue(PARAM_INFINISPAN_CACHESTORE_CLASS, IndexerCacheStore.class.getName());
this.cache = factory.createCache("Indexer_" + searchManager.getWsId(), config);
+ PrivilegedISPNCacheHelper.start(this.cache);
CacheLoaderManager cacheLoaderManager =
cache.getAdvancedCache().getComponentRegistry().getComponent(CacheLoaderManager.class);
@@ -125,4 +127,12 @@
{
return true;
}
+
+ /**
+ * {@inheritDoc}
+ */
+ public void close()
+ {
+ PrivilegedISPNCacheHelper.stop(cache);
+ }
}
Modified: jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/BufferedISPNCache.java
===================================================================
--- jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/BufferedISPNCache.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/BufferedISPNCache.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -22,6 +22,7 @@
import org.exoplatform.services.jcr.datamodel.ItemData;
import org.exoplatform.services.jcr.impl.core.itemfilters.QPathEntryFilter;
import org.exoplatform.services.jcr.infinispan.CacheKey;
+import org.exoplatform.services.jcr.infinispan.PrivilegedISPNCacheHelper;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.infinispan.AdvancedCache;
@@ -949,15 +950,7 @@
*/
public void start()
{
- PrivilegedAction<Object> action = new PrivilegedAction<Object>()
- {
- public Object run()
- {
- parentCache.start();
- return null;
- }
- };
- SecurityHelper.doPrivilegedAction(action);
+ PrivilegedISPNCacheHelper.start((Cache)parentCache);
}
/**
@@ -965,15 +958,7 @@
*/
public void stop()
{
- PrivilegedAction<Object> action = new PrivilegedAction<Object>()
- {
- public Object run()
- {
- parentCache.stop();
- return null;
- }
- };
- SecurityHelper.doPrivilegedAction(action);
+ PrivilegedISPNCacheHelper.stop((Cache)parentCache);
}
/**
Modified: jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/ISPNCacheWorkspaceStorageCache.java
===================================================================
--- jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/ISPNCacheWorkspaceStorageCache.java 2012-03-03 08:30:43 UTC (rev 5770)
+++ jcr/trunk/exo.jcr.component.core.impl.infinispan.v5/src/main/java/org/exoplatform/services/jcr/impl/dataflow/persistent/infinispan/ISPNCacheWorkspaceStorageCache.java 2012-03-03 11:02:35 UTC (rev 5771)
@@ -71,6 +71,7 @@
import org.infinispan.notifications.Listener;
import org.infinispan.notifications.cachelistener.annotation.CacheEntryModified;
import org.infinispan.notifications.cachelistener.event.CacheEntryModifiedEvent;
+import org.picocontainer.Startable;
import java.io.File;
import java.io.IOException;
@@ -118,7 +119,7 @@
* @version $Id: ISPNCacheWorkspaceStorageCache.java 3514 2010-11-22 16:14:36Z nzamosenchuk $
*/
@SuppressWarnings("unchecked")
-public class ISPNCacheWorkspaceStorageCache implements WorkspaceStorageCache, Backupable
+public class ISPNCacheWorkspaceStorageCache implements WorkspaceStorageCache, Backupable, Startable
{
private static final Log LOG = ExoLogger//NOSONAR
.getLogger("exo.jcr.component.core.impl.infinispan.v5.ISPNCacheWorkspaceStorageCache");//NOSONAR
@@ -592,6 +593,7 @@
this.caller = new GlobalOperationCaller();
cache.addListener(new CacheEventListener());
}
+ this.cache.start();
}
private boolean isDistributedMode()
@@ -2309,4 +2311,19 @@
cache.getAdvancedCache().withFlags(Flag.SKIP_REMOTE_LOOKUP, Flag.FAIL_SILENTLY).remove(key);
}
}
+
+ /**
+ * {@inheritDoc}
+ */
+ public void start()
+ {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void stop()
+ {
+ cache.stop();
+ }
}
14 years, 1 month
exo-jcr SVN: r5770 - jcr/branches/1.14.6-GA-JBAS7.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 03:30:43 -0500 (Sat, 03 Mar 2012)
New Revision: 5770
Modified:
jcr/branches/1.14.6-GA-JBAS7/pom.xml
Log:
EXOJCR-1777: added deps to branch
Modified: jcr/branches/1.14.6-GA-JBAS7/pom.xml
===================================================================
--- jcr/branches/1.14.6-GA-JBAS7/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
+++ jcr/branches/1.14.6-GA-JBAS7/pom.xml 2012-03-03 08:30:43 UTC (rev 5770)
@@ -42,9 +42,9 @@
<properties>
<exo.product.name>exo-jcr</exo.product.name>
<exo.product.specification>1.14</exo.product.specification>
- <org.exoplatform.kernel.version>2.3.6-GA</org.exoplatform.kernel.version>
- <org.exoplatform.core.version>2.4.6-GA</org.exoplatform.core.version>
- <org.exoplatform.ws.version>2.2.6-GA</org.exoplatform.ws.version>
+ <org.exoplatform.kernel.version>2.3.6-GA-JBAS7-SNAPSHOT</org.exoplatform.kernel.version>
+ <org.exoplatform.core.version>2.4.6-GA-JBAS7-SNAPSHOT</org.exoplatform.core.version>
+ <org.exoplatform.ws.version>2.2.6-GA-JBAS7-SNAPSHOT</org.exoplatform.ws.version>
<org.exoplatform.doc-style.version>2</org.exoplatform.doc-style.version>
</properties>
14 years, 1 month
exo-jcr SVN: r5769 - in jcr/tags/1.14.6-GA: applications and 26 other directories.
by do-not-reply@jboss.org
Author: tolusha
Date: 2012-03-03 03:05:27 -0500 (Sat, 03 Mar 2012)
New Revision: 5769
Modified:
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole.dist/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.browser/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.config/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.fckeditor/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jboss/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jetty/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jonas/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.rest/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.applications.tomcat/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.cluster.testclient/pom.xml
jcr/tags/1.14.6-GA/applications/exo.jcr.ear/pom.xml
jcr/tags/1.14.6-GA/applications/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.core.impl.infinispan.v5/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.core/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.ext/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.ftp/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.statistics/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.component.webdav/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.connectors.jca/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/en/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.docs/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.framework.command/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.framework.ftpclient/pom.xml
jcr/tags/1.14.6-GA/exo.jcr.framework.web/pom.xml
jcr/tags/1.14.6-GA/packaging/module/pom.xml
jcr/tags/1.14.6-GA/pom.xml
Log:
[maven-release-plugin] prepare release 1.14.6-GA-JBAS7
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.backupconsole</artifactId>
<name>eXo JCR :: Applications :: Backup Console</name>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole.dist/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole.dist/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.backupconsole.dist/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.backupconsole.dist</artifactId>
<name>eXo JCR :: Applications :: Backup Console Binary Distribution</name>
@@ -37,7 +37,7 @@
<dependency>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.applications.backupconsole</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</dependency>
<dependency>
<groupId>org.exoplatform.jcr</groupId>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.browser/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.browser/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.browser/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.browser</artifactId>
<packaging>war</packaging>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.config/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.config/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.config/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.config</artifactId>
<packaging>pom</packaging>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.fckeditor/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.fckeditor/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.fckeditor/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.fckeditor</artifactId>
<packaging>war</packaging>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jboss/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jboss/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jboss/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.applications.config</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<relativePath>../exo.jcr.applications.config/pom.xml</relativePath>
</parent>
@@ -41,7 +41,7 @@
<dependency>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.ear</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<type>ear</type>
<scope>runtime</scope>
</dependency>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jetty/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jetty/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jetty/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.applications.config</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<relativePath>../exo.jcr.applications.config/pom.xml</relativePath>
</parent>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jonas/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jonas/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.jonas/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.applications.config</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<relativePath>../exo.jcr.applications.config/pom.xml</relativePath>
</parent>
@@ -41,7 +41,7 @@
<dependency>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.connectors.jca</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<type>rar</type>
<scope>runtime</scope>
</dependency>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.rest/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.rest/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.rest/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.applications.rest</artifactId>
<packaging>war</packaging>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.applications.tomcat/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.applications.tomcat/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.applications.tomcat/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.applications.config</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<relativePath>../exo.jcr.applications.config/pom.xml</relativePath>
</parent>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.cluster.testclient/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.cluster.testclient/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.cluster.testclient/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.cluster.testclient</artifactId>
<name>eXo JCR :: Cluster :: Test Client</name>
Modified: jcr/tags/1.14.6-GA/applications/exo.jcr.ear/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/exo.jcr.ear/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/exo.jcr.ear/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.ear</artifactId>
<packaging>ear</packaging>
Modified: jcr/tags/1.14.6-GA/applications/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/applications/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/applications/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,12 +22,12 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>jcr-applications-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<name>eXo JCR :: Applications :: Reactor</name>
<packaging>pom</packaging>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.core/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.core/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.core/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.core</artifactId>
<name>eXo JCR :: Component :: Core Service</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.core.impl.infinispan.v5/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.core.impl.infinispan.v5/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.core.impl.infinispan.v5/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.core.impl.infinispan.v5</artifactId>
<name>eXo JCR :: Component :: Core Service based on ISPN 5</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.ext/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.ext/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.ext/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.ext</artifactId>
<name>eXo JCR :: Component :: Extension Service</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.ftp/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.ftp/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.ftp/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.ftp</artifactId>
<name>eXo JCR :: Component :: FTP Service</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.statistics/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.statistics/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.statistics/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.statistics</artifactId>
<name>eXo JCR :: Component :: Statistics Provider</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.component.webdav/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.component.webdav/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.component.webdav/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.component.webdav</artifactId>
<name>eXo JCR :: Component :: Webdav Service</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.connectors.jca/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.connectors.jca/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.connectors.jca/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.connectors.jca</artifactId>
<packaging>rar</packaging>
Modified: jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/en/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/en/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/en/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.docs.developer</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.docs/exo.jcr.docs.developer/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>exo.jcr.docs</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: jcr/tags/1.14.6-GA/exo.jcr.docs/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.docs/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.docs/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -22,7 +22,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: jcr/tags/1.14.6-GA/exo.jcr.framework.command/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.framework.command/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.framework.command/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -12,7 +12,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.framework.command</artifactId>
<name>eXo JCR :: Framework :: Command</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.framework.ftpclient/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.framework.ftpclient/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.framework.ftpclient/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.framework.ftpclient</artifactId>
<name>eXo JCR :: Framework :: FTP Client</name>
Modified: jcr/tags/1.14.6-GA/exo.jcr.framework.web/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/exo.jcr.framework.web/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/exo.jcr.framework.web/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -24,7 +24,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
</parent>
<artifactId>exo.jcr.framework.web</artifactId>
<name>eXo JCR :: Framework :: Web</name>
Modified: jcr/tags/1.14.6-GA/packaging/module/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/packaging/module/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/packaging/module/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -4,7 +4,7 @@
<parent>
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<artifactId>jcr.packaging.module</artifactId>
Modified: jcr/tags/1.14.6-GA/pom.xml
===================================================================
--- jcr/tags/1.14.6-GA/pom.xml 2012-03-03 08:04:45 UTC (rev 5768)
+++ jcr/tags/1.14.6-GA/pom.xml 2012-03-03 08:05:27 UTC (rev 5769)
@@ -29,14 +29,14 @@
<groupId>org.exoplatform.jcr</groupId>
<artifactId>jcr-parent</artifactId>
- <version>1.14.6-GA-JBAS7-SNAPSHOT</version>
+ <version>1.14.6-GA</version>
<packaging>pom</packaging>
<name>eXo JCR</name>
<scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/exo-jcr/jcr/branches/1.14.6-GA-JBAS7</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/exo-jcr/jcr/branches/1.14.6-GA-JBAS7</developerConnection>
- <url>http://fisheye.jboss.org/browse/exo-jcr/jcr/branches/1.14.6-GA-JBAS7</url>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/exo-jcr/jcr/tags/1.14.6-GA</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/exo-jcr/jcr/tags/1.14.6-GA</developerConnection>
+ <url>http://fisheye.jboss.org/browse/exo-jcr/jcr/tags/1.14.6-GA</url>
</scm>
<properties>
14 years, 1 month