You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@taverna.apache.org by Vitor Freitas <vi...@gmail.com> on 2014/12/10 13:47:50 UTC

TavernaServer Java Client

Hello everyone,

Currently I am working on a integration with TavernaServer and I need to
consume the REST API on a Java application. A Java Client would be handy
for that task.

I am not really familiar with the Taverna ecosystem, and looking at the
project website I found only informations about a Ruby Client [1]

Looking at Taverna/myGrid repositories at GitHub I found this [2] and this
[3]. The first one seemed a bit outdated (there is a branch with more
recent commits, but I have no idea if it is stable or not), and the second
one looks pretty coupled with the taverna server source code. I mean, I
need a standalone lib.

I even started to create my own client [4], but would save me some time if
there is an official or good/stable Java Client for Taverna Server.

So, is there a java client I could use? :)

[1]
http://www.taverna.org.uk/documentation/taverna-2-x/server/client-side-stuff/
[2] https://github.com/myGrid/t2-server-jar
[3] https://github.com/taverna/taverna-server/tree/2.5/server-client/src
[4] https://github.com/pgcc/taverna-java-client

Kind regards

-- 
Vitor Freitas
vitorfs.com

Re: TavernaServer Java Client

Posted by Robert Haines <rh...@manchester.ac.uk>.
Hi Vitor,

I've been developing the Ruby and Java client libraries for Taverna 
Server over the last few years.

Comments in-line.

On 10/12/2014 13:39, alaninmcr wrote:
> On 10/12/2014 12:47, Vitor Freitas wrote:
>> Hello everyone,
>
> Hello
>
>> Currently I am working on a integration with TavernaServer and I need to
>> consume the REST API on a Java application. A Java Client would be handy
>> for that task.
>>
>> I am not really familiar with the Taverna ecosystem, and looking at the
>> project website I found only informations about a Ruby Client [1]
>>
>> Looking at Taverna/myGrid repositories at GitHub I found this [2] and
>> this
>> [3]. The first one seemed a bit outdated (there is a branch with more
>> recent commits, but I have no idea if it is stable or not), and the
>> second
>> one looks pretty coupled with the taverna server source code. I mean, I
>> need a standalone lib.
>
> I believe that [2] is an attempt to have a Java version of the Ruby Gem.

The Ruby and Java libraries were co-developed for a while as I was using 
both of them in my work. So to begin with I was pretty much developing 
them in parallel and at the same rate.

But for the last couple of years no one has really needed the Java 
version and I have only been updating the Ruby version as a result. So 
the Java version is behind. You are right that there is another branch 
with more recent commits; it's stable enough but just hasn't been tested 
and merged down if memory serves - it still wouldn't be right up to 
date, but it might get you a lot closer.

> I don't think [3] is coupled with the Taverna Server source. It uses
> classes derived from the WADL description of Taverna Server's REST
> interface. I've just done a build of it and it did not pull in the
> Taverna Server code. It may be sensible to make it more obviously separate.
>
> I think [3] is a fairly basic client (apologies to Donal). Whereas [2]
> is intended to more user-friendly. Logically [2] should use [3].

I think the later versions of [2] use similar mechanisms to [3] although 
I think it builds up it's XML parser from the schemas rather than the 
entire WADL. Maybe [2] should use [3] (but [3] didn't exist when [2] was 
originally developed) so there's some work to do there potentially.

[2] was designed to have minimal dependencies that are as standard as 
possible.

>> I even started to create my own client [4], but would save me some
>> time if
>> there is an official or good/stable Java Client for Taverna Server.
>
> I think [3] is far more likely to match the capabilities of the Taverna
> Server.
>
>> So, is there a java client I could use? :)
>
> Donal can confirm / deny my interpretation of [3].
>
> In either case, you are very welcome to contribute code.

Yes! If you could take [2] or [2] + [3] as a base and go from there it 
would be very useful indeed.

Best wishes,
Rob

>> [1]
>> http://www.taverna.org.uk/documentation/taverna-2-x/server/client-side-stuff/
>>
>> [2] https://github.com/myGrid/t2-server-jar
>> [3] https://github.com/taverna/taverna-server/tree/2.5/server-client/src
>> [4] https://github.com/pgcc/taverna-java-client
>>
>> Kind regards
>
> Alan
>
>


-- 
Robert Haines
myGrid Team
School of Computer Science
University of Manchester

Re: TavernaServer Java Client

Posted by "Donal K. Fellows" <do...@manchester.ac.uk>.
On 10/12/2014 13:39, alaninmcr wrote:
> I think [3] is far more likely to match the capabilities of the Taverna
> Server.

Yes, though it's a work in progress right now as I've not yet finished
going through the API and making sure that everything is exposed. My aim
is to get the API exposed by that client library to match the abstract
model API that conceptually exists within the server implementation
(specifically the REST interfaces/POJOs) but not to sugar-coat it to be
nice to use. Were I to use the SOAP interface, the client API would be
near enough the same.

You really don't want to directly use the JAX-RS and JAX-WS client code
that is automatically generated by the basic tooling systems. Especially
for REST, it's *really* unpleasant (whereas the SOAP is just full of
silly IDs that you shouldn't have to care about; we don't rely on
anything like WSRF to hide them).

It's also a WIP because I've been busy with Taverna 3. There's only 24
hours in the day and I have to sleep and eat sometime. :-D

Donal.

Re: TavernaServer Java Client

Posted by alaninmcr <al...@googlemail.com>.
On 10/12/2014 12:47, Vitor Freitas wrote:
> Hello everyone,

Hello

> Currently I am working on a integration with TavernaServer and I need to
> consume the REST API on a Java application. A Java Client would be handy
> for that task.
>
> I am not really familiar with the Taverna ecosystem, and looking at the
> project website I found only informations about a Ruby Client [1]
>
> Looking at Taverna/myGrid repositories at GitHub I found this [2] and this
> [3]. The first one seemed a bit outdated (there is a branch with more
> recent commits, but I have no idea if it is stable or not), and the second
> one looks pretty coupled with the taverna server source code. I mean, I
> need a standalone lib.

I believe that [2] is an attempt to have a Java version of the Ruby Gem.

I don't think [3] is coupled with the Taverna Server source. It uses 
classes derived from the WADL description of Taverna Server's REST 
interface. I've just done a build of it and it did not pull in the 
Taverna Server code. It may be sensible to make it more obviously separate.

I think [3] is a fairly basic client (apologies to Donal). Whereas [2] 
is intended to more user-friendly. Logically [2] should use [3].

> I even started to create my own client [4], but would save me some time if
> there is an official or good/stable Java Client for Taverna Server.

I think [3] is far more likely to match the capabilities of the Taverna 
Server.

> So, is there a java client I could use? :)

Donal can confirm / deny my interpretation of [3].

In either case, you are very welcome to contribute code.

> [1]
> http://www.taverna.org.uk/documentation/taverna-2-x/server/client-side-stuff/
> [2] https://github.com/myGrid/t2-server-jar
> [3] https://github.com/taverna/taverna-server/tree/2.5/server-client/src
> [4] https://github.com/pgcc/taverna-java-client
>
> Kind regards

Alan