Uploader-plus is a plugin for Alfresco that adds a metadata dialog to the standard file uploader. The dialog allows the user to choose a type and enter metadata during the upload of a document.
This brief tutorial explains how to get up and running with the plugin. There are two approaches. One is to use maven and is recommended for testing. The other is to install two amp files in an existing Alfresco installation and is recommended for more permanent deployment.
Downloading the plugin
The plugin is hosted on GitHub and is licensed under the LGPL. The current version is 1.2, which is compatible with Alfresco 4.2.d/e/f and 5.0.a/b/c.
The source zip can be downloaded from https://github.com/softwareloop/uploader-plus/archive/v1.2.zip
The binary distribution is made of two amp files:
Testing the plugin with maven
If you are familiar with Maven, a simple way to test the plugin is to download the source code, then to run these commands:
$ unzip uploader-plus-1.2.zip $ cd uploader-plus-1.2 $ mvn clean package $ cd repo $ mvn install -Pamp-to-war
The first time it runs, maven may require a few minutes to download all the required artifacts. At the end, maven will start a tomcat instance with Alfresco’s repository running on port 8080. Then in another shell:
$ cd uploader-plus-1.2/surf $ mvn install -Pamp-to-war
This will start another tomcat with Share running on port 8081. Now you can connect to http://localhost:8081/share and login as admin/admin.
When you’re done testing, simply kill the two tomcat instances with control-C.
Deploying to an Alfresco installation
If you have an existing installation of Alfresco 4.2.d/e/f or 5.0.a/b/c you can deploy the plugin’s two amp files using this procedure:
- Stop Alfresco if running
- Save the repo amp to
- Save the Share amp to
- Run the amp installation tool:
- Start Alfresco, connect to http://localhost:8080/alfresco/ and use your normal credentials to login.
You can verify that the installation was successful by running:
$ java -jar bin/alfresco-mmt.jar list tomcat/webapps/alfresco.war Module 'uploader-plus-repo' installed in 'tomcat/webapps/alfresco.war' - Title: uploader-plus-repo - Version: 1.2.1502120927 - Install Date: Thu Feb 12 14:44:05 CET 2015 - Description: uploader-plus AMP for Alfresco repository 4.2.x $ java -jar bin/alfresco-mmt.jar list tomcat/webapps/share.war Module 'uploader-plus-surf' installed in 'tomcat/webapps/share.war' - Title: uploader-plus-surf - Version: 1.2.1502120927 - Install Date: Thu Feb 12 14:44:05 CET 2015 - Description: uploader-plus AMP using the Surf framework for Share 4.2.x
More information on installing amps can be found in the community wiki.
In the next post I’ll show how to configure uploader-plus.
If you use Maven and the Maven Alfresco SDK, you can include uploader-plus as a dependency.