- initial version of the Alfresco BFSI Output Connector (CONNECTORS-1442)
- updated to the latest version OpenCMIS (1.1.0)


git-svn-id: https://svn.apache.org/repos/asf/manifoldcf/branches/CONNECTORS-1442@1808904 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/CHANGES.txt b/CHANGES.txt
index 69b57c2..a1f1b8b 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -3,6 +3,9 @@
 
 ======================= 2.9-dev =====================
 
+CONNECTORS-1442: Added the new Alfresco BFSI Output Connector 
+(Luis Cabaceira)
+
 CONNECTORS-1456: Tentative fix for API issue exporting jobs in JSON
 format.  Basically, simple valued array elements did not work.
 (Adrian Conlon, Karl Wright)
diff --git a/build.xml b/build.xml
index 0685037..340c4bc 100644
--- a/build.xml
+++ b/build.xml
@@ -66,7 +66,7 @@
     <property name="jaxb-api.version" value="2.1"/>
     <property name="jaxb-impl.version" value="2.1.11"/>
     <property name="jaxws.version" value="2.2.6"/>
-    <property name="chemistry.version" value="0.11.0"/>
+    <property name="chemistry.version" value="1.1.0"/>
     <property name="glassfish.version" value="2.1.v20091210"/>
     <property name="junit.version" value="4.12"/>
     <property name="selenium.version" value="3.3.1"/>
@@ -763,6 +763,8 @@
           <exclude name="alfresco/lib-proprietary/*.jar"/>
           <exclude name="alfresco-webscript/test-materials-proprietary/*.war"/>
           <exclude name="alfresco-webscript/connector/src/test/resources/*.json"/>
+        	<exclude name="alfresco-bfsi/test-materials-proprietary/*.war"/>
+        	<exclude name="alfresco-bfsi/connector/src/test/resources/*.json"/>
           <exclude name="**/build/"/>
           <exclude name="**/dist/"/>
           <exclude name="**/test-output/"/>
@@ -944,6 +946,17 @@
             <param name="artifact-type" value="amp"/>
         </antcall>
     </target>
+	
+	<target name="download-alfresco-bfsi-plugin">
+      <mkdir dir="lib/alfresco-bfsi"/>
+      <antcall target="download-via-maven">
+          <param name="target" value="lib/alfresco-bfsi"/>
+          <param name="project-path" value="com/github/maoo/indexer"/>
+          <param name="artifact-version" value="${alfresco-indexer.version}"/>
+          <param name="artifact-name" value="alfresco-indexer-webscripts"/>
+          <param name="artifact-type" value="amp"/>
+      </antcall>
+  </target>
     
     <target name="download-gson">
         <mkdir dir="lib"/>
@@ -2700,7 +2713,7 @@
         </antcall>
     </target>
 
-    <target name="make-core-deps" depends="download-less-compiler,download-forbidden-checks,download-nuxeo-client,download-json-simple,download-selenium,download-kafka-client,download-joda-time,download-aws-sdk,download-resteasy,download-jsoup,download-mockito,download-alfresco-webscript-plugin,download-alfresco-indexer-client,download-mongo-java-driver,download-jira-client,download-google-api-client,download-dropbox-client,download-solrj,download-zookeeper,download-httpcomponents,download-hsqldb,download-xerces,download-commons,download-elasticsearch-plugin,download-solr-plugins,download-sharepoint-plugins,download-jstl,download-xmlgraphics-commons,download-woodstox,download-xmlsec,download-xml-apis,download-wss4j,download-velocity,download-streambuffer,download-stax,download-servlet-api,download-xml-resolver,download-osgi,download-opensaml,download-mimepull,download-mail,download-log4j,download-junit,download-jaxws,download-glassfish,download-jaxb,download-tomcat,download-h2,download-h2-support,download-geronimo-specs,download-fop,download-postgresql,download-axis,download-saaj,download-wsdl4j,download-castor,download-jetty,download-slf4j,download-xalan,download-activation,download-avalon-framework,download-poi,download-chemistry,download-ecj,download-hadoop,download-htrace,download-protobuf,download-tika,download-jackson">
+    <target name="make-core-deps" depends="download-less-compiler,download-forbidden-checks,download-nuxeo-client,download-json-simple,download-selenium,download-kafka-client,download-joda-time,download-aws-sdk,download-resteasy,download-jsoup,download-mockito,download-alfresco-webscript-plugin,download-alfresco-bfsi-plugin,download-alfresco-indexer-client,download-mongo-java-driver,download-jira-client,download-google-api-client,download-dropbox-client,download-solrj,download-zookeeper,download-httpcomponents,download-hsqldb,download-xerces,download-commons,download-elasticsearch-plugin,download-solr-plugins,download-sharepoint-plugins,download-jstl,download-xmlgraphics-commons,download-woodstox,download-xmlsec,download-xml-apis,download-wss4j,download-velocity,download-streambuffer,download-stax,download-servlet-api,download-xml-resolver,download-osgi,download-opensaml,download-mimepull,download-mail,download-log4j,download-junit,download-jaxws,download-glassfish,download-jaxb,download-tomcat,download-h2,download-h2-support,download-geronimo-specs,download-fop,download-postgresql,download-axis,download-saaj,download-wsdl4j,download-castor,download-jetty,download-slf4j,download-xalan,download-activation,download-avalon-framework,download-poi,download-chemistry,download-ecj,download-hadoop,download-htrace,download-protobuf,download-tika,download-jackson">
         <copy todir="lib">
             <fileset dir="lib-license" includes="*.txt"/>
         </copy>
diff --git a/connectors/alfresco-bfsi/build.xml b/connectors/alfresco-bfsi/build.xml
new file mode 100644
index 0000000..c87c941
--- /dev/null
+++ b/connectors/alfresco-bfsi/build.xml
@@ -0,0 +1,154 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<project name="alfresco-bfsi" default="all">
+
+    <property environment="env"/>
+    <condition property="mcf-dist" value="${env.MCFDISTPATH}">
+        <isset property="env.MCFDISTPATH"/>
+    </condition>
+    <property name="abs-dist" location="../../dist"/>
+    <condition property="mcf-dist" value="${abs-dist}">
+        <not>
+            <isset property="env.MCFDISTPATH"/>
+        </not>
+    </condition>
+
+    <import file="${mcf-dist}/connector-build.xml"/>
+
+    <property name="alfresco-indexer.version" value="0.8.1"/>
+
+    <path id="connector-classpath">
+        <path refid="mcf-connector-build.connector-classpath"/>
+        <fileset dir="../../lib">
+            <include name="alfresco-indexer-client*.jar"/>
+        	  <include name="chemistry*.jar"/>
+            <include name="stax*.jar"/>
+            <include name="streambuffer*.jar"/>
+            <include name="jaxb*.jar"/>
+            <include name="jaxws*.jar"/>
+            <include name="wstx-asl*.jar"/>
+            <include name="mimepull*.jar"/>
+            <include name="resolver*.jar"/>
+            <include name="org.osgi.core*.jar"/>
+            <include name="commons-lang*.jar"/>
+            <include name="joda*.jar"/>
+        </fileset>
+    	
+    </path>
+
+    <path id="connector-test-classpath">
+        <path refid="mcf-connector-build.connector-test-classpath"/>
+        <fileset dir="../../lib">
+            <include name="chemistry*.jar"/>
+            <include name="stax*.jar"/>
+            <include name="streambuffer*.jar"/>
+            <include name="jaxb*.jar"/>
+            <include name="jaxws*.jar"/>
+            <include name="wstx-asl*.jar"/>
+            <include name="mimepull*.jar"/>
+            <include name="resolver*.jar"/>
+            <include name="org.osgi.core*.jar"/>
+            <include name="commons-lang*.jar"/>
+        </fileset>
+    </path>
+
+    <target name="lib" depends="mcf-connector-build.lib,precompile-check" if="canBuild">
+        <mkdir dir="dist/lib"/>
+        <copy todir="dist/lib">
+            <fileset dir="../../lib">
+                <include name="alfresco-indexer-client*.jar"/>
+            </fileset>
+        </copy>
+    </target>
+
+    <target name="download-via-alfresco-indexer">
+        <get src="https://repo1.maven.org/maven2/${project-path}/${artifact-name}/${artifact-version}/${artifact-name}-${artifact-version}.${artifact-type}" dest="${target}/${artifact-name}-${artifact-version}.${artifact-type}"/>
+    </target>
+
+    <target name="download-dependencies">
+        <property name="alfresco-package" value="com/github/maoo/indexer"/>
+        <antcall target="download-via-maven">
+            <param name="project-path" value="${alfresco-package}"/>
+            <param name="artifact-version" value="${alfresco-indexer.version}"/>
+            <param name="target" value="test-materials-proprietary"/>
+            <param name="artifact-name" value="alfresco-indexer-webscripts-war"/>
+            <param name="artifact-type" value="war"/>
+        </antcall>
+    </target>
+
+    <target name="integration">
+        <mkdir dir="dist/integration/alfresco-bfsi"/>
+        <copy todir="dist/integration/alfresco-bfsi">
+          <fileset dir="../../lib/alfresco-bfsi"/>
+        </copy>
+    </target>
+
+    <target name="download-cleanup">
+        <delete>
+            <fileset dir="test-materials-proprietary" excludes="README*.txt"/>
+        </delete>
+    </target>
+
+    <target name="calculate-testcode-condition">
+        <available file="test-materials-proprietary/alfresco-indexer-webscripts-war-${alfresco-indexer.version}.war" property="alfrescoTestcodeStatus"/>
+        <condition property="tests-present">
+            <isset property="alfrescoTestcodeStatus"/>
+        </condition>
+    </target>
+
+    <target name="pretest-warn" depends="calculate-testcode-condition" unless="tests-present">
+        <echo message="Alfresco Connector integration tests cannot be be performed without alfresco.war"/>
+    </target>
+
+    <target name="deliver-connector" depends="mcf-connector-build.deliver-connector">
+        <antcall target="general-add-output-connector">
+            <param name="connector-label" value="Alfresco BFSI"/>
+            <param name="connector-class" value="org.apache.manifoldcf.agents.output.bfsioutput.AlfrescoBfsiOutputConnector"/>
+        </antcall>
+    </target>
+
+    <target name="run-IT-HSQLDB" depends="compile-tests,pretest-check" if="canTest">
+        <mkdir dir="test-HSQLDB-output"/>
+        <junit fork="true" maxmemory="1024m" dir="test-HSQLDB-output" outputtoformatters="true" showoutput="true" haltonfailure="true">
+            <jvmarg value="-DcrawlerWarPath=${mcf-dist}/web/war/mcf-crawler-ui.war"/>
+            <jvmarg value="-DauthorityserviceWarPath=${mcf-dist}/web/war/mcf-authority-service.war"/>
+            <jvmarg value="-DapiWarPath=${mcf-dist}/web/war/mcf-api-service.war"/>
+            <jvmarg value="-DcombinedWarPath=${mcf-dist}/web/war/mcf-combined-service.war"/>
+            <jvmarg value="-DalfrescoServerWarPath=../test-materials-proprietary/alfresco-indexer-webscripts-war-${alfresco-indexer.version}.war"/>
+            <jvmarg value="-Xms512m"/>
+            <jvmarg value="-Xmx1024m"/>
+            <jvmarg value="-Xss1024k"/>
+            <jvmarg value="-XX:MaxPermSize=256m"/>
+            <jvmarg value="-XX:NewSize=256m"/>
+            <classpath>
+                <fileset dir="${env.JAVA_HOME}/lib">
+                    <include name="tools.jar"/>
+                </fileset>
+                <path refid="connector-test-classpath"/>
+                <pathelement location="build/connector-tests/classes"/>
+            </classpath>
+            <formatter type="brief" usefile="false"/>
+            <batchtest todir="test-HSQLDB-output">
+                <fileset dir="build/connector-tests/classes">
+                    <include name="**/*HSQLDBIT.class"/>
+                </fileset>
+            </batchtest>
+        </junit>
+    </target>
+
+</project>
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputAgent.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputAgent.java
new file mode 100644
index 0000000..068effa
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputAgent.java
@@ -0,0 +1,188 @@
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+
+import org.apache.commons.io.IOUtils;
+
+import java.io.*;
+import java.nio.file.Path;
+import java.nio.file.StandardCopyOption;
+import java.text.DateFormat;
+import java.text.SimpleDateFormat;
+import java.util.Calendar;
+import java.util.Properties;
+
+public class AlfrescoBfsiOutputAgent {
+
+    private static Properties properties1 = new Properties();
+
+    /**
+     * No-arguments constructor.
+     */
+    public AlfrescoBfsiOutputAgent() {
+    }
+
+    /**
+     * Get traditional properties in name=value format.
+     *
+     * @param filePathAndName Path and name of properties file (without the
+     *                        .properties extension).
+     * @return Properties read in from provided file.
+     */
+    public Properties loadTraditionalProperties(final String filePathAndName) {
+        final Properties properties = new Properties();
+        try {
+            final FileInputStream in = new FileInputStream(filePathAndName);
+            properties.load(in);
+            in.close();
+        } catch (FileNotFoundException fnfEx) {
+            System.err.println("Could not read properties from file " + filePathAndName);
+        } catch (IOException ioEx) {
+            System.err.println(
+                    "IOException encountered while reading from " + filePathAndName);
+        }
+        return properties;
+    }
+
+
+    /**
+     * Get traditional properties in name=value format.
+     *
+     * @param fileName name of the file target for meta-data manifest creation
+     * @return String execution log
+
+    public static String createBulkManifest(final String fileName, Properties properties, Path files_deployment_location) {
+        DateFormat dateFormat = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
+        Calendar cal = Calendar.getInstance();
+        String date = dateFormat.format(cal.getTime());
+        FileOutputStream outStream = null;
+        String metaDatafileName = fileName + ".metadata.properties.xml";
+        String metaDatafilePath = files_deployment_location.toString() + "/" + metaDatafileName;
+        try {
+            outStream = new FileOutputStream(metaDatafilePath);
+        } catch (FileNotFoundException e) {
+            e.printStackTrace();
+        }
+        if (!(properties == null)) { // If the method was invoqued with properties object use it
+            createMetaDataXmlFile(properties, outStream);
+        } else { // else write default properties
+            properties1.setProperty("type", "cm:content");
+            properties1.setProperty("aspects", "cm:versionable,cm:dublincore");
+            properties1.setProperty("cm:title", "Crawled document from ManifoldCF Input Connectors : " + date);
+            properties1.setProperty("cm:description", "");
+            properties1.setProperty("cm:author", "Apache ManifoldCF BulkFilesystem Output Connector");
+            properties1.setProperty("cm:publisher", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:contributor", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:type", "default_plus_dubincore_aspect");
+            properties1.setProperty("cm:identifier", fileName);
+            properties1.setProperty("cm:source", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:coverage", "General");
+            properties1.setProperty("cm:rights", "");
+            properties1.setProperty("cm:subject", "Metadata file created with Apache ManifoldCF BulkFilesystem Output Connector");
+            createMetaDataXmlFile(properties1, outStream);
+        }
+        return "Created Manifest for " + fileName + ": " + files_deployment_location.toString() + "/" + metaDatafileName;
+    }*/
+
+
+
+    /**
+     * Get traditional properties in name=value format.
+     *
+     * @param fileName name of the file target for meta-data manifest creation
+     * @return String execution log
+     */
+    public static String createBulkDocument(final InputStream fileIS, final String fileName, Properties properties, Path files_deployment_location) {
+
+
+
+        File targetFile = new File(files_deployment_location.toString() + "/" + fileName);
+
+        try {
+            java.nio.file.Files.copy(
+                    fileIS,
+                    targetFile.toPath(),
+                    StandardCopyOption.REPLACE_EXISTING);
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+        IOUtils.closeQuietly(fileIS);
+
+        DateFormat dateFormat = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
+        Calendar cal = Calendar.getInstance();
+        String date = dateFormat.format(cal.getTime());
+        FileOutputStream outStream = null;
+        String metaDatafileName = fileName + ".metadata.properties.xml";
+        String metaDatafilePath = files_deployment_location.toString() + "/" + metaDatafileName;
+        try {
+            outStream = new FileOutputStream(metaDatafilePath);
+        } catch (FileNotFoundException e) {
+            e.printStackTrace();
+        }
+        if (!(properties == null)) { // If the method was invoqued with properties object use it
+            createMetaDataXmlFile(properties, outStream);
+        } else { // else write default properties
+            properties1.setProperty("type", "cm:content");
+            properties1.setProperty("aspects", "cm:versionable,cm:dublincore");
+            properties1.setProperty("cm:title", "Crawled document from ManifoldCF Input Connectors : " + date);
+            properties1.setProperty("cm:description", "");
+            properties1.setProperty("cm:author", "Apache ManifoldCF BulkFilesystem Output Connector");
+            properties1.setProperty("cm:publisher", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:contributor", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:type", "default_plus_dubincore_aspect");
+            properties1.setProperty("cm:identifier", fileName);
+            properties1.setProperty("cm:source", "BulkFilesystem Output Connector");
+            properties1.setProperty("cm:coverage", "General");
+            properties1.setProperty("cm:rights", "");
+            properties1.setProperty("cm:subject", "Metadata file created with Apache ManifoldCF BulkFilesystem Output Connector");
+            createMetaDataXmlFile(properties1, outStream);
+        }
+        return "Created Manifest for " + fileName + ": " + files_deployment_location.toString() + "/" + metaDatafileName;
+    }
+
+
+
+    public static void createMetaDataXmlFile(final Properties sourceProperties, final OutputStream out) {
+
+        try {
+            sourceProperties.storeToXML(out, "To use with Alfresco in-place-bulk importer");
+        } catch (IOException ioEx) {
+            System.err.println("ERROR trying to store properties in XML!");
+        }
+    }
+
+    /**
+     * Store provided properties in XML format.
+     *
+     * @param sourceProperties Properties to be stored in XML format.
+     * @param out              OutputStream to which to write XML formatted properties.
+     */
+    public void storeXmlProperties(final Properties sourceProperties, final OutputStream out) {
+        try {
+            sourceProperties.storeToXML(out, "This is easy!");
+        } catch (IOException ioEx) {
+            System.err.println("ERROR trying to store properties in XML!");
+        }
+    }
+
+    /**
+     * Store provided properties in XML format to provided file.
+     *
+     * @param sourceProperties Properties to be stored in XML format.
+     * @param pathAndFileName  Path and name of file to which XML-formatted
+     *                         properties will be written.
+     */
+    public void storeXmlPropertiesToFile(
+            final Properties sourceProperties,
+            final String pathAndFileName) {
+        try {
+            FileOutputStream fos = new FileOutputStream(pathAndFileName);
+            storeXmlProperties(sourceProperties, fos);
+            fos.close();
+        } catch (FileNotFoundException fnfEx) {
+            System.err.println("ERROR writing to " + pathAndFileName);
+        } catch (IOException ioEx) {
+            System.err.println(
+                    "ERROR trying to write XML properties to file " + pathAndFileName);
+        }
+    }
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConfig.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConfig.java
new file mode 100644
index 0000000..4afa16c
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConfig.java
@@ -0,0 +1,65 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+import org.apache.commons.lang.StringUtils;
+
+/**
+ * Parameters data for the Alfresco Bulk File System output connector.
+*/
+public class AlfrescoBfsiOutputConfig {
+  
+  /** DropFolder */
+  public static final String DROPFOLDER_PARAM = "dropfolder";
+
+  /** Create Timestamp Tree **/
+  public static final String CREATE_TIMESTAMP_TREE_PARAM = "createTimestampTree";
+
+  /** Username */
+  public static final String USERNAME_PARAM = "username";
+  /** Password */
+  public static final String PASSWORD_PARAM = "password";
+  /** Protocol */
+  public static final String PROTOCOL_PARAM = "protocol";
+  /** Server name */
+  public static final String SERVER_PARAM = "server";
+  /** Port */
+  public static final String PORT_PARAM = "port";
+
+  /** Remote Path in the context of remote drop (streaming) */
+  public static final String PATH_PARAM = "path";
+
+
+  public static final String CREATE_TIMESTAMP_TREE_DEFAULT_VALUE = Boolean.FALSE.toString();
+
+
+  //default values
+  public static final String USERNAME_DEFAULT_VALUE = "admin";
+  public static final String PASSWORD_DEFAULT_VALUE = "admin";
+  public static final String PROTOCOL_DEFAULT_VALUE = "http";
+  public static final String SERVER_DEFAULT_VALUE = "localhost";
+  public static final String PORT_DEFAULT_VALUE = "8080";
+  public static final String PATH_DEFAULT_VALUE = "/user/tests";
+  //default values
+  public static final String DROPFOLDER_DEFAULT_VALUE = "/opt/alfresco/alf_data/contentstore/manifoldexport";
+
+
+
+
+
+
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnector.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnector.java
new file mode 100644
index 0000000..6009456
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnector.java
@@ -0,0 +1,914 @@
+/* $Id$ */
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+
+import java.io.IOException;
+import java.io.InterruptedIOException;
+import java.nio.file.Files;
+import java.nio.file.Path;
+import java.nio.file.Paths;
+import java.rmi.NotBoundException;
+import java.rmi.RemoteException;
+import java.text.DateFormat;
+import java.text.SimpleDateFormat;
+import java.util.Calendar;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import java.util.Properties;
+
+import org.apache.chemistry.opencmis.client.api.ObjectId;
+import org.apache.chemistry.opencmis.client.runtime.ObjectIdImpl;
+import org.apache.chemistry.opencmis.commons.PropertyIds;
+import org.apache.commons.lang.StringUtils;
+import org.apache.manifoldcf.agents.interfaces.IOutputAddActivity;
+import org.apache.manifoldcf.agents.interfaces.IOutputRemoveActivity;
+import org.apache.manifoldcf.agents.interfaces.RepositoryDocument;
+import org.apache.manifoldcf.agents.interfaces.ServiceInterruption;
+import org.apache.manifoldcf.agents.output.BaseOutputConnector;
+import org.apache.manifoldcf.core.interfaces.ConfigParams;
+import org.apache.manifoldcf.core.interfaces.IHTTPOutput;
+import org.apache.manifoldcf.core.interfaces.IPasswordMapperActivity;
+import org.apache.manifoldcf.core.interfaces.IPostParameters;
+import org.apache.manifoldcf.core.interfaces.IThreadContext;
+import org.apache.manifoldcf.core.interfaces.ManifoldCFException;
+import org.apache.manifoldcf.core.interfaces.VersionContext;
+import org.apache.manifoldcf.crawler.system.Logging;
+
+
+/**
+ * This is the "output connector" for a Alfresco Bulk File System Import format repository.
+ *
+ * @author Luis Cabaceira
+ */
+public class AlfrescoBfsiOutputConnector extends BaseOutputConnector {
+
+    protected final static String ACTIVITY_READ = "read document";
+    protected static final String RELATIONSHIP_CHILD = "child";
+    /*
+    * CMIS SPECIFIC PROPERITES
+    * */
+    private static final String CMIS_PROPERTY_PREFIX = "cmis:";
+    private static final String CMIS_DOCUMENT_TYPE = "cmis:document";
+    /*
+    * END CMIS PROPERITES
+    * */
+    /** Document accepted */
+    private final static int DOCUMENT_STATUS_ACCEPTED = 0;
+    private static final String DOCUMENT_STATUS_ACCEPTED_DESC = "Injection OK - ";
+    private static final String DOCUMENT_STATUS_REJECTED_DESC = "Injection KO - ";
+    /** Document permanently rejected */
+    private final static int DOCUMENT_STATUS_REJECTED = 1;
+    /** Document remove accepted */
+    private final static String DOCUMENT_DELETION_STATUS_ACCEPTED = "Remove request accepted";
+    /** Document remove permanently rejected */
+    private final static String DOCUMENT_DELETION_STATUS_REJECTED = "Remove request rejected";
+    /** The standard Path property for ManifoldCF used for migrate contents **/
+    private static final String CONTENT_MIGRATION_PATH_PROPERTY = "manifoldcf:path";
+
+    // Tab name properties
+    private static final String TARGET_DROP_FOLDER_TAB_PROPERTY = "AlfrescoBfsiOutputConnector.BfsiParametersTab";
+    // Template names
+    /**
+     * Forward to the javascript to check the configuration parameters
+     */
+    private static final String EDIT_CONFIG_HEADER_FORWARD = "editConfiguration.js";
+    /**
+     * Server tab template
+     */
+    private static final String EDIT_CONFIG_FORWARD_SERVER = "editConfiguration_Server.html";
+    /**
+     * Forward to the HTML template to view the configuration parameters
+     */
+    private static final String VIEW_CONFIG_FORWARD = "viewConfiguration.html";
+    /**
+     * Save activity
+     */
+    protected final static String ACTIVITY_INJECTION = "Injection";
+    /**
+     * Delete activity
+     */
+    protected final static String ACTIVITY_DELETE = "Delete";
+    /**
+     * Target path handle
+     */
+    Path DropFolderPath = null;
+
+    /**
+     * Constructor
+     */
+    public AlfrescoBfsiOutputConnector() {
+        super();
+    }
+
+    /**
+     * Return the list of activities that this connector supports (i.e. writes
+     * into the log).
+     *
+     * @return the list.
+     */
+    @Override
+    public String[] getActivitiesList() {
+        return new String[]{ACTIVITY_INJECTION, ACTIVITY_DELETE};
+    }
+
+
+    protected class CheckConnectionThread extends Thread {
+        protected Throwable exception = null;
+
+        public CheckConnectionThread() {
+            super();
+            setDaemon(true);
+        }
+
+        public void run() {
+            try {
+                if (DropFolderPath.getFileSystem().equals(null))     Logging.connectors.error(" Error checking path Object: ");
+            } catch (Throwable e) {
+                Logging.connectors.warn(" Error checking path Object: " + e.getMessage(), e);
+                this.exception = e;
+            }
+        }
+
+        public Throwable getException() {
+            return exception;
+        }
+
+    }
+
+
+
+    /**
+     * Target filesystem folder for the drop zone
+     */
+    protected String dropFolder = null;
+
+    /**
+     * Credentials (for remote mode)
+     * */
+    protected String username = null;
+    protected String password = null;
+    /** Endpoint protocol */
+    protected String protocol = null;
+    /** Endpoint server name */
+    protected String server = null;
+    /** Endpoint port */
+    protected String port = null;
+    /** Endpoint context path of the Alfresco webapp */
+    protected String path = null;
+    /**
+     * Flag for creating the new tree structure using timestamp
+     **/
+    protected String createTimestampTree = Boolean.FALSE.toString();
+    protected Map<String, String> parameters = new HashMap<String, String>();
+    protected static final long timeToRelease = 300000L;
+    protected long lastSessionFetch = -1L;
+
+    /*
+    * DropFolderPath is a java.nio Path object that represents the target for the output package
+    * The thread model enables parallel output executions
+    * */
+    protected class GetDropFolderPath extends Thread {
+        protected Throwable exception = null;
+
+        public GetDropFolderPath() {
+            super();
+            setDaemon(true);
+        }
+
+        public void run() {
+            try {
+                // Create the path object
+                DropFolderPath = Paths.get(path); // Solaris/Linux syntax
+            } catch (Throwable e) {
+                this.exception = e;
+            }
+        }
+
+        public Throwable getException() {
+            return exception;
+        }
+    }
+
+    protected class DestroyDropFolderPath extends Thread {
+        protected Throwable exception = null;
+
+        public DestroyDropFolderPath() {
+            super();
+            setDaemon(true);
+        }
+
+        public void run() {
+            try {
+                DropFolderPath = null;
+            } catch (Throwable e) {
+                this.exception = e;
+            }
+        }
+
+        public Throwable getException() {
+            return exception;
+        }
+
+    }
+
+
+    /**
+     * Close the connection. Call this before discarding the connection.
+     */
+    @Override
+    public void disconnect() throws ManifoldCFException {
+        if (DropFolderPath != null) {
+            DestroyDropFolderPath t = new DestroyDropFolderPath();
+            try {
+                t.start();
+                t.join();
+                Throwable thr = t.getException();
+                if (thr != null) {
+                    if (thr instanceof RemoteException)
+                        throw (RemoteException) thr;
+                    else
+                        throw (Error) thr;
+                }
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+            } catch (InterruptedException e) {
+                t.interrupt();
+                throw new ManifoldCFException("Interrupted: " + e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+            } catch (RemoteException e) {
+                Throwable e2 = e.getCause();
+                if (e2 instanceof InterruptedException || e2 instanceof InterruptedIOException)
+                    throw new ManifoldCFException(e2.getMessage(), e2, ManifoldCFException.INTERRUPTED);
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+                // Treat this as a transient problem
+                Logging.connectors.warn("Remote exception closing path object: " + e.getMessage(), e);
+            }
+
+        }
+
+        username = null;
+        password = null;
+        protocol = null;
+        server = null;
+        port = null;
+        path = null;
+        createTimestampTree = Boolean.FALSE.toString();
+    }
+
+
+    /**
+     * This method create a new "session" for a DropFolder path object
+     * This can represent  S3, local filesystem or ftp
+     * @param  configParameters
+     *          is the set of configuration parameters, which in this case
+     *          describe the target appliance, basic auth configuration, etc.
+     *          (This formerly came out of the ini file.)
+     */
+    @Override
+    public void connect(ConfigParams configParams) {
+        super.connect(configParams);
+        username = params.getParameter(AlfrescoBfsiOutputConfig.USERNAME_PARAM);
+        password = params.getParameter(AlfrescoBfsiOutputConfig.PASSWORD_PARAM);
+        protocol = params.getParameter(AlfrescoBfsiOutputConfig.PROTOCOL_PARAM);
+        server = params.getParameter(AlfrescoBfsiOutputConfig.SERVER_PARAM);
+        port = params.getParameter(AlfrescoBfsiOutputConfig.PORT_PARAM);
+        path = params.getParameter(AlfrescoBfsiOutputConfig.PATH_PARAM);
+        createTimestampTree = params.getParameter(AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_PARAM);
+        //Logging.connectors.info("Connected");
+    }
+
+    /**
+     * Test the connection. Returns a string describing the connection integrity.
+     *
+     * @return the connection's status as a displayable string.
+     */
+    @Override
+    public String check() throws ManifoldCFException {
+        try {
+            //Logging.connectors.info("Checking Connection");
+            return super.check();
+        } catch (ManifoldCFException e) {
+            return "Connection failed: " + e.getMessage();
+        }
+    }
+
+
+
+
+    /** Set up a session */
+    protected void getSession() throws ManifoldCFException, ServiceInterruption {
+        //Logging.connectors.info("Getting Session ");
+        if (DropFolderPath == null) {
+            // Check for parameter validity
+            if (StringUtils.isEmpty(username))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.USERNAME_PARAM + " required but not set");
+            if (Logging.connectors.isDebugEnabled())
+                Logging.connectors.debug("Username = '" + username + "'");
+            if (StringUtils.isEmpty(password))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.PASSWORD_PARAM + " required but not set");
+            Logging.connectors.debug(" Password exists");
+            if (StringUtils.isEmpty(protocol))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.PROTOCOL_PARAM + " required but not set");
+            if (StringUtils.isEmpty(server))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.SERVER_PARAM + " required but not set");
+            if (StringUtils.isEmpty(port))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.PORT_PARAM + " required but not set");
+            if (StringUtils.isEmpty(path))
+                throw new ManifoldCFException("Parameter " + AlfrescoBfsiOutputConfig.PATH_PARAM + " required but not set");
+            // Create path object with the output connector path location (dropZone)
+            DropFolderPath= Paths.get(path);
+        }
+        long currentTime;
+        GetDropFolderPath t = new GetDropFolderPath();
+        try {
+            t.start();
+            t.join();
+            Throwable thr = t.getException();
+            if (thr != null) {
+                if (thr instanceof java.net.MalformedURLException)
+                    throw (java.net.MalformedURLException) thr;
+                else if (thr instanceof NotBoundException)
+                    throw (NotBoundException) thr;
+                else if (thr instanceof RemoteException)
+                    throw (RemoteException) thr;
+                else
+                    throw (Error) thr;
+            }
+        } catch (InterruptedException e) {
+            t.interrupt();
+            throw new ManifoldCFException("Interrupted: " + e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+        } catch (java.net.MalformedURLException e) {
+            throw new ManifoldCFException(e.getMessage(), e);
+        } catch (NotBoundException e) {
+            // Transient problem: Server not available at the moment.
+            Logging.connectors.warn("Target DropFolder Path not up at the moment: " + e.getMessage(), e);
+            currentTime = System.currentTimeMillis();
+            throw new ServiceInterruption(e.getMessage(), currentTime + 60000L);
+        } catch (RemoteException e) {
+            Throwable e2 = e.getCause();
+            if (e2 instanceof InterruptedException || e2 instanceof InterruptedIOException)
+                throw new ManifoldCFException(e2.getMessage(), e2, ManifoldCFException.INTERRUPTED);
+            // Treat this as a transient problem
+            Logging.connectors.warn("Transient remote exception creating session: " + e.getMessage(), e);
+            currentTime = System.currentTimeMillis();
+            throw new ServiceInterruption(e.getMessage(), currentTime + 60000L);
+        }
+
+
+        lastSessionFetch = System.currentTimeMillis();
+    }
+
+
+    protected void checkConnection() throws ManifoldCFException, ServiceInterruption {
+        while (true) {
+            boolean noPathObject = (DropFolderPath == null);
+            getSession();
+            long currentTime;
+            CheckConnectionThread t = new CheckConnectionThread();
+            try {
+                t.start();
+                t.join();
+                Throwable thr = t.getException();
+                if (thr != null) {
+                    if (thr instanceof RemoteException)
+                        throw (RemoteException) thr;
+                    else
+                        throw (Error) thr;
+                }
+                return;
+            } catch (InterruptedException e) {
+                t.interrupt();
+                throw new ManifoldCFException("Interrupted: " + e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+            } catch (RemoteException e) {
+                Throwable e2 = e.getCause();
+                if (e2 instanceof InterruptedException || e2 instanceof InterruptedIOException)
+                    throw new ManifoldCFException(e2.getMessage(), e2, ManifoldCFException.INTERRUPTED);
+                if (noPathObject) {
+                    currentTime = System.currentTimeMillis();
+                    throw new ServiceInterruption("Transient error connecting to file system service: " + e.getMessage(),
+                            currentTime + 60000L);
+                }
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+                continue;
+            }
+        }
+    }
+
+
+
+    /**
+     * Release the session, if it's time.
+     */
+    protected void releaseCheck() throws ManifoldCFException {
+        Logging.connectors.error("Starting releaseCheck ");
+        if (lastSessionFetch == -1L)
+            return;
+
+        long currentTime = System.currentTimeMillis();
+        if (currentTime >= lastSessionFetch + timeToRelease) {
+            DestroyDropFolderPath t = new DestroyDropFolderPath();
+            try {
+                t.start();
+                t.join();
+                Throwable thr = t.getException();
+                if (thr != null) {
+                    if (thr instanceof RemoteException)
+                        throw (RemoteException) thr;
+                    else
+                        throw (Error) thr;
+                }
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+            } catch (InterruptedException e) {
+                t.interrupt();
+                throw new ManifoldCFException("Interrupted: " + e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+            } catch (RemoteException e) {
+                Throwable e2 = e.getCause();
+                if (e2 instanceof InterruptedException || e2 instanceof InterruptedIOException)
+                    throw new ManifoldCFException(e2.getMessage(), e2, ManifoldCFException.INTERRUPTED);
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+                // Treat this as a transient problem
+                Logging.connectors.warn("Transient remote exception closing session: " + e.getMessage(), e);
+            }
+
+        }
+    }
+
+
+
+    /**
+     * This method is periodically called for all connectors that are connected
+     * but not in active use.
+     */
+    @Override
+    public void poll() throws ManifoldCFException {
+        if (lastSessionFetch == -1L)
+            return;
+
+        long currentTime = System.currentTimeMillis();
+        if (currentTime >= lastSessionFetch + timeToRelease) {
+            DestroyDropFolderPath t = new DestroyDropFolderPath();
+            try {
+                t.start();
+                t.join();
+                Throwable thr = t.getException();
+                if (thr != null) {
+                    if (thr instanceof RemoteException)
+                        throw (RemoteException) thr;
+                    else
+                        throw (Error) thr;
+                }
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+            } catch (InterruptedException e) {
+                t.interrupt();
+                throw new ManifoldCFException("Interrupted: " + e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+            } catch (RemoteException e) {
+                Throwable e2 = e.getCause();
+                if (e2 instanceof InterruptedException || e2 instanceof InterruptedIOException)
+                    throw new ManifoldCFException(e2.getMessage(), e2, ManifoldCFException.INTERRUPTED);
+                DropFolderPath = null;
+                lastSessionFetch = -1L;
+                // Treat this as a transient problem
+                Logging.connectors.warn("Remote exception closing path object: " + e.getMessage(), e);
+            }
+
+        }
+    }
+
+
+
+
+
+    /**
+     * This method is called to assess whether to count this connector instance
+     * should actually be counted as being connected (having a path object to dropFolder)
+     *
+     * @return true if the connector instance is actually connected (could get a path object of dropFolder)
+     */
+    @Override
+    public boolean isConnected() {
+        return DropFolderPath != null;
+    }
+
+    /**
+     * Read the content of a resource, replace the variable ${PARAMNAME} with the
+     * value and copy it to the out.
+     *
+     * @param resName
+     * @param out
+     * @throws ManifoldCFException
+     */
+    private static void outputResource(String resName, IHTTPOutput out, Locale locale, Map<String, String> paramMap)
+            throws ManifoldCFException {
+        //Logging.connectors.info(" In outputResource");
+        Messages.outputResourceWithVelocity(out, locale, resName, paramMap, true);
+    }
+
+    /**
+     * Fill in a Server tab configuration parameter map for calling a Velocity
+     * template.
+     *
+     * @param newMap
+     *          is the map to fill in
+     * @param parameters
+     *          is the current set of configuration parameters
+     */
+    private static void fillInServerConfigurationMap(Map<String, String> newMap, IPasswordMapperActivity mapper,
+                                                     ConfigParams parameters) {
+
+
+        //Logging.connectors.info("In fillInServerConfigurationMap ");
+        String username = parameters.getParameter(AlfrescoBfsiOutputConfig.USERNAME_PARAM);
+        String password = parameters.getParameter(AlfrescoBfsiOutputConfig.PASSWORD_PARAM);
+        String protocol = parameters.getParameter(AlfrescoBfsiOutputConfig.PROTOCOL_PARAM);
+        String server = parameters.getParameter(AlfrescoBfsiOutputConfig.SERVER_PARAM);
+        String port = parameters.getParameter(AlfrescoBfsiOutputConfig.PORT_PARAM);
+        String path = parameters.getParameter(AlfrescoBfsiOutputConfig.PATH_PARAM);
+
+        String dropfolder = parameters.getParameter(AlfrescoBfsiOutputConfig.DROPFOLDER_PARAM);
+        String createTimestampTree = parameters.getParameter(AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_PARAM);
+
+        if (dropfolder == null)
+            dropfolder = StringUtils.EMPTY;
+
+        if(createTimestampTree == null)
+            createTimestampTree = AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_DEFAULT_VALUE;
+
+
+        if (username == null)
+            username = StringUtils.EMPTY;
+        if (password == null)
+            password = StringUtils.EMPTY;
+        else
+            password = mapper.mapPasswordToKey(password);
+        if (protocol == null)
+            protocol = AlfrescoBfsiOutputConfig.PROTOCOL_DEFAULT_VALUE;
+        if (server == null)
+            server = AlfrescoBfsiOutputConfig.SERVER_DEFAULT_VALUE;
+        if (port == null)
+            port = AlfrescoBfsiOutputConfig.PORT_DEFAULT_VALUE;
+        if (path == null)
+            path = AlfrescoBfsiOutputConfig.PATH_DEFAULT_VALUE;
+
+
+        newMap.put(AlfrescoBfsiOutputConfig.USERNAME_PARAM, username);
+        newMap.put(AlfrescoBfsiOutputConfig.PASSWORD_PARAM, password);
+        newMap.put(AlfrescoBfsiOutputConfig.PROTOCOL_PARAM, protocol);
+        newMap.put(AlfrescoBfsiOutputConfig.SERVER_PARAM, server);
+        newMap.put(AlfrescoBfsiOutputConfig.PORT_PARAM, port);
+        newMap.put(AlfrescoBfsiOutputConfig.PATH_PARAM, path);
+        newMap.put(AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_PARAM, createTimestampTree);
+        newMap.put(AlfrescoBfsiOutputConfig.DROPFOLDER_PARAM, dropfolder);
+        //Logging.connectors.info("Cabaceira Ending fillInServerConfigurationMap" + username + "-- pass - " + password + "-- protocol -- " + protocol + "--- server ---" + server + "-- port --" + port
+        //+ "---path---" + path + "--- createTimestamp ---" + createTimestampTree + " --- dropfolder ---" + dropfolder);
+    }
+
+
+    /**
+     * View configuration. This method is called in the body section of the
+     * connector's view configuration page. Its purpose is to present the
+     * connection information to the user. The coder can presume that the HTML
+     * that is output from this configuration will be within appropriate
+     * <html> and <body> tags.
+     *
+     * @param threadContext
+     *          is the local thread context.
+     * @param out
+     *          is the output to which any HTML should be sent.
+     * @param parameters
+     *          are the configuration parameters, as they currently exist, for
+     *          this connection being configured.
+     */
+    @Override
+    public void viewConfiguration(IThreadContext threadContext, IHTTPOutput out, Locale locale, ConfigParams parameters)
+            throws ManifoldCFException, IOException {
+
+        //Logging.connectors.info(" In viewConfiguration ");
+        Map<String, String> paramMap = new HashMap<String, String>();
+
+        // Fill in map from each tab
+        fillInServerConfigurationMap(paramMap, out, parameters);
+        outputResource(VIEW_CONFIG_FORWARD, out, locale, paramMap);
+    }
+
+    /**
+     *
+     * Output the configuration header section. This method is called in the head
+     * section of the connector's configuration page. Its purpose is to add the
+     * required tabs to the list, and to output any javascript methods that might
+     * be needed by the configuration editing HTML.
+     *
+     * @param threadContext
+     *          is the local thread context.
+     * @param out
+     *          is the output to which any HTML should be sent.
+     * @param parameters
+     *          are the configuration parameters, as they currently exist, for
+     *          this connection being configured.
+     * @param tabsArray
+     *          is an array of tab names. Add to this array any tab names that are
+     *          specific to the connector.
+     */
+    @Override
+    public void outputConfigurationHeader(IThreadContext threadContext, IHTTPOutput out, Locale locale,
+                                          ConfigParams parameters, List<String> tabsArray) throws ManifoldCFException, IOException {
+        // Add the Server tab
+        tabsArray.add(Messages.getString(locale, TARGET_DROP_FOLDER_TAB_PROPERTY));
+        Logging.connectors.info(" In viewConfiguration ");
+        // Map the parameters
+        Map<String, String> paramMap = new HashMap<String, String>();
+        // Fill in the parameters from each tab
+        fillInServerConfigurationMap(paramMap, out, parameters);
+        // Output the Javascript - only one Velocity template for all tabs
+        outputResource(EDIT_CONFIG_HEADER_FORWARD, out, locale, paramMap);
+    }
+
+
+
+    @Override
+    public void outputConfigurationBody(IThreadContext threadContext, IHTTPOutput out, Locale locale,
+                                        ConfigParams parameters, String tabName) throws ManifoldCFException, IOException {
+
+        // Call the Velocity templates for each tab
+       // Logging.connectors.error("In viewConfiguration ");
+        // Server tab
+        Map<String, String> paramMap = new HashMap<String, String>();
+        // Set the tab name
+        paramMap.put("TabName", tabName);
+        // Fill in the parameters
+        fillInServerConfigurationMap(paramMap, out, parameters);
+        outputResource(EDIT_CONFIG_FORWARD_SERVER, out, locale, paramMap);
+
+    }
+
+
+
+
+
+
+
+    /**
+     * Process a configuration post. This method is called at the start of the
+     * connector's configuration page, whenever there is a possibility that form
+     * data for a connection has been posted. Its purpose is to gather form
+     * information and modify the configuration parameters accordingly. The name
+     * of the posted form is "editconnection".
+     *
+     * @param threadContext
+     *          is the local thread context.
+     * @param variableContext
+     *          is the set of variables available from the post, including binary
+     *          file post information.
+     * @param parameters
+     *          are the configuration parameters, as they currently exist, for
+     *          this connection being configured.
+     * @return null if all is well, or a string error message if there is an error
+     *         that should prevent saving of the connection (and cause a
+     *         redirection to an error page).
+     */
+    @Override
+    public String processConfigurationPost(IThreadContext threadContext, IPostParameters variableContext,
+                                           ConfigParams parameters) throws ManifoldCFException {
+
+
+        String dropfolder = variableContext.getParameter(AlfrescoBfsiOutputConfig.DROPFOLDER_PARAM);
+        if (dropfolder != null)
+            parameters.setParameter(AlfrescoBfsiOutputConfig.DROPFOLDER_PARAM, dropfolder);
+
+
+        String createTimestampTree = variableContext.getParameter(AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_PARAM);
+        if (createTimestampTree != null) {
+            parameters.setParameter(AlfrescoBfsiOutputConfig.CREATE_TIMESTAMP_TREE_PARAM, createTimestampTree);
+        }
+
+
+        String username = variableContext.getParameter(AlfrescoBfsiOutputConfig.USERNAME_PARAM);
+        if (username != null)
+            parameters.setParameter(AlfrescoBfsiOutputConfig.USERNAME_PARAM, username);
+
+        String password = variableContext.getParameter(AlfrescoBfsiOutputConfig.PASSWORD_PARAM);
+        if (password != null)
+            parameters.setParameter(AlfrescoBfsiOutputConfig.PASSWORD_PARAM, variableContext.mapKeyToPassword(password));
+
+        String protocol = variableContext.getParameter(AlfrescoBfsiOutputConfig.PROTOCOL_PARAM);
+        if (protocol != null) {
+            parameters.setParameter(AlfrescoBfsiOutputConfig.PROTOCOL_PARAM, protocol);
+        }
+
+        String server = variableContext.getParameter(AlfrescoBfsiOutputConfig.SERVER_PARAM);
+        if (server != null && !StringUtils.contains(server, '/')) {
+            parameters.setParameter(AlfrescoBfsiOutputConfig.SERVER_PARAM, server);
+        }
+
+        String port = variableContext.getParameter(AlfrescoBfsiOutputConfig.PORT_PARAM);
+        if (port != null) {
+            try {
+                Integer.parseInt(port);
+                parameters.setParameter(AlfrescoBfsiOutputConfig.PORT_PARAM, port);
+            } catch (NumberFormatException e) {
+
+            }
+        }
+
+        String path = variableContext.getParameter(AlfrescoBfsiOutputConfig.PATH_PARAM);
+        if (path != null) {
+            parameters.setParameter(AlfrescoBfsiOutputConfig.PATH_PARAM, path);
+        }
+
+
+
+
+        return null;
+    }
+
+
+    private boolean isSourceRepoCmisCompliant(RepositoryDocument document) {
+        Iterator<String> fields = document.getFields();
+        while (fields.hasNext()) {
+            String fieldName = (String) fields.next();
+            if (StringUtils.startsWith(fieldName, CMIS_PROPERTY_PREFIX)) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+
+    private boolean isSourceRepoDropBox(RepositoryDocument document) {
+        Iterator<String> fields = document.getFields();
+        while (fields.hasNext()) {
+            String fieldName = (String) fields.next();
+            if (StringUtils.startsWith(fieldName, "dropbox")) { //TODO LOGIC
+                return true;
+            }
+        }
+        return false;
+    }
+
+
+    @Override // called for each content item.
+    public int addOrReplaceDocumentWithException(String documentURI, VersionContext pipelineDescription,
+                                                 RepositoryDocument document, String authorityNameString, IOutputAddActivity activities)
+            throws ManifoldCFException, ServiceInterruption, IOException {
+
+        getSession();
+
+        DateFormat dateFormat = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
+        Calendar cal = Calendar.getInstance();
+        String date = dateFormat.format(cal.getTime());
+        String objectId = StringUtils.EMPTY;
+        Properties metadataProperties = new Properties();
+        /*
+        * HERE WE CAN CALL TRANSFORMERS OR CUSTOM METADATA AGENTS THAT ARE RESPONSIBLE TO EXTRACT THE METADATA FROM THE SOURCE
+        *
+        * USING SOME DEFAULT DUMMY VALUES FOR NOW
+        * */
+        metadataProperties.setProperty("type", "cm:content");
+        metadataProperties.setProperty("aspects", "cm:versionable,cm:dublincore");
+        metadataProperties.setProperty("cm:title", "Crawled document from ManifoldCF Input Connectors : " + date);
+        metadataProperties.setProperty("cm:description", "");
+        metadataProperties.setProperty("cm:author", "Apache ManifoldCF BulkFilesystem Output Connector");
+        metadataProperties.setProperty("cm:publisher", "BulkFilesystem Output Connector");
+        metadataProperties.setProperty("cm:contributor", "BulkFilesystem Output Connector");
+        metadataProperties.setProperty("cm:type", "default_plus_dubincore_aspect");
+        metadataProperties.setProperty("cm:identifier", document.getFileName());
+        metadataProperties.setProperty("cm:source", "BulkFilesystem Output Connector");
+        metadataProperties.setProperty("cm:coverage", "General");
+        metadataProperties.setProperty("cm:rights", "");
+        metadataProperties.setProperty("cm:subject", "Metadata file created with Apache ManifoldCF BulkFilesystem Output Connector");
+
+        /* *************************************************************************************************************************
+           ************************************ MAPPING LOGIC (REPOSITORY SOURCES) *************************************************
+           *************************************************************************************************************************/
+
+        /*
+            CMIS Repository Connector Source  - Override the objectId for synchronizing with removeDocument method
+        */
+        if(isSourceRepoCmisCompliant(document)) {
+            //Logging.connectors.info("CmisCompliant source repo - mapping cmis metada into node's shadow metadata file");
+            String[] cmisObjectIdArray = (String[]) document.getField(PropertyIds.OBJECT_ID);
+            if(cmisObjectIdArray!=null && cmisObjectIdArray.length>0) {
+                objectId = cmisObjectIdArray[0];
+            }
+
+            //Mapping all the CMIS properties ...
+            /*
+            Iterator<String> fields = document.getFields();
+            while (fields.hasNext()) {
+                String field = (String) fields.next();
+                if(!StringUtils.equals(field, "cm:lastThumbnailModification")
+                        || !StringUtils.equals(field, "cmis:secondaryObjectTypeIds")) {
+                    String[] valuesArray = (String[]) document.getField(field);
+                    properties.put(field,valuesArray);
+                }
+            }
+            */
+            //Agnostic metadata from cmis repo
+            metadataProperties.setProperty(PropertyIds.OBJECT_TYPE_ID, CMIS_DOCUMENT_TYPE);
+            metadataProperties.setProperty(PropertyIds.CREATION_DATE, document.getCreatedDate().toString());
+            metadataProperties.setProperty(PropertyIds.LAST_MODIFICATION_DATE, document.getModifiedDate().toString());
+            //check objectId
+            if(StringUtils.isNotEmpty(objectId)){
+                ObjectId objId = new ObjectIdImpl(objectId);
+                String uuid = objId.getId().substring(0,objId.getId().indexOf(';'));
+                metadataProperties.setProperty("sys:node-uuid", uuid);
+            }
+        }
+
+        if(isSourceRepoDropBox(document)) {
+            //Logging.connectors.info("DropBox source repo - mapping metada into node's shadow metadata file");
+        }
+
+        // Add more input connectors specific logic here
+
+
+        /* *************************************************************************************************************************
+           ************************************ END MAPPING LOGIC (REPOSITORY SOURCES) *********************************************
+           *************************************************************************************************************************/
+
+        // Creating target node in BFSI format (document + shadow metadata xml file)
+        AlfrescoBfsiOutputAgent.createBulkDocument(document.getBinaryStream(),document.getFileName(),metadataProperties,DropFolderPath);
+
+
+       // Logging.connectors.error("In addOrReplaceDocumentWithException -- " + document.getFileName());
+       // Logging.connectors.error("DropFolder filesystem is " + DropFolderPath.getFileSystem());
+       // Logging.connectors.error("DropFolder path is " + DropFolderPath.toString());
+       // Logging.connectors.error("Parent is " + DropFolderPath.getParent() + " Root is " + DropFolderPath.getRoot());
+
+
+        return DOCUMENT_STATUS_ACCEPTED;
+    }
+
+
+
+
+    @Override
+    public void removeDocument(String documentURI, String outputDescription, IOutputRemoveActivity activities)
+            throws ManifoldCFException, ServiceInterruption {
+        getSession();
+        Logging.connectors.error("In removeDocument -- " + documentURI);
+        long startTime = System.currentTimeMillis();
+        String result = StringUtils.EMPTY;
+
+        //append the prefix for the relative path in the target repo
+        String parentDropZonePath = DropFolderPath.toString();
+        String fullDocumentURIinTargetRepo = parentDropZonePath + documentURI;
+        Path documentPathInTarget = Paths.get(fullDocumentURIinTargetRepo);
+        Path documentShadowMetaPathInTarget = Paths.get(fullDocumentURIinTargetRepo + ".metadata.properties.xml");
+        try {
+            if(Files.exists(documentPathInTarget)) {
+                // delete document and shadow metadata file
+                Files.delete(documentPathInTarget);
+                Files.delete(documentShadowMetaPathInTarget);
+                result = DOCUMENT_DELETION_STATUS_ACCEPTED;
+            } else {
+                result = DOCUMENT_DELETION_STATUS_REJECTED;
+            }
+        } catch (Exception e) {
+            result = DOCUMENT_DELETION_STATUS_REJECTED;
+            throw new ManifoldCFException(e.getMessage(), e);
+        } finally {
+            activities.recordActivity(startTime, ACTIVITY_DELETE, null, documentURI, null, result);
+        }
+    }
+
+    protected static void handleIOException(IOException e, String context)
+            throws ManifoldCFException, ServiceInterruption {
+        if (e instanceof InterruptedIOException) {
+            throw new ManifoldCFException(e.getMessage(), e, ManifoldCFException.INTERRUPTED);
+        } else {
+            Logging.connectors.warn("IOException " + context + ": " + e.getMessage(), e);
+            throw new ManifoldCFException(e.getMessage(), e);
+        }
+    }
+
+
+
+
+
+
+
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnectorUtils.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnectorUtils.java
new file mode 100644
index 0000000..7b58a4a
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/AlfrescoBfsiOutputConnectorUtils.java
@@ -0,0 +1,30 @@
+/* $Id$ */
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+
+/**
+ *
+ * @author Luis Cabaceira
+ *
+ */
+public class AlfrescoBfsiOutputConnectorUtils {
+
+
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/ColumnSet.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/ColumnSet.java
new file mode 100644
index 0000000..41d49da
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/ColumnSet.java
@@ -0,0 +1,61 @@
+/* $Id$ */
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+import org.apache.commons.lang.StringUtils;
+
+/**
+ * 
+ * @author Luis Cabaceira
+ *
+ */
+public class ColumnSet {
+
+    private String name = StringUtils.EMPTY;
+    private String alias = StringUtils.EMPTY;
+
+    public ColumnSet() {}
+
+    public ColumnSet(String name, String alias) {
+        this.name = name;
+        this.alias = alias;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getAlias() {
+        return alias;
+    }
+
+    public void setAlias(String alias) {
+        this.alias = alias;
+    }
+
+    @Override
+    public String toString() {
+        return "ColumnSet{name=" + name + ", alias=" + alias + '}';
+    }
+
+}
diff --git a/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/Messages.java b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/Messages.java
new file mode 100644
index 0000000..3a5e72b
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/java/org/apache/manifoldcf/agents/output/bfsioutput/Messages.java
@@ -0,0 +1,142 @@
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package org.apache.manifoldcf.agents.output.bfsioutput;
+
+import org.apache.manifoldcf.core.interfaces.IHTTPOutput;
+import org.apache.manifoldcf.core.interfaces.ManifoldCFException;
+
+import java.util.Locale;
+import java.util.Map;
+
+public class Messages extends org.apache.manifoldcf.ui.i18n.Messages
+{
+  public static final String DEFAULT_BUNDLE_NAME="org.apache.manifoldcf.agents.output.bfsioutput.common";
+  public static final String DEFAULT_PATH_NAME="org.apache.manifoldcf.agents.output.bfsioutput";
+  
+  /** Constructor - do no instantiate
+  */
+  protected Messages()
+  {
+  }
+  
+  public static String getString(Locale locale, String messageKey)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+
+  public static String getAttributeString(Locale locale, String messageKey)
+  {
+    return getAttributeString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+
+  public static String getBodyString(Locale locale, String messageKey)
+  {
+    return getBodyString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+
+  public static String getAttributeJavascriptString(Locale locale, String messageKey)
+  {
+    return getAttributeJavascriptString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+
+  public static String getBodyJavascriptString(Locale locale, String messageKey)
+  {
+    return getBodyJavascriptString(DEFAULT_BUNDLE_NAME, locale, messageKey, null);
+  }
+
+  public static String getString(Locale locale, String messageKey, Object[] args)
+  {
+    return getString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+
+  public static String getAttributeString(Locale locale, String messageKey, Object[] args)
+  {
+    return getAttributeString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+  
+  public static String getBodyString(Locale locale, String messageKey, Object[] args)
+  {
+    return getBodyString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+
+  public static String getAttributeJavascriptString(Locale locale, String messageKey, Object[] args)
+  {
+    return getAttributeJavascriptString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+
+  public static String getBodyJavascriptString(Locale locale, String messageKey, Object[] args)
+  {
+    return getBodyJavascriptString(DEFAULT_BUNDLE_NAME, locale, messageKey, args);
+  }
+
+  // More general methods which allow bundlenames and class loaders to be specified.
+  
+  public static String getString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    return getString(Messages.class, bundleName, locale, messageKey, args);
+  }
+
+  public static String getAttributeString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    return getAttributeString(Messages.class, bundleName, locale, messageKey, args);
+  }
+
+  public static String getBodyString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    return getBodyString(Messages.class, bundleName, locale, messageKey, args);
+  }
+  
+  public static String getAttributeJavascriptString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    return getAttributeJavascriptString(Messages.class, bundleName, locale, messageKey, args);
+  }
+
+  public static String getBodyJavascriptString(String bundleName, Locale locale, String messageKey, Object[] args)
+  {
+    return getBodyJavascriptString(Messages.class, bundleName, locale, messageKey, args);
+  }
+
+  // Resource output
+  
+  public static void outputResource(IHTTPOutput output, Locale locale, String resourceKey,
+    Map<String,String> substitutionParameters, boolean mapToUpperCase)
+    throws ManifoldCFException
+  {
+    outputResource(output,Messages.class,DEFAULT_PATH_NAME,locale,resourceKey,
+      substitutionParameters,mapToUpperCase);
+  }
+  
+  public static void outputResourceWithVelocity(IHTTPOutput output, Locale locale, String resourceKey,
+    Map<String,String> substitutionParameters, boolean mapToUpperCase)
+    throws ManifoldCFException
+  {
+    outputResourceWithVelocity(output,Messages.class,DEFAULT_BUNDLE_NAME,DEFAULT_PATH_NAME,locale,resourceKey,
+      substitutionParameters,mapToUpperCase);
+  }
+
+  public static void outputResourceWithVelocity(IHTTPOutput output, Locale locale, String resourceKey,
+    Map<String,Object> contextObjects)
+    throws ManifoldCFException
+  {
+    outputResourceWithVelocity(output,Messages.class,DEFAULT_BUNDLE_NAME,DEFAULT_PATH_NAME,locale,resourceKey,
+      contextObjects);
+  }
+  
+}
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_en_US.properties b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_en_US.properties
new file mode 100644
index 0000000..da181ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_en_US.properties
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+AlfrescoBfsiOutputConnector.Server=localhost
+AlfrescoBfsiOutputConnector.BfsiParametersTab=Bfsi Output Parameters
+
+AlfrescoBfsiOutputConnector.DropFolder=Drop Folder Configuration
+AlfrescoBfsiOutputConnector.DropFolderColon=DropFolder:
+AlfrescoBfsiOutputConnector.TheDropFolderMustNotBeNull=The dropfolder must not be null
+
+AlfrescoBfsiOutputConnector.UsernameColon=Username:
+AlfrescoBfsiOutputConnector.PasswordColon=Password:
+AlfrescoBfsiOutputConnector.ProtocolColon=Protocol:
+AlfrescoBfsiOutputConnector.ServerColon=Server:
+AlfrescoBfsiOutputConnector.PortColon=Port:
+AlfrescoBfsiOutputConnector.PathColon=Path:
+
+
+
+AlfrescoBfsiOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree:
+AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals=createTimestampTree=
+
+
+
+AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull=The username must not be null
+AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull=The password must not be null
+AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull=Server name must be not null
+AlfrescoBfsiOutputConnector.ServerNameCantContainSlash=Server name can't contain the character '/'
+AlfrescoBfsiOutputConnector.ThePortMustNotBeNull=The port must be not null
+AlfrescoBfsiOutputConnector.TheProtocolMustNotBeNull=The Protocol must be not null
+AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger=The server port must be a valid integer
+AlfrescoBfsiOutputConnector.PathMustNotBeNull=Path must be not null
+
+
+
+AlfrescoBfsiOutputConnector.ParametersColon=Parameters:
+AlfrescoBfsiOutputConnector.UsernameEquals=username=
+AlfrescoBfsiOutputConnector.PasswordEquals=password=
+AlfrescoBfsiOutputConnector.ProtocolEquals=protocol=
+AlfrescoBfsiOutputConnector.ServerEquals=server=
+AlfrescoBfsiOutputConnector.PortEquals=port=
+AlfrescoBfsiOutputConnector.PathEquals=path=
+
+
+
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_es_ES.properties b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_es_ES.properties
new file mode 100644
index 0000000..da181ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_es_ES.properties
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+AlfrescoBfsiOutputConnector.Server=localhost
+AlfrescoBfsiOutputConnector.BfsiParametersTab=Bfsi Output Parameters
+
+AlfrescoBfsiOutputConnector.DropFolder=Drop Folder Configuration
+AlfrescoBfsiOutputConnector.DropFolderColon=DropFolder:
+AlfrescoBfsiOutputConnector.TheDropFolderMustNotBeNull=The dropfolder must not be null
+
+AlfrescoBfsiOutputConnector.UsernameColon=Username:
+AlfrescoBfsiOutputConnector.PasswordColon=Password:
+AlfrescoBfsiOutputConnector.ProtocolColon=Protocol:
+AlfrescoBfsiOutputConnector.ServerColon=Server:
+AlfrescoBfsiOutputConnector.PortColon=Port:
+AlfrescoBfsiOutputConnector.PathColon=Path:
+
+
+
+AlfrescoBfsiOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree:
+AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals=createTimestampTree=
+
+
+
+AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull=The username must not be null
+AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull=The password must not be null
+AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull=Server name must be not null
+AlfrescoBfsiOutputConnector.ServerNameCantContainSlash=Server name can't contain the character '/'
+AlfrescoBfsiOutputConnector.ThePortMustNotBeNull=The port must be not null
+AlfrescoBfsiOutputConnector.TheProtocolMustNotBeNull=The Protocol must be not null
+AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger=The server port must be a valid integer
+AlfrescoBfsiOutputConnector.PathMustNotBeNull=Path must be not null
+
+
+
+AlfrescoBfsiOutputConnector.ParametersColon=Parameters:
+AlfrescoBfsiOutputConnector.UsernameEquals=username=
+AlfrescoBfsiOutputConnector.PasswordEquals=password=
+AlfrescoBfsiOutputConnector.ProtocolEquals=protocol=
+AlfrescoBfsiOutputConnector.ServerEquals=server=
+AlfrescoBfsiOutputConnector.PortEquals=port=
+AlfrescoBfsiOutputConnector.PathEquals=path=
+
+
+
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_ja_JP.properties b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_ja_JP.properties
new file mode 100644
index 0000000..da181ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_ja_JP.properties
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+AlfrescoBfsiOutputConnector.Server=localhost
+AlfrescoBfsiOutputConnector.BfsiParametersTab=Bfsi Output Parameters
+
+AlfrescoBfsiOutputConnector.DropFolder=Drop Folder Configuration
+AlfrescoBfsiOutputConnector.DropFolderColon=DropFolder:
+AlfrescoBfsiOutputConnector.TheDropFolderMustNotBeNull=The dropfolder must not be null
+
+AlfrescoBfsiOutputConnector.UsernameColon=Username:
+AlfrescoBfsiOutputConnector.PasswordColon=Password:
+AlfrescoBfsiOutputConnector.ProtocolColon=Protocol:
+AlfrescoBfsiOutputConnector.ServerColon=Server:
+AlfrescoBfsiOutputConnector.PortColon=Port:
+AlfrescoBfsiOutputConnector.PathColon=Path:
+
+
+
+AlfrescoBfsiOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree:
+AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals=createTimestampTree=
+
+
+
+AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull=The username must not be null
+AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull=The password must not be null
+AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull=Server name must be not null
+AlfrescoBfsiOutputConnector.ServerNameCantContainSlash=Server name can't contain the character '/'
+AlfrescoBfsiOutputConnector.ThePortMustNotBeNull=The port must be not null
+AlfrescoBfsiOutputConnector.TheProtocolMustNotBeNull=The Protocol must be not null
+AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger=The server port must be a valid integer
+AlfrescoBfsiOutputConnector.PathMustNotBeNull=Path must be not null
+
+
+
+AlfrescoBfsiOutputConnector.ParametersColon=Parameters:
+AlfrescoBfsiOutputConnector.UsernameEquals=username=
+AlfrescoBfsiOutputConnector.PasswordEquals=password=
+AlfrescoBfsiOutputConnector.ProtocolEquals=protocol=
+AlfrescoBfsiOutputConnector.ServerEquals=server=
+AlfrescoBfsiOutputConnector.PortEquals=port=
+AlfrescoBfsiOutputConnector.PathEquals=path=
+
+
+
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_pt_PT.properties b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_pt_PT.properties
new file mode 100644
index 0000000..da181ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_pt_PT.properties
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+AlfrescoBfsiOutputConnector.Server=localhost
+AlfrescoBfsiOutputConnector.BfsiParametersTab=Bfsi Output Parameters
+
+AlfrescoBfsiOutputConnector.DropFolder=Drop Folder Configuration
+AlfrescoBfsiOutputConnector.DropFolderColon=DropFolder:
+AlfrescoBfsiOutputConnector.TheDropFolderMustNotBeNull=The dropfolder must not be null
+
+AlfrescoBfsiOutputConnector.UsernameColon=Username:
+AlfrescoBfsiOutputConnector.PasswordColon=Password:
+AlfrescoBfsiOutputConnector.ProtocolColon=Protocol:
+AlfrescoBfsiOutputConnector.ServerColon=Server:
+AlfrescoBfsiOutputConnector.PortColon=Port:
+AlfrescoBfsiOutputConnector.PathColon=Path:
+
+
+
+AlfrescoBfsiOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree:
+AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals=createTimestampTree=
+
+
+
+AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull=The username must not be null
+AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull=The password must not be null
+AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull=Server name must be not null
+AlfrescoBfsiOutputConnector.ServerNameCantContainSlash=Server name can't contain the character '/'
+AlfrescoBfsiOutputConnector.ThePortMustNotBeNull=The port must be not null
+AlfrescoBfsiOutputConnector.TheProtocolMustNotBeNull=The Protocol must be not null
+AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger=The server port must be a valid integer
+AlfrescoBfsiOutputConnector.PathMustNotBeNull=Path must be not null
+
+
+
+AlfrescoBfsiOutputConnector.ParametersColon=Parameters:
+AlfrescoBfsiOutputConnector.UsernameEquals=username=
+AlfrescoBfsiOutputConnector.PasswordEquals=password=
+AlfrescoBfsiOutputConnector.ProtocolEquals=protocol=
+AlfrescoBfsiOutputConnector.ServerEquals=server=
+AlfrescoBfsiOutputConnector.PortEquals=port=
+AlfrescoBfsiOutputConnector.PathEquals=path=
+
+
+
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_zh_CN.properties b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_zh_CN.properties
new file mode 100644
index 0000000..da181ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/bfsioutput/common_zh_CN.properties
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+AlfrescoBfsiOutputConnector.Server=localhost
+AlfrescoBfsiOutputConnector.BfsiParametersTab=Bfsi Output Parameters
+
+AlfrescoBfsiOutputConnector.DropFolder=Drop Folder Configuration
+AlfrescoBfsiOutputConnector.DropFolderColon=DropFolder:
+AlfrescoBfsiOutputConnector.TheDropFolderMustNotBeNull=The dropfolder must not be null
+
+AlfrescoBfsiOutputConnector.UsernameColon=Username:
+AlfrescoBfsiOutputConnector.PasswordColon=Password:
+AlfrescoBfsiOutputConnector.ProtocolColon=Protocol:
+AlfrescoBfsiOutputConnector.ServerColon=Server:
+AlfrescoBfsiOutputConnector.PortColon=Port:
+AlfrescoBfsiOutputConnector.PathColon=Path:
+
+
+
+AlfrescoBfsiOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree:
+AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals=createTimestampTree=
+
+
+
+AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull=The username must not be null
+AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull=The password must not be null
+AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull=Server name must be not null
+AlfrescoBfsiOutputConnector.ServerNameCantContainSlash=Server name can't contain the character '/'
+AlfrescoBfsiOutputConnector.ThePortMustNotBeNull=The port must be not null
+AlfrescoBfsiOutputConnector.TheProtocolMustNotBeNull=The Protocol must be not null
+AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger=The server port must be a valid integer
+AlfrescoBfsiOutputConnector.PathMustNotBeNull=Path must be not null
+
+
+
+AlfrescoBfsiOutputConnector.ParametersColon=Parameters:
+AlfrescoBfsiOutputConnector.UsernameEquals=username=
+AlfrescoBfsiOutputConnector.PasswordEquals=password=
+AlfrescoBfsiOutputConnector.ProtocolEquals=protocol=
+AlfrescoBfsiOutputConnector.ServerEquals=server=
+AlfrescoBfsiOutputConnector.PortEquals=port=
+AlfrescoBfsiOutputConnector.PathEquals=path=
+
+
+
+
diff --git a/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration.js b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration.js
new file mode 100644
index 0000000..2ff18ea
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration.js
@@ -0,0 +1,77 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<script type="text/javascript">
+<!--
+function checkConfig()
+{
+  return true;
+}
+ 
+function checkConfigForSave()
+{
+  if (editconnection.username.value == "")
+  {
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.TheUsernameMustNotBeNull'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.username.focus();
+    return false;
+  }
+  if (editconnection.password.value == "")
+  {
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ThePasswordMustNotBeNull'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.password.focus();
+    return false;
+  }
+
+  if (editconnection.server.value ==""){
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ServerNameMustNotBeNull'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.server.focus();
+    return false;
+  }
+  if(editconnection.server.value.indexOf('/')!=-1) {
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ServerNameCantContainSlash'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.server.focus();
+    return false;
+  }
+  if (editconnection.port.value == "")
+  {
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ThePortMustNotBeNull'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.port.focus();
+    return false;
+  }
+  if (!isInteger(editconnection.port.value)){
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.TheServerPortMustBeValidInteger'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.port.focus();
+    return false;
+  }
+  if(editconnection.path.value == ""){
+    alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PathMustNotBeNull'))");
+    SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.Server'))");
+    editconnection.path.focus();
+    return false;
+  }
+
+  return true;
+}
+//-->
+</script>
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration_Server.html b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration_Server.html
new file mode 100644
index 0000000..04ea0a7
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/editConfiguration_Server.html
@@ -0,0 +1,139 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+#if($TABNAME == $ResourceBundle.getString('AlfrescoBfsiOutputConnector.BfsiParametersTab'))
+
+<table class="displaytable">
+  <tr>
+    <td class="separator" colspan="2">
+      <hr />
+    </td>
+  </tr>
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ProtocolColon'))
+      </nobr>
+    </td>
+    <td class="value">
+      <select id="protocol" name="protocol">
+#if($PROTOCOL== "ftp")
+        <option value="ftp" selected="selected">Ftp</option>
+        <option value="local">local file system</option>
+        <option value="s3">S3</option>
+#elseif($PROTOCOL== "local")
+        <option value="ftp">Ftp</option>
+        <option value="local" selected="selected">local file system</option>
+        <option value="s3">S3</option>
+#elseif($PROTOCOL== "s3")
+        <option value="ftp">Ftp</option>
+        <option value="local" >local file system</option>
+        <option value="s3" selected="selected">S3</option>
+#else
+          <option value="ftp">Ftp</option>
+          <option value="local" >local file system</option>
+          <option value="s3">S3</option>
+#end
+      </select>
+    </td>
+  </tr>
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.UsernameColon'))
+      </nobr>
+    </td>
+    <td class="value">
+      <input type="text" id="username" name="username" value="$Encoder.attributeEscape($USERNAME)" />
+    </td>
+  </tr>
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PasswordColon'))
+      </nobr>
+    </td>
+    <td class="value">
+      <input type="password" id="password" name="password" value="$Encoder.attributeEscape($PASSWORD)" />
+    </td>
+  </tr>
+
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ServerColon'))
+      </nobr>
+    </td>
+    <td class="value">
+        <input id="server" name="server" type="text" size="32" value="$Encoder.attributeEscape($SERVER)"/>
+    </td>
+  </tr>
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PortColon'))
+      </nobr>
+    </td>
+    <td class="value">
+        <input id="port" name="port" type="text" size="5" value="$Encoder.attributeEscape($PORT)" />
+    </td>
+  </tr>
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PathColon'))
+      </nobr>
+    </td>
+    <td class="value">
+        <input id="path" name="path" type="text" size="32" value="$Encoder.attributeEscape($PATH)" />
+    </td>
+  </tr>
+
+  <tr>
+    <td class="description">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.CreateTimestampTreeColon'))
+      </nobr>
+    </td> 
+    <td class="value">
+
+         <select id="createTimestampTree" name="createTimestampTree">
+#if($CREATETIMESTAMPTREE == "true")
+        <option value="false">Disabled</option>
+        <option value="true" selected="selected">Enabled</option>
+#else
+        <option value="false" selected="selected">Disabled</option>
+        <option value="true">Enabled</option>
+#end
+      </select>
+    </td>
+  </tr>
+
+</table>
+
+#else
+
+<input type="hidden" name="username" value="$Encoder.attributeEscape($USERNAME)" />
+<input type="hidden" name="password" value="$Encoder.attributeEscape($PASSWORD)" />
+<input type="hidden" name="protocol" value="$Encoder.attributeEscape($PROTOCOL)" />
+<input type="hidden" name="server" value="$Encoder.attributeEscape($SERVER)" />
+<input type="hidden" name="port" value="$Encoder.attributeEscape($PORT)" />
+<input type="hidden" name="path" value="$Encoder.attributeEscape($PATH)" />
+<input type="hidden" name="createTimestampTree" value="$Encoder.attributeEscape($CREATETIMESTAMPTREE)"/>
+
+
+#end
diff --git a/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/viewConfiguration.html b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/viewConfiguration.html
new file mode 100644
index 0000000..31bb6ab
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/main/resources/org/apache/manifoldcf/agents/output/bfsioutput/viewConfiguration.html
@@ -0,0 +1,57 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<table class="displaytable">
+  <tr>
+    <td class="description" colspan="1">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ParametersColon'))
+      </nobr>
+    </td>
+    <td class="value" colspan="3">
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.UsernameEquals'))$Encoder.bodyEscape($USERNAME)
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PasswordEquals'))********
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ProtocolEquals'))$Encoder.bodyEscape($PROTOCOL)
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.ServerEquals'))$Encoder.bodyEscape($SERVER)
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PortEquals'))$Encoder.bodyEscape($PORT)
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.PathEquals'))$Encoder.bodyEscape($PATH)
+      </nobr>
+      <br />
+      <nobr>
+        $Encoder.bodyEscape($ResourceBundle.getString('AlfrescoBfsiOutputConnector.CreateTimestampTreeEquals'))$Encoder.bodyEscape($CREATETIMESTAMPTREE)
+      </nobr>
+      <br />
+    </td>
+  </tr>
+</table>
+
diff --git a/connectors/alfresco-bfsi/connector/src/test/resources/authorities.sample.json b/connectors/alfresco-bfsi/connector/src/test/resources/authorities.sample.json
new file mode 100644
index 0000000..5d33bcb
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/test/resources/authorities.sample.json
@@ -0,0 +1,20 @@
+{
+    "username" : "admin",
+    "authorities" : [
+    "GROUP_ALFRESCO_ADMINISTRATORS"
+    ,
+    "GROUP_EMAIL_CONTRIBUTORS"
+    ,
+    "GROUP_EVERYONE"
+    ,
+    "GROUP_site_konner"
+    ,
+    "GROUP_site_konner_SiteManager"
+    ,
+    "GROUP_site_swsdp"
+    ,
+    "GROUP_site_swsdp_SiteManager"
+    ,
+    "ROLE_ADMINISTRATOR"
+    ]
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/test/resources/metadata.sample.json b/connectors/alfresco-bfsi/connector/src/test/resources/metadata.sample.json
new file mode 100644
index 0000000..961ae12
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/test/resources/metadata.sample.json
@@ -0,0 +1,15 @@
+{
+	"path": "A/B/C",
+	"readableAuthorities": [ "1", "2", "3" ],
+	"properties": [ {
+			"name": "pippo",
+			"value": "pluto",
+			"type": "java.lang.String"
+		}, {
+			"name": "foo",
+			"value": "5",
+			"type": "java.lang.Double"
+		}
+	],
+	"aspects": [ "a", "b", "c" ]
+}
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/connector/src/test/resources/multi.authorities.sample.json b/connectors/alfresco-bfsi/connector/src/test/resources/multi.authorities.sample.json
new file mode 100644
index 0000000..1b90b42
--- /dev/null
+++ b/connectors/alfresco-bfsi/connector/src/test/resources/multi.authorities.sample.json
@@ -0,0 +1,24 @@
+[
+    {
+        username:"guest",
+        authorities:[
+            "ROLE_GUEST"
+        ]
+    },
+    {
+        username:"abeecher",
+        authorities:[
+            "GROUP_EVERYONE",
+            "GROUP_site_swsdp",
+            "GROUP_site_swsdp_SiteCollaborator"
+        ]
+    },
+    {
+        username:"mjackson",
+        authorities:[
+            "GROUP_EVERYONE",
+            "GROUP_site_swsdp",
+            "GROUP_site_swsdp_SiteManager"
+        ]
+    }
+]
\ No newline at end of file
diff --git a/connectors/alfresco-bfsi/pom.xml b/connectors/alfresco-bfsi/pom.xml
new file mode 100644
index 0000000..ece30a8
--- /dev/null
+++ b/connectors/alfresco-bfsi/pom.xml
@@ -0,0 +1,439 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <groupId>org.apache.manifoldcf</groupId>
+        <artifactId>mcf-connectors</artifactId>
+        <version>2.8-SNAPSHOT</version>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+
+    <properties>
+        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+    </properties>
+
+    <developers>
+        <developer>
+            <name>Luis Cabaceira</name>
+            <organization>Alfresco</organization>
+            <organizationUrl>http://www.alfresco.com</organizationUrl>
+            <url>http://www.alfresco.com</url>
+        </developer>
+    </developers>
+
+    <artifactId>mcf-alfresco-bfsi-connector</artifactId>
+    <name>ManifoldCF - Connectors - Alfresco Bulk File System Import Output Connector</name>
+
+
+    <build>
+        <defaultGoal>integration-test</defaultGoal>
+        <sourceDirectory>${basedir}/connector/src/main/java</sourceDirectory>
+        <testSourceDirectory>${basedir}/connector/src/test/java</testSourceDirectory>
+        <resources>
+            <resource>
+                <directory>${basedir}/connector/src/main/native2ascii</directory>
+                <includes>
+                    <include>**/*.properties</include>
+                </includes>
+            </resource>
+            <resource>
+                <directory>${basedir}/connector/src/main/resources</directory>
+                <includes>
+                    <include>**/*.html</include>
+                    <include>**/*.js</include>
+                </includes>
+            </resource>
+        </resources>
+        <testResources>
+            <testResource>
+                <directory>${basedir}/connector/src/test/resources</directory>
+            </testResource>
+        </testResources>
+
+        <plugins>
+
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>native2ascii-maven-plugin</artifactId>
+                <version>1.0-beta-1</version>
+                <configuration>
+                    <workDir>target/classes</workDir>
+                </configuration>
+                <executions>
+                    <execution>
+                        <id>native2ascii-utf8</id>
+                        <goals>
+                            <goal>native2ascii</goal>
+                        </goals>
+                        <configuration>
+                            <encoding>UTF8</encoding>
+                            <includes>
+                                <include>**/*.properties</include>
+                            </includes>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+
+            <!-- Test plugin configuration -->
+            <plugin>
+                <artifactId>maven-dependency-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>copy-war</id>
+                        <phase>generate-resources</phase>
+                        <goals>
+                            <goal>copy</goal>
+                        </goals>
+                        <configuration>
+                            <outputDirectory>target/dependency</outputDirectory>
+                            <artifactItems>
+                                <artifactItem>
+                                    <groupId>${project.groupId}</groupId>
+                                    <artifactId>mcf-api-service</artifactId>
+                                    <version>${project.version}</version>
+                                    <type>war</type>
+                                    <overWrite>false</overWrite>
+                                    <destFileName>mcf-api-service.war</destFileName>
+                                </artifactItem>
+                                <artifactItem>
+                                    <groupId>${project.groupId}</groupId>
+                                    <artifactId>mcf-authority-service</artifactId>
+                                    <version>${project.version}</version>
+                                    <type>war</type>
+                                    <overWrite>false</overWrite>
+                                    <destFileName>mcf-authority-service.war</destFileName>
+                                </artifactItem>
+                                <artifactItem>
+                                    <groupId>${project.groupId}</groupId>
+                                    <artifactId>mcf-crawler-ui</artifactId>
+                                    <version>${project.version}</version>
+                                    <type>war</type>
+                                    <overWrite>false</overWrite>
+                                    <destFileName>mcf-crawler-ui.war</destFileName>
+                                </artifactItem>
+                                <artifactItem>
+                                    <groupId>org.apache.chemistry.opencmis</groupId>
+                                    <artifactId>chemistry-opencmis-server-inmemory</artifactId>
+                                    <version>1.1.0</version>
+                                    <type>war</type>
+                                    <overWrite>false</overWrite>
+                                    <destFileName>chemistry-opencmis-server-inmemory.war</destFileName>
+                                </artifactItem>
+                            </artifactItems>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <configuration>
+                    <excludes>
+                        <exclude>**/*Postgresql*.java</exclude>
+                        <exclude>**/*MySQL*.java</exclude>
+                    </excludes>
+                    <forkCount>1</forkCount>
+                    <reuseForks>false</reuseForks>
+                    <workingDirectory>target/test-output</workingDirectory>
+                </configuration>
+            </plugin>
+
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-failsafe-plugin</artifactId>
+                <version>2.18.1</version>
+                <configuration>
+                    <skipTests>${skipITs}</skipTests>
+                    <systemPropertyVariables>
+                        <crawlerWarPath>../dependency/mcf-crawler-ui.war</crawlerWarPath>
+                        <authorityserviceWarPath>../dependency/mcf-authority-service.war</authorityserviceWarPath>
+                        <apiWarPath>../dependency/mcf-api-service.war</apiWarPath>
+                        <openCmisServerWarPath>../dependency/chemistry-opencmis-server-inmemory.war</openCmisServerWarPath>
+                    </systemPropertyVariables>
+                    <excludes>
+                        <exclude>**/*Postgresql*.java</exclude>
+                        <exclude>**/*MySQL*.java</exclude>
+                    </excludes>
+                    <forkCount>1</forkCount>
+                    <reuseForks>false</reuseForks>
+                    <workingDirectory>target/test-output</workingDirectory>
+                </configuration>
+                <executions>
+                    <execution>
+                        <id>integration-test</id>
+                        <goals>
+                            <goal>integration-test</goal>
+                        </goals>
+                    </execution>
+                    <execution>
+                        <id>verify</id>
+                        <goals>
+                            <goal>verify</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+
+        </plugins>
+        <pluginManagement>
+            <plugins>
+                <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
+                <plugin>
+                    <groupId>org.eclipse.m2e</groupId>
+                    <artifactId>lifecycle-mapping</artifactId>
+                    <version>1.0.0</version>
+                    <configuration>
+                        <lifecycleMappingMetadata>
+                            <pluginExecutions>
+                                <pluginExecution>
+                                    <pluginExecutionFilter>
+                                        <groupId>org.codehaus.mojo</groupId>
+                                        <artifactId>
+                                            native2ascii-maven-plugin
+                                        </artifactId>
+                                        <versionRange>
+                                            [1.0-beta-1,)
+                                        </versionRange>
+                                        <goals>
+                                            <goal>native2ascii</goal>
+                                        </goals>
+                                    </pluginExecutionFilter>
+                                    <action>
+                                        <ignore></ignore>
+                                    </action>
+                                </pluginExecution>
+                            </pluginExecutions>
+                        </lifecycleMappingMetadata>
+                    </configuration>
+                </plugin>
+            </plugins>
+        </pluginManagement>
+    </build>
+
+    <dependencies>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-core</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-connector-common</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-agents</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-pull-agent</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-ui-core</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.chemistry.opencmis</groupId>
+            <artifactId>chemistry-opencmis-client-impl</artifactId>
+            <version>1.1.0</version>
+        </dependency>
+        <dependency>
+            <groupId>commons-lang</groupId>
+            <artifactId>commons-lang</artifactId>
+            <version>2.6</version>
+        </dependency>
+        <dependency>
+            <groupId>commons-io</groupId>
+            <artifactId>commons-io</artifactId>
+            <version>${commons-io.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>joda-time</groupId>
+            <artifactId>joda-time</artifactId>
+            <version>2.8.1</version>
+        </dependency>
+
+        <!-- Test scope -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>${junit.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-core</artifactId>
+            <version>${project.version}</version>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-agents</artifactId>
+            <version>${project.version}</version>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-pull-agent</artifactId>
+            <version>${project.version}</version>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.chemistry.opencmis</groupId>
+            <artifactId>chemistry-opencmis-server-inmemory</artifactId>
+            <version>1.1.0</version>
+            <type>war</type>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>postgresql</groupId>
+            <artifactId>postgresql</artifactId>
+            <version>${postgresql.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.hsqldb</groupId>
+            <artifactId>hsqldb</artifactId>
+            <version>${hsqldb.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>mysql</groupId>
+            <artifactId>mysql-connector-java</artifactId>
+            <version>${mysql.version}</version>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-api-service</artifactId>
+            <version>${project.version}</version>
+            <type>war</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-authority-service</artifactId>
+            <version>${project.version}</version>
+            <type>war</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>mcf-crawler-ui</artifactId>
+            <version>${project.version}</version>
+            <type>war</type>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-server</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-util</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-webapp</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-servlet</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-http</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-io</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-security</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-continuation</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.eclipse.jetty</groupId>
+            <artifactId>jetty-xml</artifactId>
+            <version>${jetty.version}</version>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.mortbay.jetty</groupId>
+            <artifactId>jsp-api-2.1-glassfish</artifactId>
+            <version>${glassfish.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.mortbay.jetty</groupId>
+            <artifactId>jsp-2.1-glassfish</artifactId>
+            <version>${glassfish.version}</version>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-simple</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>test</scope>
+        </dependency>
+
+    </dependencies>
+</project>
diff --git a/connectors/alfresco-bfsi/test-materials-proprietary/README.txt b/connectors/alfresco-bfsi/test-materials-proprietary/README.txt
new file mode 100644
index 0000000..1e42d5d
--- /dev/null
+++ b/connectors/alfresco-bfsi/test-materials-proprietary/README.txt
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+To test this connector, copy the alfresco.war, including h2 support, into this
+directory, and use the "ant test" target for the standard ant build.  You can read more
+about the process on the "how-to-build-and-deploy.html" documentation page.
diff --git a/connectors/alfresco-webscript/pom.xml b/connectors/alfresco-webscript/pom.xml
index fef8d6a..958effa 100644
--- a/connectors/alfresco-webscript/pom.xml
+++ b/connectors/alfresco-webscript/pom.xml
@@ -253,7 +253,7 @@
         <dependency>
             <groupId>org.apache.chemistry.opencmis</groupId>
             <artifactId>chemistry-opencmis-client-impl</artifactId>
-            <version>0.13.0</version>
+            <version>1.1.0</version>
             <scope>test</scope>
         </dependency>
         <dependency>
diff --git a/connectors/cmis/build.xml b/connectors/cmis/build.xml
index 85d67e8..f496ce7 100644
--- a/connectors/cmis/build.xml
+++ b/connectors/cmis/build.xml
@@ -30,7 +30,7 @@
 
     <import file="${mcf-dist}/connector-build.xml"/>
     
-    <property name="chemistry.version" value="0.13.0"/>
+    <property name="chemistry.version" value="1.1.0"/>
     
     <target name="download-dependencies">
         <property name="chemistry-package" value="org/apache/chemistry/opencmis"/>
diff --git a/connectors/cmis/pom.xml b/connectors/cmis/pom.xml
index ce2f2c6..77a2728 100644
--- a/connectors/cmis/pom.xml
+++ b/connectors/cmis/pom.xml
@@ -131,7 +131,7 @@
                 <artifactItem>
                   <groupId>org.apache.chemistry.opencmis</groupId>
                   <artifactId>chemistry-opencmis-server-inmemory</artifactId>
-                  <version>0.13.0</version>
+                  <version>1.1.0</version>
                   <type>war</type>
                   <overWrite>false</overWrite>
                   <destFileName>chemistry-opencmis-server-inmemory.war</destFileName>
@@ -257,7 +257,7 @@
     <dependency>
         <groupId>org.apache.chemistry.opencmis</groupId>
         <artifactId>chemistry-opencmis-client-impl</artifactId>
-        <version>0.13.0</version>
+        <version>1.1.0</version>
      </dependency>
      <dependency>
         <groupId>commons-lang</groupId>
@@ -307,7 +307,7 @@
     <dependency>
       <groupId>org.apache.chemistry.opencmis</groupId>
       <artifactId>chemistry-opencmis-server-inmemory</artifactId>
-      <version>0.13.0</version>
+      <version>1.1.0</version>
       <type>war</type>
       <scope>test</scope>
     </dependency>
diff --git a/connectors/pom.xml b/connectors/pom.xml
index 4a19f0d..3bfa260 100644
--- a/connectors/pom.xml
+++ b/connectors/pom.xml
@@ -72,6 +72,7 @@
     <module>opennlp</module>
     <module>nuxeo</module>
     <module>contentlimiter</module>
+    <module>alfresco-bfsi</module>
   </modules>
 
 </project>