Quantcast

Is "jersey-proxy-client" module production ready?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Is "jersey-proxy-client" module production ready?

Fabrizio Cucci
Hi everyone,

a few time ago I discovered the "jersey-proxy-client" module and I think it really comes in handy, especially when working with microservices communicating through REST.

I've been using it for POCs and personal projects but, for some reason, I don't feel confident enough to use it in production scenarios. Let me try to list the main reasons:

1) searching on the web, it SEEMS there are few people actually knowing the module. I personally discovered it by accidentally stepping into this (http://blog.alutam.com/2012/05/04/proxy-client-on-top-of-jax-rs-2-0-client-api/) blog, but there is no information/example at all in the Jersey documentation (besides the module name in the "Table 2.5. Jersey Extensions"). Conversely, almost everyone knows Feign and Retrofit, even though none of them fully support JAX-RS 2.0 annotations.

2) looking at the source code in the Jersey repository, it SEEMS like the code could use some love. There are a couple of comments (e.g. "is this the right thing to do? or should I fail? or ignore the difference?" , "TODO: should at least log some warning here") which gave me the impression the module has not been fully finalized (but again, it may well be a wrong feeling). As a side note, it would be nice to extend it to support at least a simple service discovery mechanism, e.g. exposing another factory which accepts a service discovery strategy in the form of Supplier<WebTarget>.

I would be glad to be hear some feedback on this and, if the module is really production ready, why it is not "advertised" like it should be.

Thanks,
Fabrizio
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Is "jersey-proxy-client" module production ready?

Guy Rouillier
We've used it in a production environment.  We subsequently decided to switch from Jersey to RestEasy, which has a parallel capability.
 
Personally, I would recommend always using a proxy client.  It makes programming to a REST interface as easy as local function calls. You even get proper context assist with most Java IDEs (e.g., Eclipse.) Frankly, I don't understand why anyone would choose to do it any other way.
 
--
Guy Rouillier
 
 
 
------ Original Message ------
From: "Fabrizio Cucci" <[hidden email]>
Sent: 12/14/2016 4:49:05 AM
Subject: [Jersey] Is "jersey-proxy-client" module production ready?
 
Hi everyone,

a few time ago I discovered the "jersey-proxy-client" module and I think it really comes in handy, especially when working with microservices communicating through REST.

I've been using it for POCs and personal projects but, for some reason, I don't feel confident enough to use it in production scenarios. Let me try to list the main reasons:

1) searching on the web, it SEEMS there are few people actually knowing the module. I personally discovered it by accidentally stepping into this (http://blog.alutam.com/2012/05/04/proxy-client-on-top-of-jax-rs-2-0-client-api/) blog, but there is no information/example at all in the Jersey documentation (besides the module name in the "Table 2.5. Jersey Extensions"). Conversely, almost everyone knows Feign and Retrofit, even though none of them fully support JAX-RS 2.0 annotations.

2) looking at the source code in the Jersey repository, it SEEMS like the code could use some love. There are a couple of comments (e.g. "is this the right thing to do? or should I fail? or ignore the difference?" , "TODO: should at least log some warning here") which gave me the impression the module has not been fully finalized (but again, it may well be a wrong feeling). As a side note, it would be nice to extend it to support at least a simple service discovery mechanism, e.g. exposing another factory which accepts a service discovery strategy in the form of Supplier<WebTarget>.

I would be glad to be hear some feedback on this and, if the module is really production ready, why it is not "advertised" like it should be.

Thanks,
Fabrizio

Virus-free. www.avast.com
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Is "jersey-proxy-client" module production ready?

Fabrizio Cucci
We've used it in a production environment. We subsequently decided to switch from Jersey to RestEasy, which has a parallel capability.

This is probably a bit off-topic but, may I ask you why did you switch to RESTEasy at the end? I guess the reason was not something related to the jersey-proxy-client since you didn't mention any problem with that...
 
Frankly, I don't understand why anyone would choose to do it any other way.

This is exactly my point! I'm trying to understand why such an important feature for Jersey is left in the corner.


I hope someone from the Jersey team will shed some light on this.

Thanks,
Fabrizio

On 15 December 2016 at 05:30, Guy Rouillier <[hidden email]> wrote:
We've used it in a production environment.  We subsequently decided to switch from Jersey to RestEasy, which has a parallel capability.
 
Personally, I would recommend always using a proxy client.  It makes programming to a REST interface as easy as local function calls. You even get proper context assist with most Java IDEs (e.g., Eclipse.) Frankly, I don't understand why anyone would choose to do it any other way.
 
--
Guy Rouillier
 
 
 
------ Original Message ------
From: "Fabrizio Cucci" <[hidden email]>
Sent: 12/14/2016 4:49:05 AM
Subject: [Jersey] Is "jersey-proxy-client" module production ready?
 
Hi everyone,

a few time ago I discovered the "jersey-proxy-client" module and I think it really comes in handy, especially when working with microservices communicating through REST.

I've been using it for POCs and personal projects but, for some reason, I don't feel confident enough to use it in production scenarios. Let me try to list the main reasons:

1) searching on the web, it SEEMS there are few people actually knowing the module. I personally discovered it by accidentally stepping into this (http://blog.alutam.com/2012/05/04/proxy-client-on-top-of-jax-rs-2-0-client-api/) blog, but there is no information/example at all in the Jersey documentation (besides the module name in the "Table 2.5. Jersey Extensions"). Conversely, almost everyone knows Feign and Retrofit, even though none of them fully support JAX-RS 2.0 annotations.

2) looking at the source code in the Jersey repository, it SEEMS like the code could use some love. There are a couple of comments (e.g. "is this the right thing to do? or should I fail? or ignore the difference?" , "TODO: should at least log some warning here") which gave me the impression the module has not been fully finalized (but again, it may well be a wrong feeling). As a side note, it would be nice to extend it to support at least a simple service discovery mechanism, e.g. exposing another factory which accepts a service discovery strategy in the form of Supplier<WebTarget>.

I would be glad to be hear some feedback on this and, if the module is really production ready, why it is not "advertised" like it should be.

Thanks,
Fabrizio

Virus-free. www.avast.com

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Is "jersey-proxy-client" module production ready?

Guy Rouillier
We've used it in a production environment. We subsequently decided to switch from Jersey to RestEasy, which has a parallel capability.

This is probably a bit off-topic but, may I ask you why did you switch to RESTEasy at the end? I guess the reason was not something related to the jersey-proxy-client since you didn't mention any problem with that...
 No problems.  We switched to RestEasy simply because we were using RestEasy for other applications (with JBoss, which used RestEasy internally) and wanted a consistent platform for our developers.  The Jersey client works well. 
 
--
Guy Rouillier
 

Virus-free. www.avast.com
Loading...