You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by Sergey Beryozkin <sb...@gmail.com> on 2015/06/01 22:06:05 UTC

Re: Performance Enhancement for CXF jaxrs

Hi Iris

Thanks for initiating this thread, lets start with reviewing what can we 
do for optimizing the resource method selection.

Which composite key you propose for mapping a given request to a given 
resource method ?

Request URI + HTTP verb + ?

I think it will probably not work with sub resources (though we can 
discuss it further), but perhaps we can offer some optional optimization 
for simpler cases...

Thanks, Sergey
On 26/05/15 07:58, iris ding wrote:
> HI Guys,
>
> Currently CXF will find the target resource method for every jaxrs request.
> If user send multiple repeated request, this will cause big impact for
> performance.  Instead, we can cache the resource method found in the first
> request and get the resource method from cache directly for subsequent
> request.
>
>
> Provider matching is under the same situation as well. We can provide a
> cache for matched provider to save effort.
>
>
> What do you think of this problem? Can we add such support in CXF?
>
>
> Thanks & Best Regards,
>
> Iris Ding
>
>
>
> --
> View this message in context: http://cxf.547215.n5.nabble.com/Performance-Enhancement-for-CXF-jaxrs-tp5757703.html
> Sent from the cxf-dev mailing list archive at Nabble.com.
>


Re: Performance Enhancement for CXF jaxrs

Posted by Sergey Beryozkin <sb...@gmail.com>.
Hi

I guess a single URI is sufficient, however I don't think it can be a 
request URI but has to be a UriBuilder produced URI based on Path 
annotations.

Consider @Path("{id}")

a method annotated with such Path should handle /1, /2, etc

Sergey
On 02/06/15 14:57, iris ding wrote:
> Hi Sergy,
>
> How about using:
> message.get(Message.BASE_PATH) + ":" + rawPath + ":" + httpMethod + ":" +
> requestContentType + ":" + acceptTypes;
>
>
> I have a proposed solution for this and will open a jira for this. Let's
> discuss the implementation details in it.
>
> Thanks & Best Regards,
>
> Iris Ding
>
>
>
> --
> View this message in context: http://cxf.547215.n5.nabble.com/Performance-Enhancement-for-CXF-jaxrs-tp5757703p5757878.html
> Sent from the cxf-dev mailing list archive at Nabble.com.
>


-- 
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com

Re: Performance Enhancement for CXF jaxrs

Posted by iris ding <ir...@gmail.com>.
Hi Sergy,

How about using:
message.get(Message.BASE_PATH) + ":" + rawPath + ":" + httpMethod + ":" +
requestContentType + ":" + acceptTypes;


I have a proposed solution for this and will open a jira for this. Let's
discuss the implementation details in it.

Thanks & Best Regards,

Iris Ding



--
View this message in context: http://cxf.547215.n5.nabble.com/Performance-Enhancement-for-CXF-jaxrs-tp5757703p5757878.html
Sent from the cxf-dev mailing list archive at Nabble.com.