cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Neal Hu (JIRA)" <>
Subject [jira] [Commented] (CXF-6837) Add cache for MessageBodyReader/Writer
Date Tue, 05 Apr 2016 12:41:25 GMT


Neal Hu commented on CXF-6837:

1. The messagebody's genericType hasn't been used in handleMapper, only check the provider's
genericType. Why it is cache relevant?

3. Let's say ProviderA and ProviderB can read body, but the A is the nearest. First request
A isReadable return false, and B return true. Body is read by B and added in the cache.
Second request both A and B isReadable return true, if we keep single B in the cache, then
match B and return. But B is not the nearest, it is not spec compliant.
4. Sorry, IMHO is?

发自我的 iPhone

> Add cache for MessageBodyReader/Writer
> --------------------------------------
>                 Key: CXF-6837
>                 URL:
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAX-RS
>    Affects Versions: 3.1.5, 3.0.8
>         Environment: windows
>            Reporter: Neal Hu
>             Fix For: 3.2.0
>         Attachments:,,, ProviderFactory.patch,, beans.xml, web.xml
> CXF selects the msgBodyReader/writer in the reader/writer list for every request, which
has big impact to the performance. Jersey also has the cache in org.glassfish.jersey.message.internal.MessageBodyFactory._getMessageBodyReader(...).
I have tried add the cache for CXF in ProviderFactory and been proved that it has improved
7-8% for json requests in JMeter. Please let me know if you'd like me to add the enhancement
for CXF. Thanks. 

This message was sent by Atlassian JIRA

View raw message