views:

76

answers:

1

We have a j2ee/spring/hibernate/tomcat web application already running on production. We are planning to integrate with a 3rd party service(recurly) which provides a ruby client lib. They don't have a java client lib yet. Their service is RESTful and their client is a thin custom wrapper over ActiveResource. I can think of a few ways to do this:

a) jruby?

b) Run a simple ruby xml rpc daemon that calls the actual ruby lib internally ? I believe xml rpc is easy in java.

c) Thrift ?

d) Implement a java lib that talks to their RESTful service(more dev time?)

What would be the quickest way to do this ?

+3  A: 

Given that it's a simple REST API (for example, see http://support.recurly.com/faqs/api/accounts), I'd just replicate the ruby library in Java, it should be simple enough, could get you some karma on recurly guys if you can/will share it back and will avoid any integration or compatibility problems that might arise using an external daemon or jruby or thrift (the more components you add to your code, the more fragile it gets.)

Not necessarily the quickest but the safest route IMO. See here for what to use to implement the library if you deem it necessary.

Vinko Vrsalovic
thnx, I am planning to use jersey to do this.
letronje