Hi Sergey, We are actually using jackson as our json provider not the default jettison. Would I be correct in thinking we cannot register the org.apache.cxf.jaxrs.provider.JAXBElementProvider if we are not using the default provider? And I assume this would have no effect on the interceptor initialisation issue either way? thanksAndy
> Date: Fri, 17 Oct 2014 12:28:50 +0100 > From: [email protected] > To: [email protected] > Subject: Re: Initial call response times > > Hi > On 17/10/14 12:07, Andrew Clark wrote: > > Hi Sergey, > > Thanks for the reply. > > 1) Looking through our logs it seems a lot of the time for the first call > > is spent initialise the interceptor chain. I have seen this thread and it > > seems like this is normal behaviour > > http://cxf.547215.n5.nabble.com/Slow-response-time-only-on-the-first-request-td2268844.html. > > The thread is a few years old though so wondered if there was someway to > > initialise the chain on startup? > > 2) I am a little confused on how I would configure the JAXBElementProvider > > to load on startup. Could you elaborate a little? > See > > http://cxf.apache.org/docs/jax-rs-data-bindings.html#JAX-RSDataBindings-SingleJAXBContextandextrauserclasses > > Setting those properties will instruct the provider to check the > resources classes at the initialization time; > > Cheers, Sergey > > > thanks again > > Andy > > > > > >> Date: Fri, 17 Oct 2014 10:32:52 +0100 > >> From: [email protected] > >> To: [email protected] > >> Subject: Re: Initial call response times > >> > >> Hi > >> On 17/10/14 09:59, Andrew Clark wrote: > >>> > >>> > >>> > >>> Hi, > >>> We have recently started using CXF(2.7.12) to develop REST services. > >>> After testing some of these services we have started to notice that the > >>> initial request has a much larger response time than subsequent request. > >>> After some initial investigation we have been unable to identify what > >>> might be causing the issue and how to fix it. > >>> Any help would be appreciated > >> Can it be just a regular 'warm-up' thing ? > >> If you use CXF on the client side then the initial delay may be due to > >> WebClient initialization. On the server side the initial delay may be > >> caused by a dynamic JAXB context initialization which can be expensive, > >> you can configure JAXBElementProvider to prepare JAXB contexts at the > >> start up... > >> > >> Cheers, Sergey > >> > >>> thanksAndy > >>> > >>> > >> > > > > >
