exo-jcr SVN: r5239 - core/trunk/exo.core.component.organization.tests/src/main/java/org/exoplatform/services/tck/organization.
by do-not-reply@jboss.org
Author: areshetnyak
Date: 2011-11-25 07:09:00 -0500 (Fri, 25 Nov 2011)
New Revision: 5239
Modified:
core/trunk/exo.core.component.organization.tests/src/main/java/org/exoplatform/services/tck/organization/TestMembershipHandler.java
Log:
EXOJCR-1658 : TestMembershipHandler was updated.
Modified: core/trunk/exo.core.component.organization.tests/src/main/java/org/exoplatform/services/tck/organization/TestMembershipHandler.java
===================================================================
--- core/trunk/exo.core.component.organization.tests/src/main/java/org/exoplatform/services/tck/organization/TestMembershipHandler.java 2011-11-24 14:17:18 UTC (rev 5238)
+++ core/trunk/exo.core.component.organization.tests/src/main/java/org/exoplatform/services/tck/organization/TestMembershipHandler.java 2011-11-25 12:09:00 UTC (rev 5239)
@@ -17,6 +17,7 @@
package org.exoplatform.services.tck.organization;
import org.exoplatform.commons.utils.ListAccess;
+import org.exoplatform.commons.utils.PageList;
import org.exoplatform.services.organization.Group;
import org.exoplatform.services.organization.Membership;
import org.exoplatform.services.organization.MembershipEventListener;
@@ -394,8 +395,24 @@
*/
public void testFindUsersByGroupId() throws Exception
{
- assertEquals(uHandler.findUsersByGroupId("/platform/users").getSize(), 4);
+ ListAccess<User> usersListAccess = uHandler.findUsersByGroupId("/platform/users");
+ assertEquals(usersListAccess.getSize(), 4);
+
+ for (User u : usersListAccess.load(0, usersListAccess.getSize()))
+ {
+ User currentUrer = uHandler.findUserByName(u.getUserName());
+ assertNotNull(currentUrer);
+
+ assertEquals(currentUrer.getUserName(), u.getUserName());
+ assertEquals(currentUrer.getFirstName(), u.getFirstName());
+ assertEquals(currentUrer.getLastName(), u.getLastName());
+ assertEquals(currentUrer.getEmail(), u.getEmail());
+ assertEquals(currentUrer.getOrganizationId(), u.getOrganizationId());
+ assertEquals(currentUrer.getPassword(), u.getPassword());
+ assertEquals(currentUrer.getCreatedDate().toString(), u.getCreatedDate().toString());
+ }
+
// try to find users by not existed entries. We supposed to get empty list instead of Exception
try
{
@@ -412,8 +429,24 @@
*/
public void testFindUsersByGroup() throws Exception
{
- assertEquals(uHandler.findUsersByGroup("/platform/users").getAll().size(), 4);
+ PageList<User> usersList = uHandler.findUsersByGroup("/platform/users");
+
+ assertEquals(usersList.getAll().size(), 4);
+ for (User u : usersList.getAll())
+ {
+ User currentUrer = uHandler.findUserByName(u.getUserName());
+ assertNotNull(currentUrer);
+
+ assertEquals(currentUrer.getUserName(), u.getUserName());
+ assertEquals(currentUrer.getFirstName(), u.getFirstName());
+ assertEquals(currentUrer.getLastName(), u.getLastName());
+ assertEquals(currentUrer.getEmail(), u.getEmail());
+ assertEquals(currentUrer.getOrganizationId(), u.getOrganizationId());
+ assertEquals(currentUrer.getPassword(), u.getPassword());
+ assertEquals(currentUrer.getCreatedDate().toString(), u.getCreatedDate().toString());
+ }
+
// try to find users by not existed entries. We supposed to get empty list instead of Exception
try
{
12 years, 5 months
exo-jcr SVN: r5238 - jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db.
by do-not-reply@jboss.org
Author: nzamosenchuk
Date: 2011-11-24 09:17:18 -0500 (Thu, 24 Nov 2011)
New Revision: 5238
Modified:
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleMultiDbJDBCConnection.java
jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleSingleDbJDBCConnection.java
Log:
EXOJCR-1653 : Added indexes shows upto 12% query performance increase. Queries were executed in 52ms (avg) previously and in 46ms now.
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleMultiDbJDBCConnection.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleMultiDbJDBCConnection.java 2011-11-24 10:55:47 UTC (rev 5237)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleMultiDbJDBCConnection.java 2011-11-24 14:17:18 UTC (rev 5238)
@@ -97,6 +97,8 @@
+ " select I.ID, I.PARENT_ID, I.NAME, I.VERSION, I.I_INDEX, I.N_ORDER_NUM from JCR_MITEM I "
+ " where I.I_CLASS=1 order by I.ID) A where ROWNUM <= ?) where r__ > ?) J on P.PARENT_ID = J.ID"
+ " where P.I_CLASS=2 and V.PROPERTY_ID=P.ID order by J.ID";
+
+ FIND_NODES_BY_PARENTID_LAZILY_CQ = FIND_NODES_BY_PARENTID_LAZILY_CQ.replaceFirst("select", "select /*+ INDEX(I JCR_FK_SITEM_PARENT) INDEX(V JCR_IDX_SVALUE_PROPERTY)*/");
}
/**
Modified: jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleSingleDbJDBCConnection.java
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleSingleDbJDBCConnection.java 2011-11-24 10:55:47 UTC (rev 5237)
+++ jcr/trunk/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/jdbc/optimisation/db/OracleSingleDbJDBCConnection.java 2011-11-24 14:17:18 UTC (rev 5238)
@@ -98,6 +98,8 @@
+ " where I.CONTAINER_NAME=? and I.I_CLASS=1 order by I.ID"
+ " ) A where ROWNUM <= ?) where r__ > ?) J on P.PARENT_ID = J.ID"
+ " where P.I_CLASS=2 and P.CONTAINER_NAME=? and V.PROPERTY_ID=P.ID order by J.ID";
+
+ FIND_NODES_BY_PARENTID_LAZILY_CQ = FIND_NODES_BY_PARENTID_LAZILY_CQ.replaceFirst("select", "select /*+ INDEX(I JCR_FK_SITEM_PARENT) INDEX(V JCR_IDX_SVALUE_PROPERTY)*/");
}
/**
12 years, 5 months
exo-jcr SVN: r5237 - jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl.
by do-not-reply@jboss.org
Author: areshetnyak
Date: 2011-11-24 05:55:47 -0500 (Thu, 24 Nov 2011)
New Revision: 5237
Modified:
jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobWorkspaceRestore.java
Log:
EXOJCR-1647 : Problem with null in name of thread JobWorkspaceRestore was fixed.
Modified: jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobWorkspaceRestore.java
===================================================================
--- jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobWorkspaceRestore.java 2011-11-23 13:01:30 UTC (rev 5236)
+++ jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/backup/impl/JobWorkspaceRestore.java 2011-11-24 10:55:47 UTC (rev 5237)
@@ -134,7 +134,7 @@
public JobWorkspaceRestore(RepositoryService repositoryService, BackupManager backupManager, String repositoryName,
BackupChainLog log, WorkspaceEntry wEntry)
{
- super("JobWorkspaceRestore " + wEntry.getUniqueName());
+ super("JobWorkspaceRestore " + repositoryName + "_" + wEntry.getName());
this.repositoryService = repositoryService;
this.backupManager = backupManager;
this.repositoryName = repositoryName;
12 years, 5 months
exo-jcr SVN: r5236 - in jcr/branches/1.12.x: exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/api/core/query and 2 other directories.
by do-not-reply@jboss.org
Author: trang_vu
Date: 2011-11-23 08:01:30 -0500 (Wed, 23 Nov 2011)
New Revision: 5236
Added:
jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/api/core/query/TestQueryMoveNode.java
jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/usecases/query/TestQueryChilds.java
jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1678/readme.txt
Modified:
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/ChildAxisQuery.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldNames.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldSelectors.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexFormatVersion.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/NodeIndexer.java
Log:
JCR-1678: Bad performance in ChildAxisQuery.SimpleChildrenCalculator.getHits()
Problem description
Using a dataset with 20k users, the Calendar home page takes 160s to display the first time, and 3/4s later.
After 1h (JCR Cache eviction), it takes also 160s to display.
The problem doesn't occur much with 10k users (7s to display).
Fix description
* Avoid invoking getChildNodesData() by storing some needed information in lucene index.
Need to re-index data to ensure that new changes will work.
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/ChildAxisQuery.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/ChildAxisQuery.java 2011-11-23 12:50:43 UTC (rev 5235)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/ChildAxisQuery.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -519,15 +519,14 @@
{
if (position != LocationStepQueryNode.NONE)
{
- Document node = reader.document(i, FieldSelectors.UUID_AND_PARENT);
+ Document node = reader.document(i, FieldSelectors.UUID_AND_PARENT_AND_INDEX);
String parentId = node.get(FieldNames.PARENT);
String id = node.get(FieldNames.UUID);
try
{
- //NodeState state = (NodeState) itemMgr.getItemState(parentId);
- NodeData state = (NodeData)itemMgr.getItemData(parentId);
if (nameTest == null)
{
+ NodeData state = (NodeData)itemMgr.getItemData(parentId);
// only select this node if it is the child at
// specified position
if (position == LocationStepQueryNode.LAST)
@@ -555,6 +554,7 @@
// specified position
if (position == LocationStepQueryNode.LAST)
{
+ NodeData state = (NodeData)itemMgr.getItemData(parentId);
// only select last
if (state == null)
@@ -572,6 +572,11 @@
}
}
}
+ else if (version.getVersion() >= IndexFormatVersion.V4.getVersion())
+ {
+ if (Integer.valueOf(node.get(FieldNames.INDEX)) != position)
+ return false;
+ }
else
{
NodeData nodeData = (NodeData)itemMgr.getItemData(id);
@@ -693,49 +698,70 @@
//NodeId id = new NodeId(UUID.fromString(uuid));
try
{
- long time = System.currentTimeMillis();
- NodeData state = (NodeData)itemMgr.getItemData(uuid);
- time = System.currentTimeMillis() - time;
- log.debug("got NodeState with id {} in {} ms.", uuid, new Long(time));
- Iterator<NodeData> entries;
- if (nameTest != null)
+ if (nameTest != null && version.getVersion() >= IndexFormatVersion.V4.getVersion())
{
- //NodeData childNodeData = (NodeData)itemMgr.getItemData(state, new QPathEntry(nameTest, 1));//state.getChildNodeEntries(nameTest).iterator();
- List<NodeData> childs = itemMgr.getChildNodesData(state);
-
- List<NodeData> datas = new ArrayList<NodeData>();
- if (childs != null)
+ StringBuilder path = new StringBuilder(256);
+ path.append(uuid == null ? "" : uuid).append('/').append(nameTest.getAsString());
+ TermDocs docs = reader.termDocs(new Term(FieldNames.PATH, path.toString()));
+ try
{
- for (NodeData nodeData : childs)
+ while (docs.next())
{
- if (nameTest.equals(nodeData.getQPath().getName()))
- datas.add(nodeData);
+ childrenHits.set(docs.doc());
}
-
}
- entries = datas.iterator();//itemMgr.getChildNodesData(childNodeData).iterator();
+ finally
+ {
+ docs.close();
+ }
}
else
{
- // get all children
- entries = itemMgr.getChildNodesData(state).iterator();
- }
- while (entries.hasNext())
- {
- String childId = entries.next().getIdentifier();
- Term uuidTerm = new Term(FieldNames.UUID, childId);
- TermDocs docs = reader.termDocs(uuidTerm);
- try
+ long time = System.currentTimeMillis();
+ NodeData state = (NodeData)itemMgr.getItemData(uuid);
+ time = System.currentTimeMillis() - time;
+ log.debug("got NodeState with id {} in {} ms.", uuid, new Long(time));
+ Iterator<NodeData> entries;
+ if (nameTest != null)
{
- if (docs.next())
+ List<NodeData> childs = itemMgr.getChildNodesData(state);
+
+ List<NodeData> datas = new ArrayList<NodeData>();
+ if (childs != null)
{
- childrenHits.set(docs.doc());
+ for (NodeData nodeData : childs)
+ {
+ if (nameTest.equals(nodeData.getQPath().getName()))
+ {
+ datas.add(nodeData);
+ }
+ }
}
+ entries = datas.iterator();
}
- finally
+ else
{
- docs.close();
+ // get all children
+ entries = itemMgr.getChildNodesData(state).iterator();
}
+ while (entries.hasNext())
+ {
+ String childId = entries.next().getIdentifier();
+ Term uuidTerm = new Term(FieldNames.UUID, childId);
+ TermDocs docs = reader.termDocs(uuidTerm);
+ try
+ {
+ if (docs.next())
+ {
+ childrenHits.set(docs.doc());
+ }
+ }
+ finally
+
+ {
+ docs.close();
+ }
+ }
}
}
catch (RepositoryException e)
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldNames.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldNames.java 2011-11-23 12:50:43 UTC (rev 5235)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldNames.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -64,6 +64,16 @@
public static final String LOCAL_NAME = "_:LOCAL_NAME".intern();
/**
+ * Name of the field that contains the index of the item.
+ */
+ public static final String INDEX = "_:INDEX".intern();
+
+ /**
+ * Name of the field that contains the relative path of the item.
+ */
+ public static final String PATH = "_:PATH".intern();
+
+ /**
* Name of the field that contains the namespace URI of the node name. Terms
* are not tokenized.
*/
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldSelectors.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldSelectors.java 2011-11-23 12:50:43 UTC (rev 5235)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/FieldSelectors.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -63,4 +63,41 @@
}
}
};
+
+ public static final FieldSelector UUID_AND_PARENT_AND_INDEX = new FieldSelector() {
+ /**
+ * Accepts {@link FieldNames#UUID}, {@link FieldNames#PARENT}
+ * and {@link FieldNames#INDEX}.
+ *
+ * @param fieldName the field name to check.
+ * @return result.
+ */
+ public FieldSelectorResult accept(String fieldName) {
+ if (FieldNames.UUID == fieldName) {
+ return FieldSelectorResult.LOAD;
+ } else if (FieldNames.PARENT == fieldName) {
+ return FieldSelectorResult.LOAD;
+ } else if (FieldNames.INDEX == fieldName) {
+ return FieldSelectorResult.LOAD;
+ } else {
+ return FieldSelectorResult.NO_LOAD;
+ }
+ }
+ };
+
+ public static final FieldSelector PATH = new FieldSelector() {
+ /**
+ * Accepts {@link FieldNames#PATH}.
+ *
+ * @param fieldName the field name to check.
+ * @return result.
+ */
+ public FieldSelectorResult accept(String fieldName) {
+ if (FieldNames.PATH == fieldName) {
+ return FieldSelectorResult.LOAD;
+ } else {
+ return FieldSelectorResult.NO_LOAD;
+ }
+ }
+ };
}
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexFormatVersion.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexFormatVersion.java 2011-11-23 12:50:43 UTC (rev 5235)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/IndexFormatVersion.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -16,10 +16,10 @@
*/
package org.exoplatform.services.jcr.impl.core.query.lucene;
+import org.apache.lucene.index.IndexReader;
+
import java.util.Collection;
-import org.apache.lucene.index.IndexReader;
-
/**
* This class indicates the lucene index format that is used.
* <ul>
@@ -52,11 +52,16 @@
public static final IndexFormatVersion V2 = new IndexFormatVersion(2);
/**
- * V3 is the index format for Jackrabbit releases >= 1.5
+ * V3 is the index format for Jackrabbit releases 1.5.x
*/
public static final IndexFormatVersion V3 = new IndexFormatVersion(3);
/**
+ * V4 is the index format for Jackrabbit releases >= 1.6
+ */
+ public static final IndexFormatVersion V4 = new IndexFormatVersion(4);
+
+ /**
* The used version of the index format
*/
private final int version;
@@ -104,7 +109,9 @@
public static IndexFormatVersion getVersion(IndexReader indexReader) {
Collection fields = indexReader.getFieldNames(
IndexReader.FieldOption.ALL);
- if (fields.contains(FieldNames.LOCAL_NAME) || indexReader.numDocs() == 0) {
+ if ((fields.contains(FieldNames.INDEX) && fields.contains(FieldNames.PATH))|| indexReader.numDocs() == 0) {
+ return IndexFormatVersion.V4;
+ } else if (fields.contains(FieldNames.LOCAL_NAME)) {
return IndexFormatVersion.V3;
} else if (fields.contains(FieldNames.PROPERTIES_SET)) {
return IndexFormatVersion.V2;
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/NodeIndexer.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/NodeIndexer.java 2011-11-23 12:50:43 UTC (rev 5235)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/core/query/lucene/NodeIndexer.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -215,6 +215,17 @@
// unknown uri<->prefix mappings
}
+ if (indexFormatVersion.getVersion() >= IndexFormatVersion.V4.getVersion())
+ {
+ doc.add(new Field(FieldNames.INDEX, Integer.toString(node.getQPath().getIndex()), Field.Store.YES,
+ Field.Index.NOT_ANALYZED_NO_NORMS));
+
+ StringBuilder path = new StringBuilder(256);
+ path.append(node.getParentIdentifier() == null ? "" : node.getParentIdentifier()).append('/')
+ .append(node.getQPath().getName().getAsString());
+ doc.add(new Field(FieldNames.PATH, path.toString(), Field.Store.NO, Field.Index.NOT_ANALYZED_NO_NORMS));
+ }
+
for (PropertyData prop : stateProvider.listChildPropertiesData(node))
{
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/api/core/query/TestQueryMoveNode.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/api/core/query/TestQueryMoveNode.java (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/api/core/query/TestQueryMoveNode.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -0,0 +1,85 @@
+/*
+ * Copyright (C) 2003-2011 eXo Platform SAS.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Affero General Public License
+ * as published by the Free Software Foundation; either version 3
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see<http://www.gnu.org/licenses/>.
+ */
+package org.exoplatform.services.jcr.api.core.query;
+
+import org.exoplatform.services.jcr.usecases.BaseUsecasesTest;
+
+import javax.jcr.Node;
+import javax.jcr.NodeIterator;
+import javax.jcr.query.Query;
+import javax.jcr.query.QueryManager;
+import javax.jcr.query.QueryResult;
+
+/**
+ * Created by The eXo Platform SAS.
+ *
+ * <br/>Date:
+ *
+ * @author <a href="karpenko.sergiy(a)gmail.com">Karpenko Sergiy</a>
+ * @version $Id: TestQueryMoveNode.java 111 2011-28-01 11:11:11Z serg $
+ */
+public class TestQueryMoveNode extends BaseUsecasesTest
+{
+
+ public void testReordering() throws Exception
+ {
+ Node testRoot = this.root.addNode("testSameNameSiblingDelete");
+
+ Node subNode_1 = testRoot.addNode("node", "nt:unstructured"); // 1
+ subNode_1.addMixin("mix:referenceable");
+ session.save();
+
+ //check the index
+ String sqlQuery;
+ Query query;
+ QueryResult queryResult;
+ NodeIterator iterator;
+ Node node;
+ QueryManager qm = session.getWorkspace().getQueryManager();
+
+ sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path = '/testSameNameSiblingDelete/node[1]'";
+ query = qm.createQuery(sqlQuery, Query.SQL);
+ queryResult = query.execute();
+ iterator = queryResult.getNodes();
+ assertTrue("Node expected ", iterator.getSize() == 1);
+ node = iterator.nextNode();
+ assertEquals("Wrong id ", subNode_1.getUUID(), node.getUUID());
+ assertEquals("Wrong path ", subNode_1.getPath(), node.getPath());
+
+ // move
+ testRoot.addNode("folder");
+ session.save();
+ session.move("/testSameNameSiblingDelete/node", "/testSameNameSiblingDelete/folder/node");
+ session.save();
+
+ sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path = '/testSameNameSiblingDelete/node[1]'";
+ query = qm.createQuery(sqlQuery, Query.SQL);
+ queryResult = query.execute();
+ iterator = queryResult.getNodes();
+ assertTrue("There must be no node ", iterator.getSize() == 0);
+
+ sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path = '/testSameNameSiblingDelete/folder/node[1]'";
+ query = qm.createQuery(sqlQuery, Query.SQL);
+ queryResult = query.execute();
+ iterator = queryResult.getNodes();
+ assertTrue("Node expected ", iterator.getSize() == 1);
+ node = iterator.nextNode();
+ assertEquals("Wrong id ", subNode_1.getUUID(), node.getUUID());
+ assertEquals("Wrong path ", subNode_1.getPath(), node.getPath());
+ }
+
+}
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/usecases/query/TestQueryChilds.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/usecases/query/TestQueryChilds.java (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/java/org/exoplatform/services/jcr/usecases/query/TestQueryChilds.java 2011-11-23 13:01:30 UTC (rev 5236)
@@ -0,0 +1,124 @@
+/*
+ * Copyright (C) 2011 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.exoplatform.services.jcr.usecases.query;
+
+import org.exoplatform.services.jcr.impl.core.ItemImpl;
+import org.exoplatform.services.jcr.usecases.BaseUsecasesTest;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.jcr.Node;
+import javax.jcr.NodeIterator;
+import javax.jcr.RepositoryException;
+import javax.jcr.query.Query;
+import javax.jcr.query.QueryManager;
+import javax.jcr.query.QueryResult;
+
+/**
+ * @author <a href="mailto:skarpenko@exoplatform.com">Sergiy Karpenko</a>
+ * @version $Id: exo-jboss-codetemplates.xml 34360 16 ????. 2011 skarpenko $
+ *
+ */
+public class TestQueryChilds extends BaseUsecasesTest
+{
+ public void testGetChilds() throws Exception
+ {
+ Node testRoot = this.root.addNode("testSameNameSiblingDelete");
+
+ Node subNode_1 = testRoot.addNode("node", "nt:unstructured"); // 1
+ Node subNode_1_1 = subNode_1.addNode("node1", "nt:unstructured");
+ Node subNode_1_2 = subNode_1.addNode("node2", "nt:unstructured");
+ Node subNode_1_1_1 = subNode_1_1.addNode("node11", "nt:unstructured");
+ //Node subNode_1_1_2 = subNode_1_1.addNode("node12", "nt:unstructured");
+ Node subNode_2 = testRoot.addNode("node", "nt:unstructured"); // 2
+ Node subNode_2_1 = subNode_2.addNode("node3", "nt:unstructured");
+ Node subNode_2_2 = subNode_2.addNode("node4", "nt:unstructured");
+
+ session.save();
+
+ //check the index
+ String sqlQuery;
+ Query query;
+ QueryResult queryResult;
+ NodeIterator iterator;
+ Node node;
+ QueryManager qm = session.getWorkspace().getQueryManager();
+
+ sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path LIKE '/testSameNameSiblingDelete/node/%'";
+ query = qm.createQuery(sqlQuery, Query.SQL);
+ queryResult = query.execute();
+ iterator = queryResult.getNodes();
+ assertTrue("Node expected ", iterator.getSize() == 3);
+ // node = iterator.nextNode();
+ // assertEquals("Wrong id ", subNode_1.getUUID(), node.getUUID());
+ // assertEquals("Wrong path ", subNode_1.getPath(), node.getPath());
+ testNames(iterator, new String[]{"node1", "node2", "node11"}); //, "node3", "node4"
+
+ // // move
+ // testRoot.addNode("folder");
+ // session.save();
+ // session.move("/testSameNameSiblingDelete/node", "/testSameNameSiblingDelete/folder/node");
+ // session.save();
+ //
+ // sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path = '/testSameNameSiblingDelete/node[1]'";
+ // query = qm.createQuery(sqlQuery, Query.SQL);
+ // queryResult = query.execute();
+ // iterator = queryResult.getNodes();
+ // assertTrue("There must be no node ", iterator.getSize() == 0);
+ //
+ // sqlQuery = "SELECT * FROM nt:unstructured WHERE jcr:path = '/testSameNameSiblingDelete/folder/node[1]'";
+ // query = qm.createQuery(sqlQuery, Query.SQL);
+ // queryResult = query.execute();
+ // iterator = queryResult.getNodes();
+ // assertTrue("Node expected ", iterator.getSize() == 1);
+ // node = iterator.nextNode();
+ // assertEquals("Wrong id ", subNode_1.getUUID(), node.getUUID());
+ // assertEquals("Wrong path ", subNode_1.getPath(), node.getPath());
+ }
+
+ protected void testNames(Iterator iterator, String[] expectedNames) throws RepositoryException
+ {
+
+ List<String> names = new ArrayList<String>();
+ while (iterator.hasNext())
+ {
+ ItemImpl item = (ItemImpl)iterator.next();
+ names.add(item.getName());
+ }
+
+ //compare names
+ assertEquals(expectedNames.length, names.size());
+
+ for (String expectedName : expectedNames)
+ {
+ boolean finded = false;
+ for (String name : names)
+ {
+ if (expectedName.equals(name))
+ {
+ finded = true;
+ break;
+ }
+ }
+ assertTrue(finded);
+ }
+ }
+}
Added: jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1678/readme.txt
===================================================================
--- jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1678/readme.txt (rev 0)
+++ jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1678/readme.txt 2011-11-23 13:01:30 UTC (rev 5236)
@@ -0,0 +1,66 @@
+Summary
+
+ * Status: Bad performance in ChildAxisQuery.SimpleChildrenCalculator.getHits()
+ * CCP Issue: N/A. Product Jira Issue: JCR-1678.
+ * Complexity: High
+
+The Proposal
+Problem description
+
+What is the problem to fix?
+Using a dataset with 20k users, the Calendar home page takes 160s to display the first time, and 3/4s later.
+After 1h (JCR Cache eviction), it takes also 160s to display.
+The problem doesn't occur much with 10k users (7s to display).
+
+Fix description
+
+How is the problem fixed?
+
+* Avoid invoking getChildNodesData() by storing some needed information in lucene index.
+ Need to re-index data to ensure that new changes will work.
+
+Patch file: JCR-1678.patch
+
+Tests to perform
+
+Reproduction test
+ * No
+
+Tests performed at DevLevel
+ * Functional tests
+
+Tests performed at QA/Support Level
+*
+
+Documentation changes
+
+Documentation changes:
+ * No
+
+Configuration changes
+
+Configuration changes:
+ * No
+
+Will previous configuration continue to work?
+ * Yes
+
+Risks and impacts
+
+Can this bug fix have any side effects on current client projects?
+
+ * No
+
+Is there a performance risk/cost?
+ * No
+
+Validation (PM/Support/QA)
+
+PM Comment
+*
+
+Support Comment
+*
+
+QA Feedbacks
+*
12 years, 5 months
exo-jcr SVN: r5235 - in jcr/branches/1.12.x: exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value and 5 other directories.
by do-not-reply@jboss.org
Author: trang_vu
Date: 2011-11-23 07:50:43 -0500 (Wed, 23 Nov 2011)
New Revision: 5235
Added:
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase-sjdbc.properties
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase.properties
jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1689/readme.txt
Modified:
jcr/branches/1.12.x/exo.jcr.component.core/pom.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/util/ConfigurationFormat.java
jcr/branches/1.12.x/exo.jcr.component.core/src/main/resources/binding.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-configuration.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-jcr-config.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration-sjdbc.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config-sjdbc.xml
jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config.xml
Log:
JCR-1689: Add new profiles to run functional tests on all supported DBs
Modified: jcr/branches/1.12.x/exo.jcr.component.core/pom.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/pom.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/pom.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -31,6 +31,11 @@
<description>eXo JCR Service core component</description>
<properties>
<jcr.test.configuration.file>/conf/standalone/test-configuration.xml</jcr.test.configuration.file>
+ <cache.enabled>true</cache.enabled>
+ <value.storage.enabled>true</value.storage.enabled>
+ <statistics.enabled>false</statistics.enabled>
+ <properties.url.suffix>.properties</properties.url.suffix>
+ <properties.url.prefix>classpath:/conf/standalone/default</properties.url.prefix>
</properties>
<dependencies>
<dependency>
@@ -222,95 +227,7 @@
<groupId>hsqldb</groupId>
<artifactId>hsqldb</artifactId>
<scope>test</scope>
- </dependency>
- <!-- For MySQL support -->
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- <version>5.1.8</version>
- <scope>test</scope>
- </dependency>
- <!-- For PostgresSQL support -->
- <dependency>
- <groupId>postgresql</groupId>
- <artifactId>postgresql</artifactId>
- <version>8.3-603.jdbc3</version>
- <scope>test</scope>
- </dependency>
- <!-- For Oracle 10g support (local-jcr repository) -->
- <!-- dependency>
- <groupId>ojdbc</groupId>
- <artifactId>ojdbc</artifactId>
- <version>14</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>ojdbc</groupId>
- <artifactId>orai18n</artifactId>
- <version>14</version>
- <scope>test</scope>
- </dependency -->
- <!-- For IBM DB2 support (local-jcr repository) -->
- <!-- dependency>
- <groupId>com.ibm.db2</groupId>
- <artifactId>db2jcc</artifactId>
- <version>9.1</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>com.ibm.db2</groupId>
- <artifactId>db2jcc_license_cu</artifactId>
- <version>9.1</version>
- <scope>test</scope>
- </dependency -->
- <!-- For MS SQL 7/2000/2005 and Sybase ASE/Anywhere support (jTDS driver) -->
- <!-- dependency>
- <groupId>net.sourceforge.jtds</groupId>
- <artifactId>jtds</artifactId>
- <version>1.2</version>
- <scope>test</scope>
- </dependency -->
- <!-- For MS SQL 2005 support (Microsoft JDBC driver) (local-jcr repository) -->
- <!-- dependency>
- <groupId>com.microsoft.sqlserver</groupId>
- <artifactId>sqljdbc</artifactId>
- <version>9.0</version>
- <scope>test</scope>
- </dependency -->
- <!-- dependency>
- <groupId>com.microsoft</groupId>
- <artifactId>sqljdbc</artifactId>
- <version>2.0</version>
- <scope>test</scope>
- </dependency -->
- <!-- For Apache Derby support (aka JavaDB) -->
- <!-- dependency>
- <groupId>org.apache.derby</groupId>
- <artifactId>derby</artifactId>
- <version>10.2.2.0</version>
- <scope>test</scope>
- </dependency -->
- <!-- H2 Database (not supported now) -->
- <!-- dependency>
- <groupId>com.h2database</groupId>
- <artifactId>h2</artifactId>
- <version>1.0.74</version>
- <scope>test</scope>
- </dependency -->
- <!-- Ingres Database (local repository) -->
- <!-- dependency>
- <groupId>com.ingres.jdbc</groupId>
- <artifactId>iijdbc</artifactId>
- <version>9.2</version>
- <scope>test</scope>
- </dependency -->
- <!-- For Sybase ASE/Anywhere support (jConnect driver) (local-jcr repository) -->
- <!-- dependency>
- <groupId>com.sybase.jdbc3.jdbc</groupId>
- <artifactId>jconn3</artifactId>
- <version>6.05</version>
- <scope>test</scope>
- </dependency -->
+ </dependency>
</dependencies>
<!-- ======================================================================= -->
<build>
@@ -383,11 +300,22 @@
<name>emma.coverage.out.file</name>
<value>target/emma/coverage.ec</value>
</property>
- <!-- Uncomment the line below if you want to enable the statistics -->
- <!--property>
+ <property>
+ <name>cache-enabled</name>
+ <value>${cache.enabled}</value>
+ </property>
+ <property>
+ <name>value-storage-enabled</name>
+ <value>${value.storage.enabled}</value>
+ </property>
+ <property>
<name>JDBCWorkspaceDataContainer.statistics.enabled</name>
- <value>true</value>
- </property-->
+ <value>${statistics.enabled}</value>
+ </property>
+ <property>
+ <name>exo.properties.url</name>
+ <value>${properties.url.prefix}${properties.url.suffix}</value>
+ </property>
<!-- We add this system property due to some incompatibility between IPv6 and
some JVM of Linux distributions such as Ubuntu and Fedora-->
<property>
@@ -569,6 +497,22 @@
<value>target/emma/coverage.ec</value>
</property>
<property>
+ <name>cache-enabled</name>
+ <value>${cache.enabled}</value>
+ </property>
+ <property>
+ <name>value-storage-enabled</name>
+ <value>${value.storage.enabled}</value>
+ </property>
+ <property>
+ <name>JDBCWorkspaceDataContainer.statistics.enabled</name>
+ <value>${statistics.enabled}</value>
+ </property>
+ <property>
+ <name>exo.properties.url</name>
+ <value>${properties.url.prefix}${properties.url.suffix}</value>
+ </property>
+ <property>
<name>known.issues</name>
<value>org.apache.jackrabbit.test.api.SetValueConstraintViolationExceptionTest#testBooleanProperty
org.apache.jackrabbit.test.api.SetValueConstraintViolationExceptionTest#testMultipleBooleanProperty
@@ -585,11 +529,6 @@
org.apache.jackrabbit.test.api.nodetype.PredefinedNodeTypeTest#testVersion
org.apache.jackrabbit.test.api.NamespaceRegistryTest#testRegisterNamespace</value>
</property>
- <!-- Uncomment the line below if you want to enable the statistics -->
- <!--property>
- <name>JDBCWorkspaceDataContainer.statistics.enabled</name>
- <value>true</value>
- </property-->
<!-- We add this system property due to some incompatibility between IPv6 and
some JVM of Linux distributions such as Ubuntu and Fedora-->
<property>
@@ -656,6 +595,22 @@
<value>target/emma/coverage.ec</value>
</property>
<property>
+ <name>cache-enabled</name>
+ <value>${cache.enabled}</value>
+ </property>
+ <property>
+ <name>value-storage-enabled</name>
+ <value>${value.storage.enabled}</value>
+ </property>
+ <property>
+ <name>JDBCWorkspaceDataContainer.statistics.enabled</name>
+ <value>${statistics.enabled}</value>
+ </property>
+ <property>
+ <name>exo.properties.url</name>
+ <value>${properties.url.prefix}${properties.url.suffix}</value>
+ </property>
+ <property>
<name>known.issues</name>
<value>org.apache.jackrabbit.test.api.SetValueConstraintViolationExceptionTest#testBooleanProperty
org.apache.jackrabbit.test.api.SetValueConstraintViolationExceptionTest#testMultipleBooleanProperty
@@ -672,11 +627,6 @@
org.apache.jackrabbit.test.api.nodetype.PredefinedNodeTypeTest#testVersion
org.apache.jackrabbit.test.api.NamespaceRegistryTest#testRegisterNamespace</value>
</property>
- <!-- Uncomment the line below if you want to enable the statistics -->
- <!--property>
- <name>JDBCWorkspaceDataContainer.statistics.enabled</name>
- <value>true</value>
- </property-->
<!-- We add this system property due to some incompatibility between IPv6 and
some JVM of Linux distributions such as Ubuntu and Fedora-->
<property>
@@ -746,58 +696,223 @@
</plugins>
</build>
</profile>
+ <!-- We define one profile per driver -->
<profile>
- <id>run-devtests</id>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <phase>test</phase>
- <forkMode>never</forkMode>
- <!-- argLine>${env.MAVEN_OPTS}</argLine -->
- <goals>
- <goal>test</goal>
- </goals>
- <systemProperties>
- <property>
- <name>jcr.test.configuration.file</name>
- <value>${jcr.test.configuration.file}</value>
- </property>
- <!-- Uncomment the line below if you want to enable the statistics -->
- <!--property>
- <name>JDBCWorkspaceDataContainer.statistics.enabled</name>
- <value>true</value>
- </property-->
- <!-- We add this system property due to some incompatibility between IPv6 and
- some JVM of Linux distributions such as Ubuntu and Fedora-->
- <property>
- <name>java.net.preferIPv4Stack</name>
- <value>true</value>
- </property>
- <!-- Avoid the firewall -->
- <property>
- <name>bind.address</name>
- <value>127.0.0.1</value>
- </property>
- <property>
- <name>jgroups.stack</name>
- <value>udp</value>
- </property>
- </systemProperties>
- <includes>
- <include>**/**/reading_/Test*.java</include>
- <include>**/**/writing_/Test*.java</include>
- <include>**/**/TestJBossCacheWorkspaceStorageCache_.java</include>
- <exclude>**/**/TestCleanableFileStreamValueData.java</exclude>
- <include>**/**/TestSVNodeDataOptimization_.java</include>
- <include>**/**/TestValueConstraints.java</include>
- </includes>
- </configuration>
- </plugin>
- </plugins>
- </build>
+ <id>oracle-10G-R2</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/oracle</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>ojdbc</artifactId>
+ <version>10.2.0.4</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>orai18n</artifactId>
+ <version>10.2.0.4</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
</profile>
+ <profile>
+ <id>oracle-11G-R1</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/oracle</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>ojdbc</artifactId>
+ <version>11.1.0.6.0</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>orai18n</artifactId>
+ <version>11.1.0.6.0</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>oracle-11G-R2</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/oracle</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>ojdbc</artifactId>
+ <version>11.2.0.1.0</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>orai18n</artifactId>
+ <version>11.2.0.1.0</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>mysql-5.0</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/mysql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>mysql</groupId>
+ <artifactId>mysql-connector-java</artifactId>
+ <version>5.0.8</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>mysql-5.1</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/mysql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>mysql</groupId>
+ <artifactId>mysql-connector-java</artifactId>
+ <version>5.1.14</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>mysql-5.5</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/mysql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>mysql</groupId>
+ <artifactId>mysql-connector-java</artifactId>
+ <version>5.1.18</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>mssql</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/mssql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>com.microsoft</groupId>
+ <artifactId>sqljdbc</artifactId>
+ <version>3.0.1301.101</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>db2</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/db2</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>com.ibm.db2</groupId>
+ <artifactId>db2jcc</artifactId>
+ <version>9.7</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.ibm.db2</groupId>
+ <artifactId>db2jcc_license_cu</artifactId>
+ <version>9.7</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>sybase</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/sybase</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>com.sybase.jdbc4.jdbc</groupId>
+ <artifactId>jconn4</artifactId>
+ <version>26502</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>pgsql-8.2</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/pgsql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>postgresql</groupId>
+ <artifactId>postgresql</artifactId>
+ <version>8.2-507.jdbc4</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>pgsql-8.3</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/pgsql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>postgresql</groupId>
+ <artifactId>postgresql</artifactId>
+ <version>8.3-606.jdbc4</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>pgsql-8.4</id>
+ <properties>
+ <properties.url.prefix>classpath:/conf/standalone/pgsql</properties.url.prefix>
+ </properties>
+ <dependencies>
+ <dependency>
+ <groupId>postgresql</groupId>
+ <artifactId>postgresql</artifactId>
+ <version>8.4-702.jdbc4</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>sjdbc</id>
+ <properties>
+ <jcr.test.configuration.file>/conf/standalone/test-configuration-sjdbc.xml</jcr.test.configuration.file>
+ <properties.url.suffix>-sjdbc.properties</properties.url.suffix>
+ </properties>
+ </profile>
+ <profile>
+ <id>cluster</id>
+ <properties>
+ <jcr.test.configuration.file>/conf/standalone/cluster/test-configuration.xml</jcr.test.configuration.file>
+ </properties>
+ </profile>
+ <profile>
+ <id>cache-disabled</id>
+ <properties>
+ <cache.enabled>false</cache.enabled>
+ </properties>
+ </profile>
+ <profile>
+ <id>value-storage-disabled</id>
+ <properties>
+ <value.storage.enabled>false</value.storage.enabled>
+ </properties>
+ </profile>
</profiles>
</project>
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/impl/storage/value/StandaloneStoragePluginProvider.java 2011-11-23 12:50:43 UTC (rev 5235)
@@ -58,6 +58,11 @@
private static Log log = ExoLogger.getLogger("exo.jcr.component.core.StandaloneStoragePluginProvider");
/**
+ * Value storage enabling parameter. For interal usage only and testing purpose.
+ */
+ private static final String VALUE_STORAGE_ENABLED_PARAM = "enabled";
+
+ /**
* ValueData resorces holder (Files etc). It's singleton feature.
*/
private final ValueDataResourceHolder resorcesHolder;
@@ -73,60 +78,62 @@
if (storages != null)
for (ValueStorageEntry storageEntry : storages)
{
-
- // can be only one storage with given id
- for (ValueStoragePlugin vsp : this)
+ if (storageEntry.getParameterBoolean(VALUE_STORAGE_ENABLED_PARAM, true))
{
- if (vsp.getId().equals(storageEntry.getId()))
- throw new RepositoryConfigurationException("Value storage with ID '" + storageEntry.getId()
- + "' already exists");
- }
+ // can be only one storage with given id
+ for (ValueStoragePlugin vsp : this)
+ {
+ if (vsp.getId().equals(storageEntry.getId()))
+ throw new RepositoryConfigurationException("Value storage with ID '" + storageEntry.getId()
+ + "' already exists");
+ }
- Object o = null;
- try
- {
- o =
- Class.forName(storageEntry.getType()).getConstructor(FileCleaner.class).newInstance(
- holder.getFileCleaner());
+ Object o = null;
+ try
+ {
+ o =
+ Class.forName(storageEntry.getType()).getConstructor(FileCleaner.class).newInstance(
+ holder.getFileCleaner());
- }
- catch (Exception e)
- {
- log.error("Value Storage Plugin instantiation FAILED. ", e);
- continue;
- }
- if (!(o instanceof ValueStoragePlugin))
- {
- log.error("Not a ValueStoragePlugin object IGNORED: " + o);
- continue;
- }
+ }
+ catch (Exception e)
+ {
+ log.error("Value Storage Plugin instantiation FAILED. ", e);
+ continue;
+ }
+ if (!(o instanceof ValueStoragePlugin))
+ {
+ log.error("Not a ValueStoragePlugin object IGNORED: " + o);
+ continue;
+ }
- ValueStoragePlugin plugin = (ValueStoragePlugin)o;
- // init filters
- ArrayList<ValuePluginFilter> filters = new ArrayList<ValuePluginFilter>();
- List<ValueStorageFilterEntry> filterEntries = storageEntry.getFilters();
- for (ValueStorageFilterEntry filterEntry : filterEntries)
- {
- ValuePluginFilter filter =
- new ValuePluginFilter(PropertyType.valueFromName(filterEntry.getPropertyType()), null, null,
- filterEntry.getMinValueSize());
- filters.add(filter);
- }
+ ValueStoragePlugin plugin = (ValueStoragePlugin)o;
+ // init filters
+ ArrayList<ValuePluginFilter> filters = new ArrayList<ValuePluginFilter>();
+ List<ValueStorageFilterEntry> filterEntries = storageEntry.getFilters();
+ for (ValueStorageFilterEntry filterEntry : filterEntries)
+ {
+ ValuePluginFilter filter =
+ new ValuePluginFilter(PropertyType.valueFromName(filterEntry.getPropertyType()), null, null,
+ filterEntry.getMinValueSize());
+ filters.add(filter);
+ }
- // init properties
- Properties props = new Properties();
- List<SimpleParameterEntry> paramEntries = storageEntry.getParameters();
- for (SimpleParameterEntry paramEntry : paramEntries)
- {
- props.setProperty(paramEntry.getName(), paramEntry.getValue());
- }
+ // init properties
+ Properties props = new Properties();
+ List<SimpleParameterEntry> paramEntries = storageEntry.getParameters();
+ for (SimpleParameterEntry paramEntry : paramEntries)
+ {
+ props.setProperty(paramEntry.getName(), paramEntry.getValue());
+ }
- plugin.init(props, resorcesHolder);
- plugin.setId(storageEntry.getId());
- plugin.setFilters(filters);
+ plugin.init(props, resorcesHolder);
+ plugin.setId(storageEntry.getId());
+ plugin.setFilters(filters);
- add(plugin);
- log.info("Value Storage Plugin initialized " + plugin);
+ add(plugin);
+ log.info("Value Storage Plugin initialized " + plugin);
+ }
}
}
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/util/ConfigurationFormat.java
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/util/ConfigurationFormat.java 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/util/ConfigurationFormat.java 2011-11-23 12:50:43 UTC (rev 5235)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.jcr.util;
+import org.exoplatform.container.xml.Deserializer;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
@@ -36,6 +37,20 @@
private static final Log LOG = ExoLogger.getLogger("exo.jcr.component.core.ConfigurationFormat");
+ public static boolean parseBoolean(String text)
+ {
+ try
+ {
+ text = Deserializer.resolveNClean(text);
+ return Boolean.valueOf(text).booleanValue();
+ }
+ catch (Throwable e)
+ {
+ LOG.warn("Unparseable boolean '" + text + "'.", e);
+ return false;
+ }
+ }
+
public static int parseInt(String text)
{
try
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/main/resources/binding.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/main/resources/binding.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/main/resources/binding.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -1,6 +1,8 @@
<binding>
<!-- the default deserializer to use for String -->
<format type="java.lang.String" deserializer="org.exoplatform.container.xml.Deserializer.resolveString"/>
+ <!-- the default deserializer to use for boolean -->
+ <format type="boolean" deserializer="org.exoplatform.services.jcr.util.ConfigurationFormat.parseBoolean"/>
<mapping name="repository-service" class="org.exoplatform.services.jcr.config.RepositoryServiceConfiguration">
<value name="default-repository" field="defaultRepositoryName" style="attribute" />
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-configuration.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-configuration.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-configuration.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -247,10 +247,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portal"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr.url}"/>
+ <property name="username" value="${jdbcjcr.username}"/>
+ <property name="password" value="${jdbcjcr.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -274,10 +274,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1.url}"/>
+ <property name="username" value="${jdbcjcr1.username}"/>
+ <property name="password" value="${jdbcjcr1.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -301,10 +301,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr2.url}"/>
+ <property name="username" value="${jdbcjcr2.username}"/>
+ <property name="password" value="${jdbcjcr2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -328,10 +328,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr3"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr3.url}"/>
+ <property name="username" value="${jdbcjcr3.username}"/>
+ <property name="password" value="${jdbcjcr3.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -382,10 +382,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaldb2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcrdb2.url}"/>
+ <property name="username" value="${jdbcjcrdb2.username}"/>
+ <property name="password" value="${jdbcjcrdb2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -409,10 +409,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcrdb2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1db2.url}"/>
+ <property name="username" value="${jdbcjcr1db2.username}"/>
+ <property name="password" value="${jdbcjcr1db2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -436,10 +436,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaltck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcrtck.url}"/>
+ <property name="username" value="${jdbcjcrtck.username}"/>
+ <property name="password" value="${jdbcjcrtck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -463,10 +463,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcrtck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1tck.url}"/>
+ <property name="username" value="${jdbcjcr1tck.username}"/>
+ <property name="password" value="${jdbcjcr1tck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -490,10 +490,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr2tck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr2tck.url}"/>
+ <property name="username" value="${jdbcjcr2tck.username}"/>
+ <property name="password" value="${jdbcjcr2tck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -598,10 +598,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/testdbcleaner"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${testdbcleaner.url}"/>
+ <property name="username" value="${testdbcleaner.username}"/>
+ <property name="password" value="${testdbcleaner.password}"/>
</properties-param>
</init-params>
</component-plugin>
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-jcr-config.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-jcr-config.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/cluster/test-jcr-config.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -33,6 +33,7 @@
class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -45,7 +46,7 @@
<property name="root-nodetype" value="nt:unstructured" />
</properties>
</initializer>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -99,6 +100,7 @@
class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws1" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -106,7 +108,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -170,6 +172,7 @@
class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -177,7 +180,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -242,6 +245,7 @@
class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws3_big" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="1024K" />
@@ -255,6 +259,7 @@
<property name="vcas-type"
value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
<property name="jdbc-source-name" value="jdbcjcr" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -262,7 +267,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -336,6 +341,7 @@
class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/wsdb2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -349,7 +355,7 @@
<property name="root-permissions" value="*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
<property name="jgroups-configuration" value="udp-mux.xml" />
@@ -413,7 +419,7 @@
<property name="root-permissions" value="any read;any add_node;any set_property;any remove" />
</properties>
</initializer>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -489,7 +495,7 @@
value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -567,7 +573,7 @@
value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
@@ -643,7 +649,7 @@
value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true"
+ <cache enabled="${cache-enabled}"
class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="test-jbosscache-data.xml" />
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=com.ibm.db2.jcc.DB2Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1
+jdbcjcr.username=db2inst1
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db2
+jdbcjcrdb2.username=db2inst1
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1tck
+jdbcjcrtck.username=db2inst1
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/dbclns
+testdbcleaner.username=db2inst1
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/db2.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=com.ibm.db2.jcc.DB2Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1_ws
+jdbcjcr.username=db2inst1
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1_ws1
+jdbcjcr1.username=db2inst1
+jdbcjcr1.password=eXoAdmin
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1_ws2
+jdbcjcr2.username=db2inst1
+jdbcjcr2.password=eXoAdmin
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db1_ws3
+jdbcjcr3.username=db2inst1
+jdbcjcr3.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db2_ws
+jdbcjcrdb2.username=db2inst1
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/db2_ws1
+jdbcjcr1db2.username=db2inst1
+jdbcjcr1db2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/dbtckws
+jdbcjcrtck.username=db2inst1
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/dbtckws1
+jdbcjcr1tck.username=db2inst1
+jdbcjcr1tck.password=eXoAdmin
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/dbtckws2
+jdbcjcr2tck.username=db2inst1
+jdbcjcr2tck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:db2://dbs-jcr.exoplatform.com.ua:50002/dbcln
+testdbcleaner.username=db2inst1
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=org.hsqldb.jdbcDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:hsqldb:file:target/temp/data/portal;hsqldb.tx=mvcc
+jdbcjcr.username=sa
+jdbcjcr.password=
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:hsqldb:file:target/temp/data/portaldb2
+jdbcjcrdb2.username=sa
+jdbcjcrdb2.password=
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:hsqldb:file:target/temp/data/portaltck
+jdbcjcrtck.username=sa
+jdbcjcrtck.password=
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:hsqldb:file:target/temp/data/testdbcleaner
+testdbcleaner.username=sa
+testdbcleaner.password=
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/default.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=org.hsqldb.jdbcDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:hsqldb:file:target/temp/data/portal;hsqldb.tx=mvcc
+jdbcjcr.username=sa
+jdbcjcr.password=
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:hsqldb:file:target/temp/data/jcr
+jdbcjcr1.username=sa
+jdbcjcr1.password=
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:hsqldb:file:target/temp/data/jcr2
+jdbcjcr2.username=sa
+jdbcjcr2.password=
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:hsqldb:file:target/temp/data/jcr3
+jdbcjcr3.username=sa
+jdbcjcr3.password=
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:hsqldb:file:target/temp/data/portaldb2
+jdbcjcrdb2.username=sa
+jdbcjcrdb2.password=
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:hsqldb:file:target/temp/data/jcrdb2
+jdbcjcr1db2.username=sa
+jdbcjcr1db2.password=
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:hsqldb:file:target/temp/data/portaltck
+jdbcjcrtck.username=sa
+jdbcjcrtck.password=
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:hsqldb:file:target/temp/data/jcrtck
+jdbcjcr1tck.username=sa
+jdbcjcr1tck.password=
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:hsqldb:file:target/temp/data/jcr2tck
+jdbcjcr2tck.username=sa
+jdbcjcr2tck.password=
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:hsqldb:file:target/temp/data/testdbcleaner
+testdbcleaner.username=sa
+testdbcleaner.password=
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:sqlserver://localhost:1433;databaseName=db1;
+jdbcjcr.username=tester
+jdbcjcr.password=tester
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:sqlserver://localhost:1433;databaseName=db2;
+jdbcjcrdb2.username=tester
+jdbcjcrdb2.password=tester
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:sqlserver://localhost:1433;databaseName=db1tck;
+jdbcjcrtck.username=tester
+jdbcjcrtck.password=tester
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:sqlserver://localhost:1433;databaseName=testdbcleaner_sjdbc;
+testdbcleaner.username=tester
+testdbcleaner.password=tester
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mssql.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:sqlserver://localhost:1433;databaseName=db1_ws;
+jdbcjcr.username=tester
+jdbcjcr.password=tester
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:sqlserver://localhost:1433;databaseName=db1_ws1;
+jdbcjcr1.username=tester
+jdbcjcr1.password=tester
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:sqlserver://localhost:1433;databaseName=db1_ws2;
+jdbcjcr2.username=tester
+jdbcjcr2.password=tester
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:sqlserver://localhost:1433;databaseName=db1_ws3;
+jdbcjcr3.username=tester
+jdbcjcr3.password=tester
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:sqlserver://localhost:1433;databaseName=db2_ws;
+jdbcjcrdb2.username=tester
+jdbcjcrdb2.password=tester
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:sqlserver://localhost:1433;databaseName=db2_ws1;
+jdbcjcr1db2.username=tester
+jdbcjcr1db2.password=tester
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:sqlserver://localhost:1433;databaseName=db1tck_ws;
+jdbcjcrtck.username=tester
+jdbcjcrtck.password=tester
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:sqlserver://localhost:1433;databaseName=db1tck_ws1;
+jdbcjcr1tck.username=tester
+jdbcjcr1tck.password=tester
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:sqlserver://localhost:1433;databaseName=db1tck_ws2;
+jdbcjcr2tck.username=tester
+jdbcjcr2tck.password=tester
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:sqlserver://localhost:1433;databaseName=testdbcleaner;
+testdbcleaner.username=tester
+testdbcleaner.password=tester
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=com.mysql.jdbc.Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:mysql://localhost/db1
+jdbcjcr.username=root
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:mysql://localhost/db2
+jdbcjcrdb2.username=root
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:mysql://localhost/db1tck
+jdbcjcrtck.username=root
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:mysql://localhost/testdbcleaner_sjdbc
+testdbcleaner.username=root
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/mysql.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=com.mysql.jdbc.Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:mysql://localhost/db1_ws
+jdbcjcr.username=root
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:mysql://localhost/db1_ws1
+jdbcjcr1.username=root
+jdbcjcr1.password=eXoAdmin
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:mysql://localhost/db1_ws2
+jdbcjcr2.username=root
+jdbcjcr2.password=eXoAdmin
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:mysql://localhost/db1_ws3
+jdbcjcr3.username=root
+jdbcjcr3.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:mysql://localhost/db2_ws
+jdbcjcrdb2.username=root
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:mysql://localhost/db2_ws1
+jdbcjcr1db2.username=root
+jdbcjcr1db2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:mysql://localhost/db1tck_ws
+jdbcjcrtck.username=root
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:mysql://localhost/db1tck_ws1
+jdbcjcr1tck.username=root
+jdbcjcr1tck.password=eXoAdmin
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:mysql://localhost/db1tck_ws2
+jdbcjcr2tck.username=root
+jdbcjcr2tck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:mysql://localhost/testdbcleaner
+testdbcleaner.username=root
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=oracle.jdbc.OracleDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr.username=exoperf
+jdbcjcr.password=exo12321
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcrdb2.username=exoperf1
+jdbcjcrdb2.password=exo12321
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcrtck.username=exoperf2
+jdbcjcrtck.password=exo12321
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+testdbcleaner.username=exoperf3
+testdbcleaner.password=exo12321
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/oracle.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=oracle.jdbc.OracleDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr.username=exoperfdb1_ws
+jdbcjcr.password=exo12321
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr1.username=exoperfdb1_ws1
+jdbcjcr1.password=exo12321
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr2.username=exoperfdb1_ws2
+jdbcjcr2.password=exo12321
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr3.username=exoperfdb1_ws3
+jdbcjcr3.password=exo12321
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcrdb2.username=exoperfdb2_ws
+jdbcjcrdb2.password=exo12321
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr1db2.username=exoperfdb2_ws1
+jdbcjcr1db2.password=exo12321
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcrtck.username=exoperfdb1tck_ws
+jdbcjcrtck.password=exo12321
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr1tck.username=exoperfdb1tck_ws1
+jdbcjcr1tck.password=exo12321
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+jdbcjcr2tck.username=exoperfdb1tck_ws2
+jdbcjcr2tck.password=exo12321
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:oracle:thin:@v06.storm.exoplatform.com.ua:1521:orclvm
+testdbcleaner.username=exoperftestdbcleaner
+testdbcleaner.password=exo12321
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=org.postgresql.Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:postgresql://localhost:5433/db1
+jdbcjcr.username=root
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:postgresql://localhost:5433/db2
+jdbcjcrdb2.username=root
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:postgresql://localhost:5433/db1tck
+jdbcjcrtck.username=root
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:postgresql://localhost:5433/testdbcleaner
+testdbcleaner.username=root
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/pgsql.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=org.postgresql.Driver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:postgresql://localhost:5433/db1_ws
+jdbcjcr.username=root
+jdbcjcr.password=eXoAdmin
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:postgresql://localhost:5433/db1_ws1
+jdbcjcr1.username=root
+jdbcjcr1.password=eXoAdmin
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:postgresql://localhost:5433/db1_ws2
+jdbcjcr2.username=root
+jdbcjcr2.password=eXoAdmin
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:postgresql://localhost:5433/db1_ws3
+jdbcjcr3.username=root
+jdbcjcr3.password=eXoAdmin
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:postgresql://localhost:5433/db2_ws
+jdbcjcrdb2.username=root
+jdbcjcrdb2.password=eXoAdmin
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:postgresql://localhost:5433/db2_ws1
+jdbcjcr1db2.username=root
+jdbcjcr1db2.password=eXoAdmin
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:postgresql://localhost:5433/db1tck_ws
+jdbcjcrtck.username=root
+jdbcjcrtck.password=eXoAdmin
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:postgresql://localhost:5433/db1tck_ws1
+jdbcjcr1tck.username=root
+jdbcjcr1tck.password=eXoAdmin
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:postgresql://localhost:5433/db1tck_ws2
+jdbcjcr2tck.username=root
+jdbcjcr2tck.password=eXoAdmin
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:postgresql://localhost:5433/testdbcleaner_sjdbc
+testdbcleaner.username=root
+testdbcleaner.password=eXoAdmin
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase-sjdbc.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase-sjdbc.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase-sjdbc.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,22 @@
+# Global Properties
+all.driverClassName=com.sybase.jdbc4.jdbc.SybDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:sybase:Tds:localhost:5003/db1
+jdbcjcr.username=sa
+jdbcjcr.password=
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:sybase:Tds:localhost:5003/db2
+jdbcjcrdb2.username=sa
+jdbcjcrdb2.password=
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:sybase:Tds:localhost:5003/db1_tck
+jdbcjcrtck.username=sa
+jdbcjcrtck.password=
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:sybase:Tds:localhost:5003/testdbcleaner_sjdbc
+testdbcleaner.username=sa
+testdbcleaner.password=
\ No newline at end of file
Added: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase.properties
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase.properties (rev 0)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/sybase.properties 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,52 @@
+# Global Properties
+all.driverClassName=com.sybase.jdbc4.jdbc.SybDriver
+
+# Properties for jdbcjcr
+jdbcjcr.url=jdbc:sybase:Tds:localhost:5003/db1_ws
+jdbcjcr.username=sa
+jdbcjcr.password=
+
+# Properties for jdbcjcr1
+jdbcjcr1.url=jdbc:sybase:Tds:localhost:5003/db1_ws1
+jdbcjcr1.username=sa
+jdbcjcr1.password=
+
+# Properties for jdbcjcr2
+jdbcjcr2.url=jdbc:sybase:Tds:localhost:5003/db1_ws2
+jdbcjcr2.username=sa
+jdbcjcr2.password=
+
+# Properties for jdbcjcr3
+jdbcjcr3.url=jdbc:sybase:Tds:localhost:5003/db1_ws3
+jdbcjcr3.username=sa
+jdbcjcr3.password=
+
+# Properties for jdbcjcrdb2
+jdbcjcrdb2.url=jdbc:sybase:Tds:localhost:5003/db2_ws
+jdbcjcrdb2.username=sa
+jdbcjcrdb2.password=
+
+# Properties for jdbcjcr1db2
+jdbcjcr1db2.url=jdbc:sybase:Tds:localhost:5003/db2_ws1
+jdbcjcr1db2.username=sa
+jdbcjcr1db2.password=
+
+# Properties for jdbcjcrtck
+jdbcjcrtck.url=jdbc:sybase:Tds:localhost:5003/db1tck_ws
+jdbcjcrtck.username=sa
+jdbcjcrtck.password=
+
+# Properties for jdbcjcr1tck
+jdbcjcr1tck.url=jdbc:sybase:Tds:localhost:5003/db1tck_ws1
+jdbcjcr1tck.username=sa
+jdbcjcr1tck.password=
+
+# Properties for jdbcjcr2tck
+jdbcjcr2tck.url=jdbc:sybase:Tds:localhost:5003/db1tck_ws2
+jdbcjcr2tck.username=sa
+jdbcjcr2tck.password=
+
+# Properties for testdbcleaner
+testdbcleaner.url=jdbc:sybase:Tds:localhost:5003/testdbcleaner
+testdbcleaner.username=sa
+testdbcleaner.password=
\ No newline at end of file
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration-sjdbc.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration-sjdbc.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration-sjdbc.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -248,10 +248,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portal"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr.url}"/>
+ <property name="username" value="${jdbcjcr.username}"/>
+ <property name="password" value="${jdbcjcr.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -302,10 +302,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaldb2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcrdb2.url}"/>
+ <property name="username" value="${jdbcjcrdb2.username}"/>
+ <property name="password" value="${jdbcjcrdb2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -329,10 +329,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaltck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>^
+ <property name="url" value="${jdbcjcrtck.url}"/>^
+ <property name="username" value="${jdbcjcrtck.username}"/>^
+ <property name="password" value="${jdbcjcrtck.password}"/>^
</properties-param>
</init-params>
</component-plugin>
@@ -436,11 +436,11 @@
</value-param>
<properties-param>
<name>ref-addresses</name>
- <description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/testdbcleaner"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <description>ref-addresses</description>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${testdbcleaner.url}"/>
+ <property name="username" value="${testdbcleaner.username}"/>
+ <property name="password" value="${testdbcleaner.password}"/>
</properties-param>
</init-params>
</component-plugin>
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-configuration.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -248,10 +248,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portal"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr.url}"/>
+ <property name="username" value="${jdbcjcr.username}"/>
+ <property name="password" value="${jdbcjcr.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -275,10 +275,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1.url}"/>
+ <property name="username" value="${jdbcjcr1.username}"/>
+ <property name="password" value="${jdbcjcr1.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -302,10 +302,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr2.url}"/>
+ <property name="username" value="${jdbcjcr2.username}"/>
+ <property name="password" value="${jdbcjcr2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -329,10 +329,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr3"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr3.url}"/>
+ <property name="username" value="${jdbcjcr3.username}"/>
+ <property name="password" value="${jdbcjcr3.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -383,10 +383,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaldb2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcrdb2.url}"/>
+ <property name="username" value="${jdbcjcrdb2.username}"/>
+ <property name="password" value="${jdbcjcrdb2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -410,10 +410,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcrdb2"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1db2.url}"/>
+ <property name="username" value="${jdbcjcr1db2.username}"/>
+ <property name="password" value="${jdbcjcr1db2.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -437,10 +437,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/portaltck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcrtck.url}"/>
+ <property name="username" value="${jdbcjcrtck.username}"/>
+ <property name="password" value="${jdbcjcrtck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -464,10 +464,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcrtck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr1tck.url}"/>
+ <property name="username" value="${jdbcjcr1tck.username}"/>
+ <property name="password" value="${jdbcjcr1tck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -491,10 +491,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/jcr2tck"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${jdbcjcr2tck.url}"/>
+ <property name="username" value="${jdbcjcr2tck.username}"/>
+ <property name="password" value="${jdbcjcr2tck.password}"/>
</properties-param>
</init-params>
</component-plugin>
@@ -599,10 +599,10 @@
<properties-param>
<name>ref-addresses</name>
<description>ref-addresses</description>
- <property name="driverClassName" value="org.hsqldb.jdbcDriver"/>
- <property name="url" value="jdbc:hsqldb:file:target/temp/data/testdbcleaner"/>
- <property name="username" value="sa"/>
- <property name="password" value=""/>
+ <property name="driverClassName" value="${all.driverClassName}"/>
+ <property name="url" value="${testdbcleaner.url}"/>
+ <property name="username" value="${testdbcleaner.username}"/>
+ <property name="password" value="${testdbcleaner.password}"/>
</properties-param>
</init-params>
</component-plugin>
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config-sjdbc.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config-sjdbc.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config-sjdbc.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -47,6 +47,7 @@
<property name="vcas-type" value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
<property name="jdbc-source-name" value="jdbcjcr" />
<property name="jdbc-dialect" value="auto" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -65,7 +66,7 @@
<property name="restore-path" value="./src/test/resources/import-export/restore_db1_ws1.xml" />
</properties>
</initializer -->
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -108,6 +109,7 @@
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws1" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -115,7 +117,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -161,6 +163,7 @@
<value-storage id="ws2" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -168,7 +171,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -199,91 +202,81 @@
</properties>
</lock-manager>
</workspace>
-
+
<workspace name="ws3">
- <!-- for system storage -->
- <container
- class="org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.CQJDBCWorkspaceDataContainer">
- <properties>
- <property name="source-name" value="jdbcjcr" />
- <property name="dialect" value="auto" />
- <property name="multi-db" value="false" />
- <property name="update-storage" value="false" />
- <property name="max-buffer-size" value="200k" />
- <property name="swap-directory" value="target/temp/swap/ws3" />
- </properties>
- <value-storages>
- <!--
- This storage is used to check whether properties are removed
- correctly from each value-storage
- (TestRemoveFromValueStorage.java)
- -->
- <value-storage id="ws3_big"
- class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
- <properties>
- <property name="path" value="target/temp/values/ws3_big" />
- </properties>
- <filters>
- <filter property-type="Binary" min-value-size="1024K" />
- </filters>
- </value-storage>
- <value-storage id="ws3"
- class="org.exoplatform.services.jcr.impl.storage.value.fs.CASableTreeFileValueStorage">
- <properties>
- <property name="path" value="target/temp/values/ws3" />
- <property name="digest-algo" value="MD5" />
- <property name="vcas-type"
- value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
- <property name="jdbc-source-name" value="jdbcjcr" />
- </properties>
- <filters>
- <filter property-type="Binary" />
- </filters>
- </value-storage>
- </value-storages>
- </container>
- <initializer
- class="org.exoplatform.services.jcr.impl.core.ScratchWorkspaceInitializer">
- <properties>
- <property name="root-nodetype" value="nt:unstructured" />
- </properties>
- </initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
- <properties>
- <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
- </properties>
- </cache>
- <query-handler
- class="org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex">
- <properties>
- <property name="index-dir" value="target/temp/index/db1/ws3" />
- <property name="synonymprovider-class"
- value="org.exoplatform.services.jcr.impl.core.query.lucene.PropertiesSynonymProvider" />
- <property name="synonymprovider-config-path" value="../../synonyms.properties" />
- <property name="support-highlighting" value="true" />
- <property name="indexing-configuration-path" value="../../indexing-configuration.xml" />
- <property name="query-class"
- value="org.exoplatform.services.jcr.impl.core.query.QueryImpl" />
- <property name="spellchecker-class"
- value="org.exoplatform.services.jcr.impl.core.query.lucene.spell.LuceneSpellChecker$FiveSecondsRefreshInterval" />
- </properties>
- </query-handler>
- <lock-manager class="org.exoplatform.services.jcr.impl.core.lock.jbosscache.CacheableLockManagerImpl">
- <properties>
- <property name="time-out" value="15m" />
- <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-lock.xml" />
- <property name="jbosscache-cl-cache.jdbc.table.name" value="jcrlocks_db1_ws3" />
- <property name="jbosscache-cl-cache.jdbc.table.create" value="true" />
- <property name="jbosscache-cl-cache.jdbc.table.drop" value="false" />
- <property name="jbosscache-cl-cache.jdbc.table.primarykey" value="jcrlocks_db1_ws3_pk" />
- <property name="jbosscache-cl-cache.jdbc.fqn.column" value="fqn" />
- <property name="jbosscache-cl-cache.jdbc.node.column" value="node" />
- <property name="jbosscache-cl-cache.jdbc.parent.column" value="parent" />
- <property name="jbosscache-cl-cache.jdbc.datasource" value="jdbcjcr" />
- </properties>
- </lock-manager>
-
- </workspace>
+ <!-- for system storage -->
+ <container class="org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.CQJDBCWorkspaceDataContainer">
+ <properties>
+ <property name="source-name" value="jdbcjcr" />
+ <property name="dialect" value="auto" />
+ <property name="multi-db" value="false" />
+ <property name="update-storage" value="false" />
+ <property name="max-buffer-size" value="200k" />
+ <property name="swap-directory" value="target/temp/swap/ws3" />
+ </properties>
+ <value-storages>
+ <!--
+ This storage is used to check whether properties are removed correctly from each value-storage (TestRemoveFromValueStorage.java)
+ -->
+ <value-storage id="ws3_big" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
+ <properties>
+ <property name="path" value="target/temp/values/ws3_big" />
+ <property name="enabled" value="${value-storage-enabled}" />
+ </properties>
+ <filters>
+ <filter property-type="Binary" min-value-size="1024K" />
+ </filters>
+ </value-storage>
+ <value-storage id="ws3" class="org.exoplatform.services.jcr.impl.storage.value.fs.CASableTreeFileValueStorage">
+ <properties>
+ <property name="path" value="target/temp/values/ws3" />
+ <property name="digest-algo" value="MD5" />
+ <property name="vcas-type" value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
+ <property name="jdbc-source-name" value="jdbcjcr" />
+ <property name="enabled" value="${value-storage-enabled}" />
+ </properties>
+ <filters>
+ <filter property-type="Binary" />
+ </filters>
+ </value-storage>
+ </value-storages>
+ </container>
+ <initializer class="org.exoplatform.services.jcr.impl.core.ScratchWorkspaceInitializer">
+ <properties>
+ <property name="root-nodetype" value="nt:unstructured" />
+ </properties>
+ </initializer>
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <properties>
+ <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
+ </properties>
+ </cache>
+ <query-handler class="org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex">
+ <properties>
+ <property name="index-dir" value="target/temp/index/db1/ws3" />
+ <property name="synonymprovider-class" value="org.exoplatform.services.jcr.impl.core.query.lucene.PropertiesSynonymProvider" />
+ <property name="synonymprovider-config-path" value="../../synonyms.properties" />
+ <property name="support-highlighting" value="true" />
+ <property name="indexing-configuration-path" value="../../indexing-configuration.xml" />
+ <property name="query-class" value="org.exoplatform.services.jcr.impl.core.query.QueryImpl" />
+ <property name="spellchecker-class" value="org.exoplatform.services.jcr.impl.core.query.lucene.spell.LuceneSpellChecker$FiveSecondsRefreshInterval" />
+ </properties>
+ </query-handler>
+ <lock-manager class="org.exoplatform.services.jcr.impl.core.lock.jbosscache.CacheableLockManagerImpl">
+ <properties>
+ <property name="time-out" value="15m" />
+ <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-lock.xml" />
+ <property name="jbosscache-cl-cache.jdbc.table.name" value="jcrlocks_db1_ws3" />
+ <property name="jbosscache-cl-cache.jdbc.table.create" value="true" />
+ <property name="jbosscache-cl-cache.jdbc.table.drop" value="false" />
+ <property name="jbosscache-cl-cache.jdbc.table.primarykey" value="jcrlocks_db1_ws3_pk" />
+ <property name="jbosscache-cl-cache.jdbc.fqn.column" value="fqn" />
+ <property name="jbosscache-cl-cache.jdbc.node.column" value="node" />
+ <property name="jbosscache-cl-cache.jdbc.parent.column" value="parent" />
+ <property name="jbosscache-cl-cache.jdbc.datasource" value="jdbcjcr" />
+ </properties>
+ </lock-manager>
+ </workspace>
</workspaces>
</repository>
@@ -309,6 +302,7 @@
<value-storage id="ws" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/wsdb2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -322,7 +316,7 @@
<property name="root-permissions" value="*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
<property name="jbosscache-shareable" value="${jbosscache-shareable}" />
@@ -364,6 +358,7 @@
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws1db2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -377,7 +372,7 @@
<property name="root-permissions" value="any read;any add_node;any set_property;any remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
<property name="jbosscache-shareable" value="${jbosscache-shareable}" />
@@ -429,6 +424,7 @@
<value-storage id="ws" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/wstck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -442,7 +438,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -489,6 +485,7 @@
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws1tck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -502,7 +499,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -548,6 +545,7 @@
<value-storage id="ws2" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
<property name="path" value="target/temp/values/ws2tck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -561,7 +559,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
Modified: jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config.xml
===================================================================
--- jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config.xml 2011-11-23 12:37:54 UTC (rev 5234)
+++ jcr/branches/1.12.x/exo.jcr.component.core/src/test/resources/conf/standalone/test-jcr-config.xml 2011-11-23 12:50:43 UTC (rev 5235)
@@ -46,7 +46,8 @@
<property name="digest-algo" value="MD5" />
<property name="vcas-type" value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
<property name="jdbc-source-name" value="jdbcjcr" />
- <property name="jdbc-dialect" value="auto" />
+ <property name="jdbc-dialect" value="auto" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -65,7 +66,7 @@
<property name="restore-path" value="./src/test/resources/import-export/restore_db1_ws1.xml" />
</properties>
</initializer -->
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -107,7 +108,8 @@
<value-storages>
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/ws1" />
+ <property name="path" value="target/temp/values/ws1" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -115,7 +117,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -160,7 +162,8 @@
<value-storages>
<value-storage id="ws2" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/ws2" />
+ <property name="path" value="target/temp/values/ws2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" />
@@ -168,7 +171,7 @@
</value-storage>
</value-storages>
</container>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -199,91 +202,81 @@
</properties>
</lock-manager>
</workspace>
-
- <workspace name="ws3">
- <!-- for system storage -->
- <container
- class="org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.CQJDBCWorkspaceDataContainer">
- <properties>
- <property name="source-name" value="jdbcjcr3" />
- <property name="dialect" value="auto" />
- <property name="multi-db" value="true" />
- <property name="update-storage" value="false" />
- <property name="max-buffer-size" value="200k" />
- <property name="swap-directory" value="target/temp/swap/ws3" />
- </properties>
- <value-storages>
- <!--
- This storage is used to check whether properties are removed
- correctly from each value-storage
- (TestRemoveFromValueStorage.java)
- -->
- <value-storage id="ws3_big"
- class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
- <properties>
- <property name="path" value="target/temp/values/ws3_big" />
- </properties>
- <filters>
- <filter property-type="Binary" min-value-size="1024K" />
- </filters>
- </value-storage>
- <value-storage id="ws3"
- class="org.exoplatform.services.jcr.impl.storage.value.fs.CASableTreeFileValueStorage">
- <properties>
- <property name="path" value="target/temp/values/ws3" />
- <property name="digest-algo" value="MD5" />
- <property name="vcas-type"
- value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
- <property name="jdbc-source-name" value="jdbcjcr" />
- </properties>
- <filters>
- <filter property-type="Binary" />
- </filters>
- </value-storage>
- </value-storages>
- </container>
- <initializer
- class="org.exoplatform.services.jcr.impl.core.ScratchWorkspaceInitializer">
- <properties>
- <property name="root-nodetype" value="nt:unstructured" />
- </properties>
- </initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
- <properties>
- <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
- </properties>
- </cache>
- <query-handler
- class="org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex">
- <properties>
- <property name="index-dir" value="target/temp/index/db1/ws3" />
- <property name="synonymprovider-class"
- value="org.exoplatform.services.jcr.impl.core.query.lucene.PropertiesSynonymProvider" />
- <property name="synonymprovider-config-path" value="../../synonyms.properties" />
- <property name="support-highlighting" value="true" />
- <property name="indexing-configuration-path" value="../../indexing-configuration.xml" />
- <property name="query-class"
- value="org.exoplatform.services.jcr.impl.core.query.QueryImpl" />
- <property name="spellchecker-class"
- value="org.exoplatform.services.jcr.impl.core.query.lucene.spell.LuceneSpellChecker$FiveSecondsRefreshInterval" />
- </properties>
- </query-handler>
- <lock-manager class="org.exoplatform.services.jcr.impl.core.lock.jbosscache.CacheableLockManagerImpl">
- <properties>
- <property name="time-out" value="15m" />
- <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-lock.xml" />
- <property name="jbosscache-cl-cache.jdbc.table.name" value="jcrlocks_db1_ws3" />
- <property name="jbosscache-cl-cache.jdbc.table.create" value="true" />
- <property name="jbosscache-cl-cache.jdbc.table.drop" value="false" />
- <property name="jbosscache-cl-cache.jdbc.table.primarykey" value="jcrlocks_db1_ws3_pk" />
- <property name="jbosscache-cl-cache.jdbc.fqn.column" value="fqn" />
- <property name="jbosscache-cl-cache.jdbc.node.column" value="node" />
- <property name="jbosscache-cl-cache.jdbc.parent.column" value="parent" />
- <property name="jbosscache-cl-cache.jdbc.datasource" value="jdbcjcr3" />
- </properties>
- </lock-manager>
- </workspace>
+ <workspace name="ws3">
+ <!-- for system storage -->
+ <container class="org.exoplatform.services.jcr.impl.storage.jdbc.optimisation.CQJDBCWorkspaceDataContainer">
+ <properties>
+ <property name="source-name" value="jdbcjcr3" />
+ <property name="dialect" value="auto" />
+ <property name="multi-db" value="true" />
+ <property name="update-storage" value="false" />
+ <property name="max-buffer-size" value="200k" />
+ <property name="swap-directory" value="target/temp/swap/ws3" />
+ </properties>
+ <value-storages>
+ <!--
+ This storage is used to check whether properties are removed correctly from each value-storage (TestRemoveFromValueStorage.java)
+ -->
+ <value-storage id="ws3_big" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
+ <properties>
+ <property name="path" value="target/temp/values/ws3_big" />
+ <property name="enabled" value="${value-storage-enabled}" />
+ </properties>
+ <filters>
+ <filter property-type="Binary" min-value-size="1024K" />
+ </filters>
+ </value-storage>
+ <value-storage id="ws3" class="org.exoplatform.services.jcr.impl.storage.value.fs.CASableTreeFileValueStorage">
+ <properties>
+ <property name="path" value="target/temp/values/ws3" />
+ <property name="digest-algo" value="MD5" />
+ <property name="vcas-type" value="org.exoplatform.services.jcr.impl.storage.value.cas.JDBCValueContentAddressStorageImpl" />
+ <property name="jdbc-source-name" value="jdbcjcr" />
+ <property name="enabled" value="${value-storage-enabled}" />
+ </properties>
+ <filters>
+ <filter property-type="Binary" />
+ </filters>
+ </value-storage>
+ </value-storages>
+ </container>
+ <initializer class="org.exoplatform.services.jcr.impl.core.ScratchWorkspaceInitializer">
+ <properties>
+ <property name="root-nodetype" value="nt:unstructured" />
+ </properties>
+ </initializer>
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <properties>
+ <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
+ </properties>
+ </cache>
+ <query-handler class="org.exoplatform.services.jcr.impl.core.query.lucene.SearchIndex">
+ <properties>
+ <property name="index-dir" value="target/temp/index/db1/ws3" />
+ <property name="synonymprovider-class" value="org.exoplatform.services.jcr.impl.core.query.lucene.PropertiesSynonymProvider" />
+ <property name="synonymprovider-config-path" value="../../synonyms.properties" />
+ <property name="support-highlighting" value="true" />
+ <property name="indexing-configuration-path" value="../../indexing-configuration.xml" />
+ <property name="query-class" value="org.exoplatform.services.jcr.impl.core.query.QueryImpl" />
+ <property name="spellchecker-class" value="org.exoplatform.services.jcr.impl.core.query.lucene.spell.LuceneSpellChecker$FiveSecondsRefreshInterval" />
+ </properties>
+ </query-handler>
+ <lock-manager class="org.exoplatform.services.jcr.impl.core.lock.jbosscache.CacheableLockManagerImpl">
+ <properties>
+ <property name="time-out" value="15m" />
+ <property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-lock.xml" />
+ <property name="jbosscache-cl-cache.jdbc.table.name" value="jcrlocks_db1_ws3" />
+ <property name="jbosscache-cl-cache.jdbc.table.create" value="true" />
+ <property name="jbosscache-cl-cache.jdbc.table.drop" value="false" />
+ <property name="jbosscache-cl-cache.jdbc.table.primarykey" value="jcrlocks_db1_ws3_pk" />
+ <property name="jbosscache-cl-cache.jdbc.fqn.column" value="fqn" />
+ <property name="jbosscache-cl-cache.jdbc.node.column" value="node" />
+ <property name="jbosscache-cl-cache.jdbc.parent.column" value="parent" />
+ <property name="jbosscache-cl-cache.jdbc.datasource" value="jdbcjcr3" />
+ </properties>
+ </lock-manager>
+ </workspace>
</workspaces>
</repository>
@@ -308,7 +301,8 @@
<value-storages>
<value-storage id="ws" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/wsdb2" />
+ <property name="path" value="target/temp/values/wsdb2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -322,7 +316,7 @@
<property name="root-permissions" value="*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
<property name="jbosscache-shareable" value="${jbosscache-shareable}" />
@@ -363,7 +357,8 @@
<value-storages>
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/ws1db2" />
+ <property name="path" value="target/temp/values/ws1db2" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -377,7 +372,7 @@
<property name="root-permissions" value="any read;any add_node;any set_property;any remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
<property name="jbosscache-shareable" value="${jbosscache-shareable}" />
@@ -429,7 +424,8 @@
<value-storages>
<value-storage id="ws" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/wstck" />
+ <property name="path" value="target/temp/values/wstck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -443,7 +439,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -489,7 +485,8 @@
<value-storages>
<value-storage id="ws1" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/ws1tck" />
+ <property name="path" value="target/temp/values/ws1tck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -503,7 +500,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
@@ -548,7 +545,8 @@
<value-storages>
<value-storage id="ws2" class="org.exoplatform.services.jcr.impl.storage.value.fs.TreeFileValueStorage">
<properties>
- <property name="path" value="target/temp/values/ws2tck" />
+ <property name="path" value="target/temp/values/ws2tck" />
+ <property name="enabled" value="${value-storage-enabled}" />
</properties>
<filters>
<filter property-type="Binary" min-value-size="100K" />
@@ -562,7 +560,7 @@
<property name="root-permissions" value="any read;*:/platform/administrators read;*:/platform/administrators add_node;*:/platform/administrators set_property;*:/platform/administrators remove" />
</properties>
</initializer>
- <cache enabled="true" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
+ <cache enabled="${cache-enabled}" class="org.exoplatform.services.jcr.impl.dataflow.persistent.jbosscache.JBossCacheWorkspaceStorageCache">
<properties>
<property name="jbosscache-configuration" value="conf/standalone/test-jbosscache-config.xml" />
</properties>
Added: jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1689/readme.txt
===================================================================
--- jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1689/readme.txt (rev 0)
+++ jcr/branches/1.12.x/patch/1.12.11-GA/JCR-1689/readme.txt 2011-11-23 12:50:43 UTC (rev 5235)
@@ -0,0 +1,70 @@
+Summary
+
+ * Status: Propose a maven profile for each supported configuration
+ * CCP Issue: N/A, Product Jira Issue: JCR-1689.
+ * Depends on KER-180
+ * Complexity: Low
+
+The Proposal
+Problem description
+
+What is the problem to fix?
+To allow the QA to launch the functional tests on each supported config composed of DB Type/DB Version/Driver Version we need to add the remaining profiles in order to have the full list.
+
+Fix description
+
+How is the problem fixed?
+ * Add new profiles to run functional tests on all supported DBs
+
+Patch file: JCR-1689.patch
+
+Tests to perform
+
+Reproduction test
+
+ * No
+
+Tests performed at DevLevel
+
+ * No
+
+Tests performed at QA/Support Level
+
+ *
+
+Documentation changes
+
+Documentation changes:
+
+ * No
+
+Configuration changes
+
+Configuration changes:
+
+ * No
+
+Will previous configuration continue to work?
+
+ * Yes
+
+Risks and impacts
+
+Can this bug fix have any side effects on current client projects?
+
+ * No
+
+Is there a performance risk/cost?
+
+ * No
+
+Validation (PM/Support/QA)
+
+PM Comment
+* PM validated
+
+Support Comment
+* Validated by PM on behalf of Support
+
+QA Feedbacks
+*
12 years, 5 months
exo-jcr SVN: r5234 - in core/branches/2.3.x: exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap and 3 other directories.
by do-not-reply@jboss.org
Author: trang_vu
Date: 2011-11-23 07:37:54 -0500 (Wed, 23 Nov 2011)
New Revision: 5234
Added:
core/branches/2.3.x/patch/2.3.11-GA/COR-237/
core/branches/2.3.x/patch/2.3.11-GA/COR-237/readme.txt
Removed:
core/branches/2.3.x/patch/2.3.10/COR-237/
Modified:
core/branches/2.3.x/exo.core.component.ldap/src/main/java/org/exoplatform/services/ldap/impl/LDAPServiceImpl.java
core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java
core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/MembershipDAOImpl.java
core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/OrganizationLdapInitializer.java
Log:
COR-237: minConnection and maxConnection params in the ldap configuration are not used
Fix description
Use minConnection and maxConnection to set up com.sun.jndi.ldap.connect.pool.initsize and com.sun.jndi.ldap.connect.pool.prefsize, precisely:
* com.sun.jndi.ldap.connect.pool.initsize and com.sun.jndi.ldap.connect.pool.prefsize are set to minConnection if minConnection > 0
* com.sun.jndi.ldap.connect.pool.maxsize are set to maxConnection if maxConnection > 0
Modified: core/branches/2.3.x/exo.core.component.ldap/src/main/java/org/exoplatform/services/ldap/impl/LDAPServiceImpl.java
===================================================================
--- core/branches/2.3.x/exo.core.component.ldap/src/main/java/org/exoplatform/services/ldap/impl/LDAPServiceImpl.java 2011-11-23 12:32:33 UTC (rev 5233)
+++ core/branches/2.3.x/exo.core.component.ldap/src/main/java/org/exoplatform/services/ldap/impl/LDAPServiceImpl.java 2011-11-23 12:37:54 UTC (rev 5234)
@@ -83,9 +83,20 @@
env.put(Context.SECURITY_AUTHENTICATION, config.getAuthenticationType());
env.put(Context.SECURITY_PRINCIPAL, config.getRootDN());
env.put(Context.SECURITY_CREDENTIALS, config.getPassword());
- // TODO move it in configuration ?
+
env.put("com.sun.jndi.ldap.connect.timeout", "60000");
+ if (config.getMinConnection() > 0)
+ {
+ System.setProperty("com.sun.jndi.ldap.connect.pool.initsize", Integer.toString(config.getMinConnection()));
+ System.setProperty("com.sun.jndi.ldap.connect.pool.prefsize", Integer.toString(config.getMinConnection()));
+ }
+
+ if (config.getMaxConnection() > 0)
+ {
+ System.setProperty("com.sun.jndi.ldap.connect.pool.maxsize", Integer.toString(config.getMaxConnection()));
+ }
+
env.put("com.sun.jndi.ldap.connect.pool", "true");
env.put("java.naming.ldap.version", config.getVerion());
env.put("java.naming.ldap.attributes.binary", "tokenGroups");
@@ -239,13 +250,19 @@
SearchControls constraints = new SearchControls();
constraints.setSearchScope(SearchControls.ONELEVEL_SCOPE);
NamingEnumeration<SearchResult> results = ctx.search(name, "(objectclass=*)", constraints);
- while (results.hasMore())
+ try
{
- SearchResult sr = results.next();
- unbind(ctx, sr.getNameInNamespace());
+ while (results.hasMore())
+ {
+ SearchResult sr = results.next();
+ unbind(ctx, sr.getNameInNamespace());
+ }
+ // close search results enumeration
}
- // close search results enumeration
- results.close();
+ finally
+ {
+ results.close();
+ }
ctx.unbind(name);
}
Modified: core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java
===================================================================
--- core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java 2011-11-23 12:32:33 UTC (rev 5233)
+++ core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java 2011-11-23 12:37:54 UTC (rev 5234)
@@ -123,24 +123,24 @@
@Override
protected void saveUserPassword(User user, String userDN) throws Exception
{
- Object v = ldapService.getLdapContext().getEnvironment().get(Context.SECURITY_PROTOCOL);
- if (v == null)
- return;
- String security = String.valueOf(v);
- if (!security.equalsIgnoreCase("ssl"))
- return;
- String newQuotedPassword = "\"" + user.getPassword() + "\"";
- byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
- ModificationItem[] mods = new ModificationItem[2];
- mods[0] =
- new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute(ldapAttrMapping.userPassword,
- newUnicodePassword));
- mods[1] =
- new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute("userAccountControl", Integer
- .toString(UF_NORMAL_ACCOUNT + UF_PASSWORD_EXPIRED)));
LdapContext ctx = ldapService.getLdapContext();
try
{
+ Object v = ctx.getEnvironment().get(Context.SECURITY_PROTOCOL);
+ if (v == null)
+ return;
+ String security = String.valueOf(v);
+ if (!security.equalsIgnoreCase("ssl"))
+ return;
+ String newQuotedPassword = "\"" + user.getPassword() + "\"";
+ byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
+ ModificationItem[] mods = new ModificationItem[2];
+ mods[0] =
+ new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute(ldapAttrMapping.userPassword,
+ newUnicodePassword));
+ mods[1] =
+ new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute("userAccountControl",
+ Integer.toString(UF_NORMAL_ACCOUNT + UF_PASSWORD_EXPIRED)));
for (int err = 0;; err++)
{
try
Modified: core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/MembershipDAOImpl.java
===================================================================
--- core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/MembershipDAOImpl.java 2011-11-23 12:32:33 UTC (rev 5233)
+++ core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/MembershipDAOImpl.java 2011-11-23 12:37:54 UTC (rev 5234)
@@ -401,15 +401,23 @@
+ ldapAttrMapping.membershipTypeMemberValue + "=" + userDN + "))";
NamingEnumeration<SearchResult> results = findMembershipsInGroup(ctx, groupId, filter);
- if (results.hasMoreElements())
+ try
{
- // SearchResult sr = results.next();
- // if (haveUser(sr.getAttributes(), userDN)) {
- // membership = createMembershipObject(userName, groupId, type);
- // }
- membership = createMembershipObject(userName, groupId, type);
+ if (results.hasMoreElements())
+ {
+ // SearchResult sr = results.next();
+ // if (haveUser(sr.getAttributes(), userDN)) {
+ // membership = createMembershipObject(userName, groupId, type);
+ // }
+ membership = createMembershipObject(userName, groupId, type);
+ }
}
+ finally
+ {
+ results.close();
+ }
+
if (membership != null)
{
cacheHandler.put(cacheHandler.getMembershipKey(membership), membership, CacheType.MEMBERSHIP);
Modified: core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/OrganizationLdapInitializer.java
===================================================================
--- core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/OrganizationLdapInitializer.java 2011-11-23 12:32:33 UTC (rev 5233)
+++ core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/OrganizationLdapInitializer.java 2011-11-23 12:37:54 UTC (rev 5234)
@@ -27,7 +27,10 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import javax.naming.NamingEnumeration;
import javax.naming.directory.BasicAttributes;
+import javax.naming.directory.SearchControls;
+import javax.naming.directory.SearchResult;
import javax.naming.ldap.LdapContext;
/**
@@ -67,36 +70,57 @@
Matcher matcher = pattern.matcher(dn);
dn = matcher.replaceAll("=");
LdapContext context = baseHandler.ldapService.getLdapContext();
- String[] explodeDN = baseHandler.explodeDN(dn, false);
- if (explodeDN.length < 1)
- return;
- dn = explodeDN[explodeDN.length - 1];
- int i = explodeDN.length - 2;
- for (; i > -1; i--)
+ try
{
- if (!explodeDN[i].toLowerCase().startsWith("dc="))
- break;
- dn = explodeDN[i] + "," + dn;
+ String[] explodeDN = baseHandler.explodeDN(dn, false);
+ if (explodeDN.length < 1)
+ return;
+ dn = explodeDN[explodeDN.length - 1];
+ int i = explodeDN.length - 2;
+ for (; i > -1; i--)
+ {
+ if (!explodeDN[i].toLowerCase().startsWith("dc="))
+ break;
+ dn = explodeDN[i] + "," + dn;
+ }
+ createDN(dn, context);
+ for (; i > -1; i--)
+ {
+ dn = explodeDN[i] + "," + dn;
+ createDN(dn, context);
+ }
}
- createDN(dn, context);
- for (; i > -1; i--)
+ finally
{
- dn = explodeDN[i] + "," + dn;
- createDN(dn, context);
+ baseHandler.ldapService.release(context);
}
}
private void createDN(String dn, LdapContext context) throws Exception
{
+ NamingEnumeration<SearchResult> results = null;
try
{
- Object obj = context.lookupLink(dn);
- if (obj != null)
+ SearchControls control = new SearchControls();
+ control.setSearchScope(SearchControls.OBJECT_SCOPE);
+ results = context.search(dn, "(objectClass=*)", control);
+
+ if (results.hasMoreElements())
+ {
return;
+ }
}
catch (Exception exp)
{
}
+ finally
+ {
+ if (results != null)
+ {
+ results.close();
+ }
+ }
+
String nameValue = dn.substring(dn.indexOf("=") + 1, dn.indexOf(","));
BasicAttributes attrs = new BasicAttributes();
if (dn.toLowerCase().startsWith("ou="))
@@ -139,33 +163,40 @@
LdapContext context = baseHandler.ldapService.getLdapContext();
- String[] edn = baseHandler.explodeDN(dn, false);
- String[] ebasedn = baseHandler.explodeDN(basedn, false);
+ try
+ {
+ String[] edn = baseHandler.explodeDN(dn, false);
+ String[] ebasedn = baseHandler.explodeDN(basedn, false);
- if (edn.length < 1)
- throw new IllegalArgumentException("Zerro DN length, [" + dn + "]");
- if (ebasedn.length < 1)
- throw new IllegalArgumentException("Zerro Base DN length, [" + basedn + "]");
- if (edn.length < ebasedn.length)
- throw new IllegalArgumentException("DN length smaller Base DN [" + dn + " >= " + basedn + "]");
+ if (edn.length < 1)
+ throw new IllegalArgumentException("Zerro DN length, [" + dn + "]");
+ if (ebasedn.length < 1)
+ throw new IllegalArgumentException("Zerro Base DN length, [" + basedn + "]");
+ if (edn.length < ebasedn.length)
+ throw new IllegalArgumentException("DN length smaller Base DN [" + dn + " >= " + basedn + "]");
- String rdn = basedn;
- for (int i = 1; i <= edn.length; i++)
- {
- // for (int i=edn.length - 1; i>=0; i--) {
- String n = edn[edn.length - i];
- if (i <= ebasedn.length)
+ String rdn = basedn;
+ for (int i = 1; i <= edn.length; i++)
{
- String bn = ebasedn[ebasedn.length - i];
- if (!n.equals(bn))
- throw new IllegalArgumentException("DN does not starts with Base DN [" + dn + " != " + basedn + "]");
+ // for (int i=edn.length - 1; i>=0; i--) {
+ String n = edn[edn.length - i];
+ if (i <= ebasedn.length)
+ {
+ String bn = ebasedn[ebasedn.length - i];
+ if (!n.equals(bn))
+ throw new IllegalArgumentException("DN does not starts with Base DN [" + dn + " != " + basedn + "]");
+ }
+ else
+ {
+ // create RDN elem
+ rdn = n + "," + rdn;
+ createDN(rdn, context);
+ }
}
- else
- {
- // create RDN elem
- rdn = n + "," + rdn;
- createDN(rdn, context);
- }
}
+ finally
+ {
+ baseHandler.ldapService.release(context);
+ }
}
}
Added: core/branches/2.3.x/patch/2.3.11-GA/COR-237/readme.txt
===================================================================
--- core/branches/2.3.x/patch/2.3.11-GA/COR-237/readme.txt (rev 0)
+++ core/branches/2.3.x/patch/2.3.11-GA/COR-237/readme.txt 2011-11-23 12:37:54 UTC (rev 5234)
@@ -0,0 +1,70 @@
+Summary
+
+ * Status: minConnection and maxConnection params in the ldap configuration are not used
+ * CCP Issue: CCP-1032, Product Jira Issue: COR-237.
+ * Complexity: Low
+
+The Proposal
+Problem description
+
+What is the problem to fix?
+
+ * minConnection and maxConnection params in the ldap configuration are not used
+
+Fix description
+
+How is the problem fixed?
+Use minConnection and maxConnection to set up com.sun.jndi.ldap.connect.pool.initsize and com.sun.jndi.ldap.connect.pool.prefsize, precisely:
+
+ * com.sun.jndi.ldap.connect.pool.initsize and com.sun.jndi.ldap.connect.pool.prefsize are set to minConnection if minConnection > 0
+ * com.sun.jndi.ldap.connect.pool.maxsize are set to maxConnection if maxConnection > 0
+
+Patch file: COR-237.patch
+
+Tests to perform
+
+Reproduction test
+
+ * org.exoplatform.services.ldap.impl.LDAPServiceImpl does not use minConnection and maxConnection params to init the ldap connection pool (should be used for com.sun.jndi.ldap.connect.pool.initsize and com.sun.jndi.ldap.connect.pool.maxsize env params).
+
+Tests performed at DevLevel
+ * Manual testing PLF 3.0.5 with configured LDAPOrganizationService
+
+Tests performed at QA/Support Level
+*
+
+Documentation changes
+
+Documentation changes:
+ * No
+
+Configuration changes
+
+Configuration changes:
+ * No
+
+Will previous configuration continue to work?
+ * Yes
+
+Risks and impacts
+
+Can this bug fix have any side effects on current client projects?
+
+ * No
+
+Is there a performance risk/cost?
+ * No
+
+Validation (PM/Support/QA)
+
+PM Comment
+
+ * Patch approved.
+
+Support Comment
+
+ * Patch validated by QA on behalf of Support.
+
+QA Feedbacks
+* Patch validated
+
12 years, 5 months
exo-jcr SVN: r5233 - in kernel/branches/2.2.x: patch/2.2.11-GA/KER-180 and 1 other directory.
by do-not-reply@jboss.org
Author: trang_vu
Date: 2011-11-23 07:32:33 -0500 (Wed, 23 Nov 2011)
New Revision: 5233
Added:
kernel/branches/2.2.x/patch/2.2.11-GA/KER-180/readme.txt
Modified:
kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/PropertyConfigurator.java
kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/StandaloneContainer.java
Log:
KER-180: Propose a maven profile for each supported configuration
Fix description
* Add new method PropertyConfigurator to work with the StandaloneContainer.
If the system property PropertyManager.PROPERTIES_URL has been set properly, it will load the properties from the file and load them as system properties.
Modified: kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/PropertyConfigurator.java
===================================================================
--- kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/PropertyConfigurator.java 2011-11-23 10:03:55 UTC (rev 5232)
+++ kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/PropertyConfigurator.java 2011-11-23 12:32:33 UTC (rev 5233)
@@ -62,32 +62,38 @@
/** The logger. */
private final Log log = ExoLogger.getExoLogger(PropertyConfigurator.class);
+ public PropertyConfigurator(ConfigurationManager confManager)
+ {
+ this(null, confManager);
+ }
+
public PropertyConfigurator(InitParams params, ConfigurationManager confManager)
{
- PropertiesParam propertiesParam = params.getPropertiesParam("properties");
- if (propertiesParam != null)
+ String path = null;
+ if (params != null)
{
- log.debug("Going to initialize properties from init param");
- for (Iterator<Property> i = propertiesParam.getPropertyIterator();i.hasNext();)
+ PropertiesParam propertiesParam = params.getPropertiesParam("properties");
+ if (propertiesParam != null)
{
- Property property = i.next();
- String name = property.getName();
- String value = property.getValue();
- log.debug("Adding property from init param " + name + " = " + value);
- PropertyManager.setProperty(name, value);
+ log.debug("Going to initialize properties from init param");
+ for (Iterator<Property> i = propertiesParam.getPropertyIterator();i.hasNext();)
+ {
+ Property property = i.next();
+ String name = property.getName();
+ String value = property.getValue();
+ log.debug("Adding property from init param " + name + " = " + value);
+ PropertyManager.setProperty(name, value);
+ }
+ }
+ ValueParam pathParam = params.getValueParam("properties.url");
+ if (pathParam != null)
+ {
+ log.debug("Using file path " + path + " found from configuration");
+ path = pathParam.getValue();
}
}
//
- String path = null;
- ValueParam pathParam = params.getValueParam("properties.url");
- if (pathParam != null)
- {
- log.debug("Using file path " + path + " found from configuration");
- path = pathParam.getValue();
- }
-
- //
String systemPath = PropertyManager.getProperty(PropertyManager.PROPERTIES_URL);
if (systemPath != null)
{
Modified: kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/StandaloneContainer.java
===================================================================
--- kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/StandaloneContainer.java 2011-11-23 10:03:55 UTC (rev 5232)
+++ kernel/branches/2.2.x/exo.kernel.container/src/main/java/org/exoplatform/container/StandaloneContainer.java 2011-11-23 12:32:33 UTC (rev 5233)
@@ -82,6 +82,10 @@
configurationManager = new ConfigurationManagerImpl(configClassLoader, ExoContainer.getProfiles());
this.registerComponentInstance(ConfigurationManager.class, configurationManager);
registerComponentImplementation(SessionManagerImpl.class);
+ // Workaround used to allow to use the PropertyConfigurator with the StandaloneContainer
+ // If the system property PropertyManager.PROPERTIES_URL has been set properly, it will load the properties
+ // from the file and load them as system properties
+ new PropertyConfigurator(configurationManager);
}
/**
Added: kernel/branches/2.2.x/patch/2.2.11-GA/KER-180/readme.txt
===================================================================
--- kernel/branches/2.2.x/patch/2.2.11-GA/KER-180/readme.txt (rev 0)
+++ kernel/branches/2.2.x/patch/2.2.11-GA/KER-180/readme.txt 2011-11-23 12:32:33 UTC (rev 5233)
@@ -0,0 +1,67 @@
+Summary
+
+ * Status: Propose a maven profile for each supported configuration
+ * CCP Issue: N/A, Product Jira Issue: KER-180.
+ * Complexity: Low
+
+The Proposal
+Problem description
+
+What is the problem to fix?
+Changes for the kernel from issue JCR-1689.
+
+See base issue https://jira.exoplatform.org/browse/JCR-1689
+
+Fix description
+
+How is the problem fixed?
+ * Add new method PropertyConfigurator to work with the StandaloneContainer.
+ If the system property PropertyManager.PROPERTIES_URL has been set properly, it will load the properties from the file and load them as system properties.
+
+Patch file: KER-180.patch
+
+Tests to perform
+
+Reproduction test
+ * No
+
+Tests performed at DevLevel
+ * No
+
+Tests performed at QA/Support Level
+*
+
+Documentation changes
+
+Documentation changes:
+ * No
+
+Configuration changes
+
+Configuration changes:
+
+ * No
+
+Will previous configuration continue to work?
+
+* Yes
+
+Risks and impacts
+
+Can this bug fix have any side effects on current client projects?
+
+ * No
+
+Is there a performance risk/cost?
+ * No
+
+Validation (PM/Support/QA)
+
+PM Comment
+*PM validated
+
+Support Comment
+*Validated by PM, on behalf of Support
+
+QA Feedbacks
+*
12 years, 5 months
exo-jcr SVN: r5232 - jcr/trunk/exo.jcr.component.core/src/test/resources.
by do-not-reply@jboss.org
Author: dkuleshov
Date: 2011-11-23 05:03:55 -0500 (Wed, 23 Nov 2011)
New Revision: 5232
Modified:
jcr/trunk/exo.jcr.component.core/src/test/resources/tsm-excludes.properties
Log:
EXOJCR-1534: added a few exclusions for TestSecurityManager
Modified: jcr/trunk/exo.jcr.component.core/src/test/resources/tsm-excludes.properties
===================================================================
--- jcr/trunk/exo.jcr.component.core/src/test/resources/tsm-excludes.properties 2011-11-22 14:04:27 UTC (rev 5231)
+++ jcr/trunk/exo.jcr.component.core/src/test/resources/tsm-excludes.properties 2011-11-23 10:03:55 UTC (rev 5232)
@@ -28,4 +28,13 @@
org.exoplatform.services.jcr.impl.storage.value.fs.TestFileValueIO.testWriteFileValueData=testWriteValue,testReadValue
org.exoplatform.services.jcr.impl.storage.value.fs.TestRemoveFromValueStorage.testRemoveValue=read,getFile
org.exoplatform.services.jcr.impl.TestRepositoryCheckController.testIndexUsecaseMultipleDocuments=onSaveItems
-org.exoplatform.services.jcr.impl.TestRepositoryCheckController.testIndexUsecaseDocumentNotExists=onSaveItems
\ No newline at end of file
+org.exoplatform.services.jcr.impl.TestRepositoryCheckController.testIndexUsecaseDocumentNotExists=onSaveItems
+org.exoplatform.services.jcr.cluster.functional.WebdavRemoveNodeTest.testRemoveNode=addNode,getStatusCode
+org.exoplatform.services.jcr.cluster.functional.WebdavAddBLOBTest.testAddBLOB=getStatusCode,close
+org.exoplatform.services.jcr.cluster.functional.WebdavAddNodeTest.testAddNode=addNode
+org.exoplatform.services.jcr.cluster.functional.WebdavLockNodeTest.testLock=addDir
+org.exoplatform.services.jcr.cluster.functional.WebdavMoveNodeTest.testMoveNode=addNode
+org.exoplatform.services.jcr.cluster.functional.WebdavQueryTest.testFullTextSearch=addNode
+org.exoplatform.services.jcr.cluster.functional.WebdavQueryTest.testPathSearch=addDir
+org.exoplatform.services.jcr.cluster.functional.WebdavQueryTest.testPropertyValueSearch=addNode
+org.exoplatform.services.jcr.cluster.functional.WebdavVersionTest.testVersioning=addNode
12 years, 5 months
exo-jcr SVN: r5231 - core/trunk/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl.
by do-not-reply@jboss.org
Author: tolusha
Date: 2011-11-22 09:04:27 -0500 (Tue, 22 Nov 2011)
New Revision: 5231
Modified:
core/trunk/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java
Log:
EXOJCR-1645: Support of DefaultSchema parameter for HiberbateService
Modified: core/trunk/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java
===================================================================
--- core/trunk/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
+++ core/trunk/exo.core.component.database/src/main/java/org/exoplatform/services/database/impl/HibernateServiceImpl.java 2011-11-22 14:04:27 UTC (rev 5231)
@@ -108,6 +108,10 @@
// "org.hibernate.dialect"
log_.info("Using dialect " + dialect);
}
+ else if (name.equals("hibernate.default_schema") && (value == null || value.isEmpty()))
+ {
+ continue;
+ }
//
conf_.setProperty(name, value);
12 years, 5 months
exo-jcr SVN: r5230 - in core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization: impl and 1 other directory.
by do-not-reply@jboss.org
Author: dkuleshov
Date: 2011-11-22 05:37:35 -0500 (Tue, 22 Nov 2011)
New Revision: 5230
Added:
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/ExtendedCloneable.java
Modified:
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/CacheHandler.java
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/GroupImpl.java
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipImpl.java
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipTypeImpl.java
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserImpl.java
core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserProfileImpl.java
Log:
EXOJCR-1545: fixed ugly cloning
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/CacheHandler.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/CacheHandler.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/CacheHandler.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -125,17 +125,9 @@
obj = userProfileCache.get(key);
}
- if (obj != null && obj instanceof Cloneable)
+ if (obj instanceof ExtendedCloneable)
{
- try
- {
- // need to return the clone of the object since object is mutable
- return obj.getClass().getMethod("clone").invoke(obj);
- }
- catch (Exception e)
- {
- return obj;
- }
+ return ((ExtendedCloneable)obj).clone();
}
return obj;
}
Added: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/ExtendedCloneable.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/ExtendedCloneable.java (rev 0)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/ExtendedCloneable.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2009 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.exoplatform.services.organization;
+
+/**
+ * Used to allow to use clone method without involvement of reflection.
+ *
+ * Created by The eXo Platform SAS.
+ *
+ * Date: 21.11.2011
+ *
+ * @author <a href="mailto:dmitry.kuleshov@exoplatform.com">Dmitry Kuleshov</a>
+ * @version $Id:
+ */
+public interface ExtendedCloneable extends Cloneable
+{
+ public Object clone();
+
+}
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/GroupImpl.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/GroupImpl.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/GroupImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -25,12 +25,13 @@
*/
package org.exoplatform.services.organization.impl;
+import org.exoplatform.services.organization.ExtendedCloneable;
import org.exoplatform.services.organization.Group;
/**
* @hibernate.class table="EXO_GROUP"
*/
-public class GroupImpl implements Group, Cloneable
+public class GroupImpl implements Group, ExtendedCloneable
{
private String id;
@@ -148,16 +149,15 @@
/**
* {@inheritDoc}
**/
- public Object clone()
+ public GroupImpl clone()
{
- GroupImpl gi = new GroupImpl();
-
- gi.setId(this.id);
- gi.setParentId(this.parentId);
- gi.setGroupName(this.groupName);
- gi.setLabel(this.label);
- gi.setDescription(this.desc);
-
- return gi;
+ try
+ {
+ return (GroupImpl)super.clone();
+ }
+ catch (CloneNotSupportedException e)
+ {
+ return this;
+ }
}
}
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipImpl.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipImpl.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -18,12 +18,13 @@
*/
package org.exoplatform.services.organization.impl;
+import org.exoplatform.services.organization.ExtendedCloneable;
import org.exoplatform.services.organization.Membership;
/**
* @hibernate.class table="EXO_MEMBERSHIP"
*/
-public class MembershipImpl implements Membership, Cloneable
+public class MembershipImpl implements Membership, ExtendedCloneable
{
private String id = null;
@@ -101,15 +102,15 @@
/**
* {@inheritDoc}
**/
- public Object clone()
+ public MembershipImpl clone()
{
- MembershipImpl mi = new MembershipImpl();
-
- mi.setGroupId(this.groupId);
- mi.setMembershipType(this.membershipType);
- mi.setId(this.id);
- mi.setUserName(this.userName);
-
- return mi;
+ try
+ {
+ return (MembershipImpl)super.clone();
+ }
+ catch (CloneNotSupportedException e)
+ {
+ return this;
+ }
}
}
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipTypeImpl.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipTypeImpl.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipTypeImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.organization.impl;
+import org.exoplatform.services.organization.ExtendedCloneable;
import org.exoplatform.services.organization.MembershipType;
import java.util.Date;
@@ -28,7 +29,7 @@
*
* @hibernate.class table="EXO_MEMBERSHIP_TYPE"
*/
-public class MembershipTypeImpl implements MembershipType, Cloneable
+public class MembershipTypeImpl implements MembershipType, ExtendedCloneable
{
private String name;
@@ -120,14 +121,25 @@
/**
* {@inheritDoc}
**/
- public Object clone()
+ public MembershipTypeImpl clone()
{
- MembershipTypeImpl mti = new MembershipTypeImpl();
- mti.setName(this.name);
- mti.setDescription(this.description);
- mti.setOwner(this.owner);
- mti.setCreatedDate((Date)this.createdDate.clone());
- mti.setModifiedDate((Date)this.modifiedDate.clone());
+ MembershipTypeImpl mti;
+ try
+ {
+ mti = (MembershipTypeImpl)super.clone();
+ if (createdDate != null)
+ {
+ mti.createdDate = (Date)createdDate.clone();
+ }
+ if (modifiedDate != null)
+ {
+ mti.modifiedDate = (Date)modifiedDate.clone();
+ }
+ }
+ catch (CloneNotSupportedException e)
+ {
+ return this;
+ }
return mti;
}
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserImpl.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserImpl.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.organization.impl;
+import org.exoplatform.services.organization.ExtendedCloneable;
import org.exoplatform.services.organization.User;
import java.util.Date;
@@ -25,7 +26,7 @@
/**
* @hibernate.class table="EXO_USER"
*/
-public class UserImpl implements User, Cloneable
+public class UserImpl implements User, ExtendedCloneable
{
private String id = null;
@@ -189,20 +190,26 @@
/**
* {@inheritDoc}
**/
- public Object clone()
+ public UserImpl clone()
{
- UserImpl ui = new UserImpl();
+ UserImpl ui;
+ try
+ {
+ ui = (UserImpl)super.clone();
+ if (createdDate != null)
+ {
+ ui.createdDate = (Date)createdDate.clone();
+ }
+ if (lastLoginTime != null)
+ {
+ ui.lastLoginTime = (Date)lastLoginTime.clone();
+ }
+ }
+ catch (CloneNotSupportedException e)
+ {
+ return this;
+ }
- ui.setId(this.id);
- ui.setUserName(this.userName);
- ui.setPassword(this.password);
- ui.setFirstName(this.firstName);
- ui.setLastName(this.lastName);
- ui.setEmail(this.email);
- ui.setCreatedDate((Date)this.createdDate.clone());
- ui.setLastLoginTime((Date)this.lastLoginTime.clone());
- ui.setOrganizationId(this.organizationId);
-
return ui;
}
}
Modified: core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserProfileImpl.java
===================================================================
--- core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserProfileImpl.java 2011-11-21 15:03:07 UTC (rev 5229)
+++ core/trunk/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/UserProfileImpl.java 2011-11-22 10:37:35 UTC (rev 5230)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.organization.impl;
+import org.exoplatform.services.organization.ExtendedCloneable;
import org.exoplatform.services.organization.UserProfile;
import java.util.HashMap;
@@ -27,7 +28,7 @@
* Created by The eXo Platform SAS Author : Mestrallet Benjamin
* benjmestrallet(a)users.sourceforge.net Date: Aug 21, 2003 Time: 3:22:54 PM
*/
-public class UserProfileImpl implements UserProfile, Cloneable
+public class UserProfileImpl implements UserProfile, ExtendedCloneable
{
private String userName;
@@ -90,8 +91,19 @@
/**
* {@inheritDoc}
**/
- public Object clone()
+ public UserProfileImpl clone()
{
- return new UserProfileImpl(this.userName, new HashMap<String, String>(this.attributes));
+ UserProfileImpl upi;
+ try
+ {
+ upi = (UserProfileImpl)super.clone();
+ upi.attributes = new HashMap<String, String>(attributes);
+ }
+ catch (CloneNotSupportedException e)
+ {
+ return this;
+ }
+
+ return upi;
}
}
12 years, 5 months