cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1080270 - in /cxf/branches/2.3.x-fixes: ./ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
Date Thu, 10 Mar 2011 16:37:53 GMT
Author: sergeyb
Date: Thu Mar 10 16:37:53 2011
New Revision: 1080270

URL: http://svn.apache.org/viewvc?rev=1080270&view=rev
Log:
Merged revisions 1080267 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1080267 | sergeyb | 2011-03-10 16:35:06 +0000 (Thu, 10 Mar 2011) | 1 line
  
  [CF-3390] Applying a patch on behalf of Ben Noordhuis - thanks
........

Modified:
    cxf/branches/2.3.x-fixes/   (props changed)
    cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java

Propchange: cxf/branches/2.3.x-fixes/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Mar 10 16:37:53 2011
@@ -1 +1 @@
-/cxf/trunk:1079780,1080225
+/cxf/trunk:1079780,1080225,1080267

Propchange: cxf/branches/2.3.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java?rev=1080270&r1=1080269&r2=1080270&view=diff
==============================================================================
--- cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
(original)
+++ cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/utils/JAXRSUtils.java
Thu Mar 10 16:37:53 2011
@@ -187,6 +187,11 @@ public final class JAXRSUtils {
                                      Message message) {
         ClassResourceInfo cri = ori.getClassResourceInfo();
         InjectionUtils.injectContextMethods(requestObject, cri, message);
+        
+        if (cri.isSingleton() 
+            && (!cri.getParameterMethods().isEmpty() || !cri.getParameterFields().isEmpty()))
{
+            LOG.fine("Injecting request parameters into singleton resource is not thread-safe");
+        }
         // Param methods
         MultivaluedMap<String, String> values = 
             (MultivaluedMap<String, String>)message.get(URITemplate.TEMPLATE_PARAMETERS);
@@ -198,9 +203,7 @@ public final class JAXRSUtils {
                                                 message,
                                                 values,
                                                 ori);
-            if (o != null) { 
-                InjectionUtils.injectThroughMethod(requestObject, m, o);
-            }
+            InjectionUtils.injectThroughMethod(requestObject, m, o);
         }
         // Param fields
         for (Field f : cri.getParameterFields()) {
@@ -211,9 +214,7 @@ public final class JAXRSUtils {
                                                 message,
                                                 values,
                                                 ori);
-            if (o != null) { 
-                InjectionUtils.injectFieldValue(f, requestObject, o);
-            }
+            InjectionUtils.injectFieldValue(f, requestObject, o);
         }
         
     }



Mime
View raw message