<?xml version="1.0"?>
<component name="org.collectionspace.${ServiceName}.${TenantLabel}.coreTypes">
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="${CustomSchemaName}" prefix="${CustomSchemaName}" src="schemas/${CustomSchemaName}.xsd"/>
+ <extension target="org.nuxeo.ecm.core.schema.TypeService"
+ point="schema">
+ <schema name="${CustomSchemaName}" prefix="${CustomSchemaName}"
+ src="schemas/${CustomSchemaName}.xsd" />
</extension>
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
- <doctype name="${NuxeoDocTypeName}${TenantPrefix}${TenantId}" extends="${NuxeoDocTypeName}">
- <schema name="common"/>
- <schema name="dublincore"/>
- <schema name="collectionspace_core"/>
- <schema name="${CommonSchemaName}"/>
- <schema name="${CustomSchemaName}"/>
+ <extension target="org.nuxeo.ecm.core.schema.TypeService"
+ point="doctype">
+ <doctype name="${NuxeoDocTypeName}${TenantPrefix}${TenantId}"
+ extends="${NuxeoDocTypeName}">
+ <schema name="common" />
+ <schema name="dublincore" />
+ <schema name="collectionspace_core" />
+ <schema name="${CommonSchemaName}" />
+ <schema name="${CustomSchemaName}" />
</doctype>
</extension>
- </component>
+</component>
<?xml version="1.0"?>
<component name="org.collectionspace.${ServiceName}.coreTypes">
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="${CommonSchemaName}" prefix="${CommonSchemaName}" src="schemas/${CommonSchemaName}.xsd"/>
- </extension>
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
- <doctype name="${NuxeoDocTypeName}" extends="CollectionSpaceDocument">
- <schema name="common"/>
- <schema name="dublincore"/>
- <schema name="collectionspace_core"/>
- <schema name="${CommonSchemaName}"/>
- </doctype>
- </extension>
+ <extension target="org.nuxeo.ecm.core.schema.TypeService"
+ point="schema">
+ <schema name="${CommonSchemaName}" prefix="${CommonSchemaName}"
+ src="schemas/${CommonSchemaName}.xsd" />
+ </extension>
+ <extension target="org.nuxeo.ecm.core.schema.TypeService"
+ point="doctype">
+ <doctype name="${NuxeoDocTypeName}" extends="CollectionSpaceDocument">
+ <schema name="common" />
+ <schema name="dublincore" />
+ <schema name="collectionspace_core" />
+ <schema name="${CommonSchemaName}" />
+ </doctype>
+ </extension>
</component>
File below this line have been ported. -->\r
<!-- ============================================= -->\r
\r
+<!-- \r
<run controlFile="./security.xml" testGroup="deleteBug" />\r
<run controlFile="objectexit/object-exit.xml" testGroup="makeone" />\r
<run controlFile="objectexit/object-exit.xml" testGroup="checkList" />\r
<run controlFile="acquisitions/acquisitions.xml" testGroup="makeone" />\r
<run controlFile="acquisitions/acquisitions.xml" testGroup="testList" />\r
<run controlFile="relation/relation.xml" testGroup="makeRelations" />\r
+ --> \r
\r
<!-- No - this test is broken\r
<run controlFile="relation/relation.xml" testGroup="r2only" />\r
-->\r
\r
+<!-- \r
<run controlFile="person/person.xml" testGroup="postPerson" />\r
<run controlFile="person/person.xml" testGroup="updatePerson" />\r
<run controlFile="person/person.xml" testGroup="PersonAddRelsDeleteRels" />\r
<run controlFile="vocabulary/vocabulary.xml" testGroup="TestOrder" />\r
<run controlFile="authrefs/authrefsSimple.xml" testGroup="AuthRefsSimple" />\r
<run controlFile="authrefs/authrefsComplex.xml" testGroup="AuthRefsComplex" />\r
+ --> \r
<run controlFile="imports/imports.xml" testGroup="importsTestGroup" />\r
\r
</xmlReplayMaster>\r
</parent>
<modelVersion>4.0.0</modelVersion>
- <groupId>org.collectionspace.services</groupId>
<artifactId>org.collectionspace.services.collectionobject.3rdparty.lifesci.nuxeo</artifactId>
<packaging>jar</packaging>
<description>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
- <manifestFile>target/classes/META-INF/MANIFEST.MF </manifestFile>
+ <manifestFile>target/classes/META-INF/MANIFEST.MF</manifestFile>
<manifestEntries>
<Bundle-Version>${eclipseVersion}</Bundle-Version>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
</parent>\r
\r
<modelVersion>4.0.0</modelVersion>\r
- <groupId>org.collectionspace.services</groupId>\r
<artifactId>org.collectionspace.services.collectionobject.3rdparty</artifactId>\r
<name>services.collectionobject.3rdparty</name>\r
<packaging>pom</packaging>\r
</parent>\r
\r
<modelVersion>4.0.0</modelVersion>\r
- <groupId>org.collectionspace.services</groupId>\r
<artifactId>org.collectionspace.services.collectionobject</artifactId>\r
<name>services.collectionobject</name>\r
<packaging>pom</packaging>\r
<build>
<resources>
- <resource>
- <directory>src/main/resources</directory>
- <filtering>true</filtering>
- </resource>
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ <resource>
+ <directory>../../../../3rdparty/nuxeo/nuxeo-doctype/src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
- <manifestFile> src/main/resources/META-INF/MANIFEST.MF </manifestFile>
+ <manifestFile>target/classes/META-INF/MANIFEST.MF</manifestFile>
<manifestEntries>
<Bundle-Version>${eclipseVersion}</Bundle-Version>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
+++ /dev/null
-Manifest-Version: 1.0 \r
-Bundle-ManifestVersion: 1 \r
-Bundle-Name: NuxeoCS\r
-Bundle-SymbolicName: org.collectionspace.group;singleton:=true \r
-Bundle-Version: 1.0.0\r
-Bundle-Localization: plugin\r
-Bundle-Vendor: Nuxeo \r
-Require-Bundle: org.nuxeo.runtime, \r
- org.nuxeo.ecm.core.api, \r
- org.nuxeo.ecm.core,\r
- org.nuxeo.ecm.core.api,\r
- org.nuxeo.ecm.platform.types.api,\r
- org.nuxeo.ecm.platform.versioning.api,\r
- org.nuxeo.ecm.platform.ui,\r
- org.nuxeo.ecm.platform.forms.layout.client,\r
- org.nuxeo.ecm.platform.ws,\r
- org.collectionspace.collectionspace_core\r
-Provide-Package: org.collectionspace.group\r
-Nuxeo-Component: OSGI-INF/core-types-contrib.xml,\r
- OSGI-INF/life-cycle-contrib.xml,\r
- OSGI-INF/ecm-types-contrib.xml,\r
- OSGI-INF/layouts-contrib.xml\r
-\r
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.group.coreTypes">
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="groups_common" prefix="groups_common" src="schemas/groups_common.xsd"/>
- </extension>
-
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
- <doctype name="Group" extends="Document">
- <schema name="common"/>
- <schema name="dublincore"/>
- <schema name="collectionspace_core"/>
- <schema name="groups_common"/>
- </doctype>
- </extension>
-</component>
+++ /dev/null
-<?xml version="1.0"?>
-<fragment>
-
- <extension target="application#MODULE">
- <module>
- <java>${bundle.fileName}</java>
- </module>
- </extension>
-
-</fragment>
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.group.ecm.types">
- <extension target="org.nuxeo.ecm.platform.types.TypeService" point="types">
- <type id="Group" coretype="Group">
- <label>org.collectionspace.group</label>
- <!--icon>/icons/file.gif</icon-->
- <default-view>view_documents</default-view>
-
- <layouts mode="any">
- <layout>heading</layout>
- <layout>collectionspace_core</layout>
- <layout>group</layout>
- </layouts>
- </type>
-
- <type id="Folder" coretype="Folder">
- <subtypes>
- <type>Group</type>
- </subtypes>
- </type>
-
- <type id="Workspace" coretype="Workspace">
- <subtypes>
- <type>Group</type>
- </subtypes>
- </type>
-
- </extension>
-</component>
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.ecm.platform.group.LifeCycleManagerExtensions">
-
- <extension target="org.nuxeo.ecm.core.lifecycle.LifeCycleService"
- point="types">
- <types>
- <type name="Group">${Lifecycle}</type>
- </types>
- </extension>
-
-</component>
</parent>
<modelVersion>4.0.0</modelVersion>
- <groupId>org.collectionspace.services</groupId>
<artifactId>org.collectionspace.services.group.3rdparty</artifactId>
<name>services.group.3rdparty</name>
<packaging>pom</packaging>
3rd party build for group service
</description>
+ <properties>
+ <ServiceName>group</ServiceName>
+ <NuxeoDocTypeName>Group</NuxeoDocTypeName>
+ <CommonSchemaName>groups_common</CommonSchemaName>
+ <TenantPrefix>Tenant</TenantPrefix>
+ <Lifecycle>cs_default</Lifecycle>
+ </properties>
+
<modules>
<module>nuxeo-platform-cs-group</module>
</modules>
}\r
\r
String importTree(RepositoryInstance repoSession, File file, String toPath) throws Exception {\r
+ Exception failed = null;\r
DocumentReader reader = null;\r
DocumentWriter writer = null;\r
DocumentModel docModel = null;\r
pipe.setReader(reader);\r
pipe.setWriter(writer);\r
DocumentTranslationMap dtm = pipe.run();\r
- Map<DocumentRef,DocumentRef> documentRefs = dtm.getDocRefMap();\r
+ Map<DocumentRef,DocumentRef> documentRefs = dtm.getDocRefMap(); // FIXME: Should be checking for null here!\r
dump.append("<importedRecords>");\r
for (Map.Entry entry: documentRefs.entrySet()) {\r
keyDocRef = (DocumentRef) entry.getKey();\r
}\r
dump.append("</importedRecords>");\r
} catch (Exception e) {\r
- throw e;\r
+ failed = e;\r
+ throw failed;\r
} finally {\r
+ String status = failed == null ? "Success" : "Failed";\r
+ dump.append("<status>" + status + "</status>");\r
dump.append("<totalRecordsImported>"+totalRecordsImported+"</totalRecordsImported>");\r
dump.append("<numRecordsImportedByDocType>");\r
TreeSet<String> keys = new TreeSet<String>(recordsImportedForDocType.keySet());\r
if (writer != null) {\r
writer.close();\r
}\r
+ \r
+ if (failed != null) {\r
+ String msg = "The Import service encountered an exception: " + failed.getLocalizedMessage();\r
+ logger.error(msg, failed);\r
+ System.err.println(msg);\r
+ }\r
}\r
return dump.toString();\r
}\r
</parent>
<modelVersion>4.0.0</modelVersion>
- <groupId>org.collectionspace.services</groupId>
<artifactId>org.collectionspace.services.objectexit.3rdparty.nuxeo</artifactId>
<name>services.objectexit.3rdparty.nuxeo</name>
<packaging>jar</packaging>
<build>
<resources>
+<!--
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
+-->
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ <resource>
+ <directory>../../../../3rdparty/nuxeo/nuxeo-doctype/src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
- <manifestFile> src/main/resources/META-INF/MANIFEST.MF </manifestFile>
+ <manifestFile>target/classes/META-INF/MANIFEST.MF</manifestFile>
<manifestEntries>
<Bundle-Version>${eclipseVersion}</Bundle-Version>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
+++ /dev/null
-Manifest-Version: 1.0 \r
-Bundle-ManifestVersion: 1 \r
-Bundle-Name: NuxeoCS\r
-Bundle-SymbolicName: org.collectionspace.objectexit;singleton:=true \r
-Bundle-Version: 1.0.0\r
-Bundle-Localization: plugin\r
-Bundle-Vendor: Nuxeo \r
-Require-Bundle: org.nuxeo.runtime, \r
- org.nuxeo.ecm.core.api, \r
- org.nuxeo.ecm.core,\r
- org.nuxeo.ecm.core.api,\r
- org.nuxeo.ecm.platform.types.api,\r
- org.nuxeo.ecm.platform.versioning.api,\r
- org.nuxeo.ecm.platform.ui,\r
- org.nuxeo.ecm.platform.forms.layout.client,\r
- org.nuxeo.ecm.platform.ws,\r
- org.collectionspace.collectionspace_core\r
-Provide-Package: org.collectionspace.objectexit\r
-Nuxeo-Component: OSGI-INF/core-types-contrib.xml,\r
- OSGI-INF/life-cycle-contrib.xml,\r
- OSGI-INF/ecm-types-contrib.xml,\r
- OSGI-INF/layouts-contrib.xml\r
-\r
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.objectexit.coreTypes">
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="objectexit_common" prefix="objectexit_common" src="schemas/objectexit_common.xsd"/>
- </extension>
-
- <extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
- <doctype name="ObjectExit" extends="Document">
- <schema name="common"/>
- <schema name="dublincore"/>
- <schema name="collectionspace_core"/>
- <schema name="objectexit_common"/>
- </doctype>
- </extension>
-</component>
+++ /dev/null
-<?xml version="1.0"?>
-<fragment>
-
- <extension target="application#MODULE">
- <module>
- <java>${bundle.fileName}</java>
- </module>
- </extension>
-
-</fragment>
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.objectexit.ecm.types">
- <extension target="org.nuxeo.ecm.platform.types.TypeService" point="types">
- <type id="ObjectExit" coretype="ObjectExit">
- <label>org.collectionspace.objectexit</label>
- <!--icon>/icons/file.gif</icon-->
- <default-view>view_documents</default-view>
-
- <layouts mode="any">
- <layout>heading</layout>
- <layout>collectionspace_core</layout>
- <layout>objectexit</layout>
- </layouts>
- </type>
-
- <type id="Folder" coretype="Folder">
- <subtypes>
- <type>ObjectExit</type>
- </subtypes>
- </type>
-
- <type id="Workspace" coretype="Workspace">
- <subtypes>
- <type>ObjectExit</type>
- </subtypes>
- </type>
-
- </extension>
-</component>
+++ /dev/null
-<?xml version="1.0"?>
-<component name="org.collectionspace.ecm.platform.objectexit.LifeCycleManagerExtensions">
-
- <extension target="org.nuxeo.ecm.core.lifecycle.LifeCycleService"
- point="types">
- <types>
- <type name="ObjectExit">${Lifecycle}</type>
- </types>
- </extension>
-
-</component>
</parent>
<modelVersion>4.0.0</modelVersion>
- <groupId>org.collectionspace.services</groupId>
<artifactId>org.collectionspace.services.objectexit.3rdparty</artifactId>
<name>services.objectexit.3rdparty</name>
<packaging>pom</packaging>
3rd party build for objectexit service
</description>
+ <properties>
+ <ServiceName>objectexit</ServiceName>
+ <NuxeoDocTypeName>ObjectExit</NuxeoDocTypeName>
+ <CommonSchemaName>objectexit_common</CommonSchemaName>
+ <TenantPrefix>Tenant</TenantPrefix>
+ <Lifecycle>cs_default</Lifecycle>
+ </properties>
+
<modules>
<module>nuxeo-platform-cs-objectexit</module>
</modules>