camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r893853 - in /camel/trunk/examples/camel-example-spring-javaconfig/src: main/java/org/apache/camel/example/spring/javaconfig/ main/resources/META-INF/spring/ test/java/org/apache/camel/example/spring/javaconfig/
Date Fri, 25 Dec 2009 13:42:05 GMT
Author: ningjiang
Date: Fri Dec 25 13:42:04 2009
New Revision: 893853

URL: http://svn.apache.org/viewvc?rev=893853&view=rev
Log:
CAMEL-2312 Upgrade the example of camel-spring-configure to spring3.0.0

Modified:
    camel/trunk/examples/camel-example-spring-javaconfig/src/main/java/org/apache/camel/example/spring/javaconfig/MyRouteConfig.java
    camel/trunk/examples/camel-example-spring-javaconfig/src/main/resources/META-INF/spring/camel-context.xml
    camel/trunk/examples/camel-example-spring-javaconfig/src/test/java/org/apache/camel/example/spring/javaconfig/IntegrationTest.java

Modified: camel/trunk/examples/camel-example-spring-javaconfig/src/main/java/org/apache/camel/example/spring/javaconfig/MyRouteConfig.java
URL: http://svn.apache.org/viewvc/camel/trunk/examples/camel-example-spring-javaconfig/src/main/java/org/apache/camel/example/spring/javaconfig/MyRouteConfig.java?rev=893853&r1=893852&r2=893853&view=diff
==============================================================================
--- camel/trunk/examples/camel-example-spring-javaconfig/src/main/java/org/apache/camel/example/spring/javaconfig/MyRouteConfig.java
(original)
+++ camel/trunk/examples/camel-example-spring-javaconfig/src/main/java/org/apache/camel/example/spring/javaconfig/MyRouteConfig.java
Fri Dec 25 13:42:04 2009
@@ -30,8 +30,8 @@
 import org.apache.camel.spring.javaconfig.SingleRouteCamelConfiguration;
 import org.osgi.framework.BundleContext;
 import org.springframework.beans.factory.InitializingBean;
-import org.springframework.config.java.annotation.Bean;
-import org.springframework.config.java.annotation.Configuration;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
 import org.springframework.osgi.context.BundleContextAware;
 
 //START SNIPPET: RouteConfig

Modified: camel/trunk/examples/camel-example-spring-javaconfig/src/main/resources/META-INF/spring/camel-context.xml
URL: http://svn.apache.org/viewvc/camel/trunk/examples/camel-example-spring-javaconfig/src/main/resources/META-INF/spring/camel-context.xml?rev=893853&r1=893852&r2=893853&view=diff
==============================================================================
--- camel/trunk/examples/camel-example-spring-javaconfig/src/main/resources/META-INF/spring/camel-context.xml
(original)
+++ camel/trunk/examples/camel-example-spring-javaconfig/src/main/resources/META-INF/spring/camel-context.xml
Fri Dec 25 13:42:04 2009
@@ -15,19 +15,21 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-
+<!-- START SNIPPET: ex -->
 <!-- Configures the Camel Context-->
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:context="http://www.springframework.org/schema/context"
        xsi:schemaLocation="
-       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
-  
-  <!-- START SNIPPET: ex -->  
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
+       http://www.springframework.org/schema/context
+           http://www.springframework.org/schema/context/spring-context-3.0.xsd">
+    
   <!-- first, define your individual @Configuration classes as beans -->
   <bean class="org.apache.camel.example.spring.javaconfig.MyRouteConfig"/>
  
-  <!-- be sure to include the JavaConfig bean post-processor -->
-  <bean class="org.springframework.config.java.process.ConfigurationPostProcessor"/>
+  <!-- be sure the configure class to be processed -->
+  <context:annotation-config/>
 
   <!-- END SNIPPET: ex -->
 

Modified: camel/trunk/examples/camel-example-spring-javaconfig/src/test/java/org/apache/camel/example/spring/javaconfig/IntegrationTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/examples/camel-example-spring-javaconfig/src/test/java/org/apache/camel/example/spring/javaconfig/IntegrationTest.java?rev=893853&r1=893852&r2=893853&view=diff
==============================================================================
--- camel/trunk/examples/camel-example-spring-javaconfig/src/test/java/org/apache/camel/example/spring/javaconfig/IntegrationTest.java
(original)
+++ camel/trunk/examples/camel-example-spring-javaconfig/src/test/java/org/apache/camel/example/spring/javaconfig/IntegrationTest.java
Fri Dec 25 13:42:04 2009
@@ -33,7 +33,7 @@
     @Test
     public void testCamelRulesDeployCorrectlyInSpring() throws Exception {
         // let's boot up the Spring application context for 2 seconds to check that it works
OK
-        Main.main("-duration", "2s", "-bp", "org.apache.camel.example.spring.javaconfig");
+        Main.main("-duration", "2s", "-cc", "org.apache.camel.example.spring.javaconfig.MyRouteConfig");
     }
     
     @Test



Mime
View raw message