Hi to all Apache CXF users!, I would kindly like to bring to your attention a particular problem that we are currently being stuck into. We are experimenting with a simple web application, which exposes its functionality via REST. We are using JAX-RS/JSON, no SOAP, no JAX-WS. We deploy our application on top of Tomcat 7, and test both against CXF 2.5.2 and Jersey as REST frameworks.
For calculating our performance measurements, we simply execute REST requests, and in the client we measure the time that the roundtrip takes. Apart from that, on the server side, we measure as well the time that our REST resource consumes, i.e. the method call time. In summary, we have some huge differences between CXF and Jersey - in favor of Jersey being much faster - in the cases where we test against non-existing resources. In all other cases, the numbers we got were really very close for the two REST frameworks. But when testing against non-existing REST paths, the roundtrip time in CXF case is approximately 0.5 seconds, while in the case of Jersey it is 0.01 seconds. We think that this is quite strange, and probably we are not using CXF in its proper configuration. Could you please give us some hints ? Maybe we have to tune and tweak it a little bit, so that we get the best out of it. The server side time, in the case of CXF, is rather small - 0.001 seconds, so we wonder where is that half second spent in ? In our application logic, in the case when the path is not correct, we throw javax.ws.rs.WebApplicationException and with a debugger we saw that this exception is getting caught in CXF, and heavily processed further down the stack. Are you aware of such kind of issues, with CXF handling the 404 situation in a very heavyweight manner ? Maybe it does some thorough processing to try to map the URI to some existing REST resource, I don't know ... maybe performance here could depend on the particular JSON framework that is being used. ... Kindest Regards, Krum.
