[
https://issues.apache.org/jira/browse/CXF-4324?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Kulp updated CXF-4324:
-----------------------------
Component/s: JAX-RS
> UriInfo uninjectable
> --------------------
>
> Key: CXF-4324
> URL: https://issues.apache.org/jira/browse/CXF-4324
> Project: CXF
> Issue Type: Bug
> Components: JAX-RS
> Reporter: Chris Eineke
> Labels: cxf, dependency-injection, dozer, spring, uriinfo
> Attachments: uriinfofail.zip
>
>
> Spring v3.1.1
> CXF v2.5.3
> Dozer v5.3.2
> (see attached project for further versioning details)
> I'm using CXF 2.5.3 and Spring 3.1.1.RELEASE with dozer 5.3.2.
> My restful service code maps domain objects to transfer objects, but for the
> life of me I cannot get UriInfo injected into my dozer custom mappers.
> The restful services are request-scoped and produced by several
> RequestScopeResourceFactoryS. I'm using CGLIB as the proxy implementation. My
> dozer mappers are defined as singletons, same thing for the dozer bean
> itself.
> I've tried the following:
> 1. @Autowire-annotating a UriInfo instance variable => null.
> 2. @Context-annotating a UriInfo instance variable => null.
> 3. Written a UriInfoInjectable interface { @Context public void
> setUriInfo(UriInfo value); } and implemented in the service => setter is
> never called => null.
> 4. Tried writing an CXF interceptor that loaded UriInfo into a holder bean
> trying to intercept in several different phases and using the three last
> approaches => null.
> I attached a sample project that exhibits the problem.
> 1. mvn clean tomcat:run
> 2. http://localhost:8080/uriinfofail/
> Note the TRACE messages saying that uriInfo is null.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)