Pragalathan  M
Pragalathan M

Reputation: 1781

Migration from CXF 2.7.0 to JAX-RS 2.0 (RestEasy 3.0.1 precisely)

I have a library written using CXF which is used old applications and running in tomcat. I am now using that library for a new application hosted in JBoss AS 7. Hence I am rewriting the CXF specific code to JAX-RS 2.0 SPI compliant so that both old and new applications can use this library.

1.in CXF there is a way to set the receive timeout and connection timeout as follows

((HTTPConduit) config.getConduit()).getClient().setReceiveTimeout(timeout);

How do I port this to jaxrs2.0

2.The default implementation of resteasy 3.0.1 uses apache httpclient-4 (if i am not wrong) and singleclientconnmanager which causes connection busy error if not used properly. Is it good for production LIBRARY use (as you may not have control over client using this library)? Or how do I change it to work like CXF where I dont have to worry about the connections

Upvotes: 1

Views: 426

Answers (1)

constantlearner
constantlearner

Reputation: 5247

Please have a look at this Blog it may help you there are also few code snippets if u go to git hub please have a look.If not i can answer you showed some pointers

Upvotes: 2

Related Questions