Hi,
Recently I followed the tutorials on creating plugins for Taverna 2. I
managed to develop a plugin for uploading large files to a Tomcat server.
The server contains a REST service developed with the Jersey API, where the
post method is used for uploading.The Taverna plugin contains user-side
(client) code which is directly dependent on jersey-client, jersey-core,
jersey-multipart, mimepull. I got the following questions/notes regarding
the plugin:
1: When invoking the service (plugin) the following error occurs:
java.lang.NoClassDefFoundError: javax/ws/rs/core/MultivaluedMap. This seems
to be an indirect dependency used by Jersey. I do not understand why this
class is not available even though the jersey-core package contains this
specific class. Looking at the /home/user/.taverna-2.4.0/repository/ folder
on the client side I am able to see the packages specified in the pom.xml
of the Maven plugin project. I also added the javax-ws.rs-api as an
dependency to the pom.xml but this does not solve the issue.
2: Running the TavernaWorkBenchWithExamplePlugin.java does not give the
NoClassDefFoundError and works perfectly.
3: I developed another plugin for downloading large files successfully.
This service is dependent on jersey-client. I added the jersey-bundle which
contains the jersey-client package as a dependency to the pom.xml. This
dependency seems enough to make the download plugin work.
4:Regarding the previous notes I am not able to solve this dependency issue
for the upload plugin. Am I missing additional dependencies or else why is
Taverna not able to locate the MultiValuedMap class ? The attachment of
this mail contains the pom.xml of the Uploader-activity. I also tried
adding the same dependencies in the pom.xml of the parent project
(Uploader) but to no avail.
Cheers,
Sidney
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.UploadServices</groupId>
<artifactId>Uploader</artifactId>
<version>0.0.1</version>
</parent>
<artifactId>Uploader-activity</artifactId>
<name>UploadServices Taverna activity</name>
<dependencies>
<dependency>
<groupId>net.sf.taverna.t2.core</groupId>
<artifactId>workflowmodel-api</artifactId>
<version>${t2.core.version}</version>
</dependency>
<dependency>
<groupId>net.sf.taverna.t2.activities</groupId>
<artifactId>activity-test-utils</artifactId>
<version>${t2.activities.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-client</artifactId>
<version>1.18</version>
</dependency>
<dependency>
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-core</artifactId>
<version>1.18</version>
</dependency>
<dependency>
<groupId>com.sun.jersey.contribs</groupId>
<artifactId>jersey-multipart</artifactId>
<version>1.18</version>
</dependency>
<dependency>
<groupId>org.jvnet.mimepull</groupId>
<artifactId>mimepull</artifactId>
<version>1.9.4</version>
</dependency>
<dependency>
<groupId>javax.ws.rs</groupId>
<artifactId>javax.ws.rs-api</artifactId>
<version>2.0</version>
</dependency>
</dependencies>
</project>
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
taverna-hackers mailing list
[email protected]
Web site: http://www.taverna.org.uk
Mailing lists: http://www.taverna.org.uk/about/contact-us/
Developers Guide: http://www.taverna.org.uk/developers/