Overview

CMIS Import feature downloads files from CMIS server and process them as batches in Ephesoft Application. Using CMIS import user can monitor the CMIS server using a cron job which checks the specified folder for a new file after the specified interval of time. Along with the document, its properties are also downloaded in an xml format. Users can write their own custom scripts to access these properties in the batch being executed.

Batch is created for every file downloaded file from the CMIS server and execute it on the Ephesoft Application.

FORMAT FOR DOWNLOADED XML (containing document properties)

<CmisImport>

<Properties>

<Property>

<Name>Description</Name>

<Value/>

</Property>

<Property>

<Name>Title</Name>

<Value>BI1E_documentDOC2.pdf</Value>

</Property>

</Properties>

</CmisImport>

CMIS Import feature downloads the file having valid file extension and having cmis property configured in the Property column which have the value mention in the Value column. After downloading the file from CMIS server our application updates that property value using new value configured in the New Value property.

Let’s take the example which will help us in understanding the property. CMIS server contains 15 documents but 10 of them are valid as per our confgured file extension. The property is configured as “cm:author” and value is configured as “Ephesoft”, then only that document out of 10 documents which satisfy the cmis property “cm:author” and its value “Ephesoft” will be downloaded by the application and that document cmis property “cm:author” will be updated to New Value configured.

Configuration

User can specify the CMIS server configuration in the batch class.

cmis1

Configurable property Type of value Value options Description
Server URL String NA URL for making connection to CMIS servere.g. http://localhost:8090/alfresco/cmisatom
Username String NA User name for authentication to the specified CMIS server.
Password String NA Password for authentication to the specified CMIS server.
Repository ID String NA CMIS server repository ID.
File Extension String Read only Supported file extensions which will get downloaded. In version 3.0, application supports only PDF and tiff files.
Folder String NA Folder name on the CMIS server from where files need to be downloaded.
Property String NA This property is used to specify the cmis property which should be used to download file from CMIS server URL. Valid documents containing this property with the specified value mentioned below will be marked for selection.e.g. cmis:name, cm:description, cm:title, cm:author
Value String NA This property contains the value for the property mentioned above. This key value pair decides which document will get downloaded.
New Value String NA This specifed the new value to be updated after downloading file from the cmis server of the specified cmis property. This is to ensure that same document doesn’t get downloaded again.

Cron job expression

For cron job scheduler: Please update the following property file {Application}\WEB-INF\classes\META-INF\dcma-cmis-import\cmis-import.properties for cron job.

cmisImport.cronxpression=0 0/15 * ? * *

Default value for this property is set to every 15 mins by default.

Disabling/Enabling CMIS import functionality

For enabling/disabling CMIS import functionality please uncomment/comment the following line at {Application}\applicationContext.xml

<import resource=”classpath:/META-INF/applicationContext-dcma-cmis-import.xml” />

Default: CMIS import is disabled.

Screenshots for Configuration

Screenshot for CMIS folder:

cmis2

Screenshot for CMIS document:

cmis3

Screenshot for CMIS properties:

cmis4

Screenshot for CMIS repository information:

cmis5

URL for fetching repository information in alfresco:

http://{server}:{port}/alfresco/service/cmis/index.html

Troubleshooting

S no. Error message Possible root cause
1 Unable to connect to the server Invalid configuration being used for making connection to the cmis server.
2 Error while generating cmis properties xml
  • Either {Ephesoft Application} is not access to write the properties on the disk.
  • Either network path is unable to connect while writing the file.




Was this article helpful to you?

J.D. Abbey

Comments are closed.