This seems like a simple operation but we clearly don't understand something!

We want to copy a tree of items from one place /adt:dataRepository/adt:ABRA_data to another

        try {
            Workspace workspace = session.getWorkspace();
workspace.copy(RepositoryStructureNames.DATAREPOSITORY+"/" + internalSourceDataStoreName, RepositoryStructureNames.DATAREPOSITORY+"/" + internalNewDataStoreName);
        } catch

As you can see we can find the node just before we copy it but the getNodeState complains that it can not find it.

Any hints as to what we can do to make this work or is there a better way to copy a tree of items to another place.

We think that adt is a namespace. At least we tried to set that up and the property related debug messages replace "adt:" with the "http://....";




2013-01-09 10:12:41,012 [main] INFO com.artifact_software.adt.plugin.transformation.CreateNewDataStoreFromExisting - Transformation plugin Create Internal Person DataStore attempting to create new DataStore PersonInternal from ABRA_data 2013-01-09 10:12:41,012 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performing node.getNode(adt:dataRepository) 2013-01-09 10:12:41,012 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performed node.getNode(adt:dataRepository) in 74739us 2013-01-09 10:12:41,012 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performing node.getNode(adt:ABRA_data) 2013-01-09 10:12:41,012 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performed node.getNode(adt:ABRA_data) in 68144us 2013-01-09 10:12:41,013 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performing item.getPath() 2013-01-09 10:12:41,013 [main] DEBUG org.apache.jackrabbit.core.session.SessionState - Performed item.getPath() in 42499us 2013-01-09 10:12:41,013 [main] DEBUG com.artifact_software.adt.model.jcr.DataRepositoryImpl - *****path to node /adt:dataRepository/adt:ABRA_data* 2013-01-09 10:12:41,013 [main] DEBUG com.artifact_software.adt.model.jcr.DataRepositoryImpl - soure data store exists=true
javax.jcr.PathNotFoundException: /adt:dataRepository/adt:ABRA_data
at org.apache.jackrabbit.core.BatchedItemOperations.getNodeState(BatchedItemOperations.java:1448) at org.apache.jackrabbit.core.BatchedItemOperations.copy(BatchedItemOperations.java:378) at org.apache.jackrabbit.core.WorkspaceImpl.internalCopy(WorkspaceImpl.java:430) at org.apache.jackrabbit.core.WorkspaceImpl.copy(WorkspaceImpl.java:656) at com.artifact_software.adt.model.jcr.DataRepositoryImpl.cloneDataStore(DataRepositoryImpl.java:156)

--
Ron Wheeler
President
Artifact Software Inc
email: [email protected]
skype: ronaldmwheeler
phone: 866-970-2435, ext 102

Reply via email to