cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sberyozkin <...@git.apache.org>
Subject [GitHub] cxf pull request #253: [CXF-7309] JAX-RS @Context fields throw NPE in OSGI h...
Date Mon, 03 Apr 2017 09:27:15 GMT
Github user sberyozkin commented on a diff in the pull request:

    https://github.com/apache/cxf/pull/253#discussion_r109372768
  
    --- Diff: rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/InjectionUtils.java
---
    @@ -1167,10 +1161,12 @@ public static void injectContextMethods(Object requestObject,
                     if (!cri.isSingleton()) {
                         InjectionUtils.injectThroughMethod(requestObject, method, o, message);
                     } else {
    -                    ThreadLocalProxy<Object> proxy 
    -                        = (ThreadLocalProxy<Object>)cri.getContextSetterProxy(method);
    +                    Object proxy = extractFromSetter(requestObject, method);
    +                    if (!(proxy instanceof ThreadLocalProxy)) {
    --- End diff --
    
    Hi, can you explain please why this check is done, what else can the proxy be, apart from
null or ThreadLocalProxy ? Thanks


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message