cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1519750 - /cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java
Date Tue, 03 Sep 2013 16:33:05 GMT
Author: dkulp
Date: Tue Sep  3 16:33:05 2013
New Revision: 1519750

URL: http://svn.apache.org/r1519750
Log:
Merged revisions 1519747 via  git cherry-pick from
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1519747 | dkulp | 2013-09-03 12:25:26 -0400 (Tue, 03 Sep 2013) | 2 lines

  Don't use the 3.0 only API if the 2.5.x version will work

........

Modified:
    cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java

Modified: cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java?rev=1519750&r1=1519749&r2=1519750&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java
(original)
+++ cxf/branches/2.7.x-fixes/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContextResourceResolver.java
Tue Sep  3 16:33:05 2013
@@ -69,7 +69,10 @@ public class BusApplicationContextResour
         try {
             T resource = null;
             if (resourceName == null) {
-                resource = resourceType.cast(context.getBean(resourceType));
+                String names[] = context.getBeanNamesForType(resourceType);
+                if (names != null && names.length > 0) {
+                    resource = resourceType.cast(context.getBean(names[0], resourceType));
+                }
             } else {
                 resource = resourceType.cast(context.getBean(resourceName, resourceType));
             }



Mime
View raw message