Author: buildbot
Date: Mon Apr 16 20:20:19 2012
New Revision: 813285
Log:
Production update by buildbot for camel
Modified:
websites/production/camel/content/book-cookbook.html
websites/production/camel/content/book-in-one-page.html
websites/production/camel/content/cache/main.pageCache
websites/production/camel/content/spring-testing.html
Modified: websites/production/camel/content/book-cookbook.html
==============================================================================
--- websites/production/camel/content/book-cookbook.html (original)
+++ websites/production/camel/content/book-cookbook.html Mon Apr 16 20:20:19 2012
@@ -2132,8 +2132,7 @@ Override when using <a shape="rect" href
<p>org.apache.camel.test.CamelSpringTestSupport, org.apache.camel.test.junit4.CamelSpringTestSupport, and org.apache.camel.testng.CamelSpringTestSupport extend their non-Spring aware counterparts (org.apache.camel.test.CamelTestSupport, org.apache.camel.test.junit4.CamelTestSupport, and org.apache.camel.testng.CamelTestSupport) and deliver integration with Spring into your test classes.  Instead of instantiating the CamelContext and routes programmatically, these classes rely on a Spring context to wire the needed components together.  If your test extends one of these classes, you must provide the Spring context by implementing the following method.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
+<pre class="code-java"><span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
</pre>
</div></div>
<p>You are responsible for the instantiation of the Spring context in the method implementation.  All of the features available in the non-Spring aware counterparts from <a shape="rect" href="camel-test.html" title="Camel Test">Camel Test</a> are available in your test.</p>
@@ -2206,8 +2205,7 @@ Override when using <a shape="rect" href
<p>For instance, like this maven folder layout:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-src/test/java/org/apache/camel/spring/patterns/FilterTest.java
+<pre class="code-java">src/test/java/org/apache/camel/spring/patterns/FilterTest.java
src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml
</pre>
</div></div>
@@ -2271,8 +2269,7 @@ src/test/resources/org/apache/camel/spri
<p>You can avoid extending Spring classes by using the SpringJUnit4ClassRunner provided by Spring Test.  This custom JUnit runner means you are free to choose your own class hierarchy while retaining all the capabilities of Spring Test.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(SpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest {
@@ -2301,7 +2298,7 @@ src/test/resources/org/apache/camel/spri
<p>Using org.apache.camel.test.junit4.CamelSpringJUnit4ClassRunner runner with the <b>@RunWith</b> annotation or extending org.apache.camel.testng.AbstractCamelTestNGSpringContextTests provides the full feature set of Spring Test with support for the feature set provided in the CamelTestSupport classes.  A number of Camel specific annotations have been developed in order to provide for declarative manipulation of the Camel context(s) involved in the test.  These annotations free your test classes from having to inherit from the CamelSpringTestSupport classes and also reduce the amount of code required to customize the tests.</p>
<div class="table-wrap">
-<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.  The meth
od must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds
</td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </td><td colspan="
1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
+<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpointsAndSkip<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on
the registration of the mock endpoints.  This annotation will also skip sending the message to matched endpoints as well.<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint.  The original endpoint is not invoked.<br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.
  The method must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceT
d"> 10 seconds </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </t
d><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
</div>
@@ -2309,8 +2306,7 @@ src/test/resources/org/apache/camel/spri
<p>The following example illustrates the use of the <b>@MockEndpoints</b> annotation in order to setup mock endpoints as interceptors on all endpoints using the Camel Log component and the <b>@DisableJmx</b> annotation to enable JMX which is disabled during tests by default.  Note that we still use the <b>@DirtiesContext</b> annotation to ensure that the CamelContext, routes, and mock endpoints are reinitialized between test methods.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(CamelSpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(CamelSpringJUnit4ClassRunner.class)
@ContextConfiguration
@DirtiesContext(classMode = ClassMode.AFTER_EACH_TEST_METHOD)
@MockEndpoints(<span class="code-quote">"log:*"</span>)
@@ -2350,8 +2346,7 @@ src/test/resources/org/apache/camel/spri
<p>If you wish to programmatically add any new assertions to your test you can easily do so with the following. Notice how we use @EndpointInject to inject a Camel endpoint into our code then the <a shape="rect" href="mock.html" title="Mock">Mock</a> API to add an expectation on a specific message.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -2377,8 +2372,7 @@ src/test/resources/org/apache/camel/spri
<p>So you can then process the received message exchanges if you like...</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -2410,8 +2404,7 @@ src/test/resources/org/apache/camel/spri
<p>To send or receive messages you should use the <a shape="rect" href="bean-integration.html" title="Bean Integration">Bean Integration</a> mechanism. For example to send messages inject a ProducerTemplate using the @EndpointInject annotation then call the various send methods on this object to send a message to an endpoint. To consume messages use the @MessageDriven annotation on a method to have the method invoked when a message is received.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">public</span> class Foo {
+<pre class="code-java"><span class="code-keyword">public</span> class Foo {
@EndpointInject(uri=<span class="code-quote">"activemq:foo.bar"</span>)
ProducerTemplate producer;
Modified: websites/production/camel/content/book-in-one-page.html
==============================================================================
--- websites/production/camel/content/book-in-one-page.html (original)
+++ websites/production/camel/content/book-in-one-page.html Mon Apr 16 20:20:19 2012
@@ -3264,8 +3264,7 @@ Override when using <a shape="rect" href
<p>org.apache.camel.test.CamelSpringTestSupport, org.apache.camel.test.junit4.CamelSpringTestSupport, and org.apache.camel.testng.CamelSpringTestSupport extend their non-Spring aware counterparts (org.apache.camel.test.CamelTestSupport, org.apache.camel.test.junit4.CamelTestSupport, and org.apache.camel.testng.CamelTestSupport) and deliver integration with Spring into your test classes.  Instead of instantiating the CamelContext and routes programmatically, these classes rely on a Spring context to wire the needed components together.  If your test extends one of these classes, you must provide the Spring context by implementing the following method.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
+<pre class="code-java"><span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
</pre>
</div></div>
<p>You are responsible for the instantiation of the Spring context in the method implementation.  All of the features available in the non-Spring aware counterparts from <a shape="rect" href="camel-test.html" title="Camel Test">Camel Test</a> are available in your test.</p>
@@ -3338,8 +3337,7 @@ Override when using <a shape="rect" href
<p>For instance, like this maven folder layout:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-src/test/java/org/apache/camel/spring/patterns/FilterTest.java
+<pre class="code-java">src/test/java/org/apache/camel/spring/patterns/FilterTest.java
src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml
</pre>
</div></div>
@@ -3403,8 +3401,7 @@ src/test/resources/org/apache/camel/spri
<p>You can avoid extending Spring classes by using the SpringJUnit4ClassRunner provided by Spring Test.  This custom JUnit runner means you are free to choose your own class hierarchy while retaining all the capabilities of Spring Test.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(SpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest {
@@ -3433,7 +3430,7 @@ src/test/resources/org/apache/camel/spri
<p>Using org.apache.camel.test.junit4.CamelSpringJUnit4ClassRunner runner with the <b>@RunWith</b> annotation or extending org.apache.camel.testng.AbstractCamelTestNGSpringContextTests provides the full feature set of Spring Test with support for the feature set provided in the CamelTestSupport classes.  A number of Camel specific annotations have been developed in order to provide for declarative manipulation of the Camel context(s) involved in the test.  These annotations free your test classes from having to inherit from the CamelSpringTestSupport classes and also reduce the amount of code required to customize the tests.</p>
<div class="table-wrap">
-<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.  The meth
od must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds
</td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </td><td colspan="
1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
+<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpointsAndSkip<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on
the registration of the mock endpoints.  This annotation will also skip sending the message to matched endpoints as well.<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint.  The original endpoint is not invoked.<br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.
  The method must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceT
d"> 10 seconds </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </t
d><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
</div>
@@ -3441,8 +3438,7 @@ src/test/resources/org/apache/camel/spri
<p>The following example illustrates the use of the <b>@MockEndpoints</b> annotation in order to setup mock endpoints as interceptors on all endpoints using the Camel Log component and the <b>@DisableJmx</b> annotation to enable JMX which is disabled during tests by default.  Note that we still use the <b>@DirtiesContext</b> annotation to ensure that the CamelContext, routes, and mock endpoints are reinitialized between test methods.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(CamelSpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(CamelSpringJUnit4ClassRunner.class)
@ContextConfiguration
@DirtiesContext(classMode = ClassMode.AFTER_EACH_TEST_METHOD)
@MockEndpoints(<span class="code-quote">"log:*"</span>)
@@ -3482,8 +3478,7 @@ src/test/resources/org/apache/camel/spri
<p>If you wish to programmatically add any new assertions to your test you can easily do so with the following. Notice how we use @EndpointInject to inject a Camel endpoint into our code then the <a shape="rect" href="mock.html" title="Mock">Mock</a> API to add an expectation on a specific message.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -3509,8 +3504,7 @@ src/test/resources/org/apache/camel/spri
<p>So you can then process the received message exchanges if you like...</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -3542,8 +3536,7 @@ src/test/resources/org/apache/camel/spri
<p>To send or receive messages you should use the <a shape="rect" href="bean-integration.html" title="Bean Integration">Bean Integration</a> mechanism. For example to send messages inject a ProducerTemplate using the @EndpointInject annotation then call the various send methods on this object to send a message to an endpoint. To consume messages use the @MessageDriven annotation on a method to have the method invoked when a message is received.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">public</span> class Foo {
+<pre class="code-java"><span class="code-keyword">public</span> class Foo {
@EndpointInject(uri=<span class="code-quote">"activemq:foo.bar"</span>)
ProducerTemplate producer;
@@ -14355,14 +14348,14 @@ from(<span class="code-quote">"direct:st
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.choice()
.when(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"bar"</span>))
- .to(<span class="code-quote">"seda:b"</span>)
+ .to(<span class="code-quote">"direct:b"</span>)
.when(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"cheese"</span>))
- .to(<span class="code-quote">"seda:c"</span>)
+ .to(<span class="code-quote">"direct:c"</span>)
.otherwise()
- .to(<span class="code-quote">"seda:d"</span>);
+ .to(<span class="code-quote">"direct:d"</span>);
}
};
</pre>
@@ -14536,8 +14529,8 @@ from(<span class="code-quote">"activemq:
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
- .multicast().to(<span class="code-quote">"seda:b"</span>, <span class="code-quote">"seda:c"</span>, <span class="code-quote">"seda:d"</span>);
+ from(<span class="code-quote">"direct:a"</span>)
+ .multicast().to(<span class="code-quote">"direct:b"</span>, <span class="code-quote">"direct:c"</span>, <span class="code-quote">"direct:d"</span>);
}
};
</pre>
@@ -15118,14 +15111,14 @@ from(<span class="code-quote">"activemq:
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.choice()
.when(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"bar"</span>))
- .to(<span class="code-quote">"seda:b"</span>)
+ .to(<span class="code-quote">"direct:b"</span>)
.when(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"cheese"</span>))
- .to(<span class="code-quote">"seda:c"</span>)
+ .to(<span class="code-quote">"direct:c"</span>)
.otherwise()
- .to(<span class="code-quote">"seda:d"</span>);
+ .to(<span class="code-quote">"direct:d"</span>);
}
};
</pre>
@@ -15172,9 +15165,9 @@ from(<span class="code-quote">"activemq:
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.filter(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"bar"</span>))
- .to(<span class="code-quote">"seda:b"</span>);
+ .to(<span class="code-quote">"direct:b"</span>);
}
};
</pre>
@@ -15413,8 +15406,8 @@ You can use the <a shape="rect" href="re
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
- .multicast().to(<span class="code-quote">"seda:b"</span>, <span class="code-quote">"seda:c"</span>, <span class="code-quote">"seda:d"</span>);
+ from(<span class="code-quote">"direct:a"</span>)
+ .multicast().to(<span class="code-quote">"direct:b"</span>, <span class="code-quote">"direct:c"</span>, <span class="code-quote">"direct:d"</span>);
}
};
</pre>
@@ -15445,7 +15438,7 @@ You can use the <a shape="rect" href="re
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.recipientList(header(<span class="code-quote">"foo"</span>));
}
};
@@ -15766,9 +15759,9 @@ from(<span class="code-quote">"direct:c"
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.split(body(<span class="code-object">String</span>.class).tokenize(<span class="code-quote">"\n"</span>))
- .to(<span class="code-quote">"seda:b"</span>);
+ .to(<span class="code-quote">"direct:b"</span>);
}
};
</pre>
@@ -19045,7 +19038,7 @@ from(<span class="code-quote">"jms:MyQue
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.filter(header(<span class="code-quote">"foo"</span>).isEqualTo(<span class="code-quote">"bar"</span>))
.process(myProcessor);
}
@@ -19190,10 +19183,10 @@ On completion Camel will remove the mess
<span class="code-keyword">public</span> void configure() {
errorHandler(deadLetterChannel(<span class="code-quote">"mock:error"</span>));
- from(<span class="code-quote">"seda:a"</span>)
+ from(<span class="code-quote">"direct:a"</span>)
.idempotentConsumer(header(<span class="code-quote">"myMessageId"</span>),
MemoryIdempotentRepository.memoryIdempotentRepository(200))
- .to(<span class="code-quote">"seda:b"</span>);
+ .to(<span class="code-quote">"direct:b"</span>);
}
};
</pre>
Modified: websites/production/camel/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.
Modified: websites/production/camel/content/spring-testing.html
==============================================================================
--- websites/production/camel/content/spring-testing.html (original)
+++ websites/production/camel/content/spring-testing.html Mon Apr 16 20:20:19 2012
@@ -96,8 +96,7 @@
<p>org.apache.camel.test.CamelSpringTestSupport, org.apache.camel.test.junit4.CamelSpringTestSupport, and org.apache.camel.testng.CamelSpringTestSupport extend their non-Spring aware counterparts (org.apache.camel.test.CamelTestSupport, org.apache.camel.test.junit4.CamelTestSupport, and org.apache.camel.testng.CamelTestSupport) and deliver integration with Spring into your test classes.  Instead of instantiating the CamelContext and routes programmatically, these classes rely on a Spring context to wire the needed components together.  If your test extends one of these classes, you must provide the Spring context by implementing the following method.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
+<pre class="code-java"><span class="code-keyword">protected</span> <span class="code-keyword">abstract</span> AbstractApplicationContext createApplicationContext();
</pre>
</div></div>
<p>You are responsible for the instantiation of the Spring context in the method implementation.  All of the features available in the non-Spring aware counterparts from <a shape="rect" href="camel-test.html" title="Camel Test">Camel Test</a> are available in your test.</p>
@@ -170,8 +169,7 @@
<p>For instance, like this maven folder layout:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-src/test/java/org/apache/camel/spring/patterns/FilterTest.java
+<pre class="code-java">src/test/java/org/apache/camel/spring/patterns/FilterTest.java
src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml
</pre>
</div></div>
@@ -235,8 +233,7 @@ src/test/resources/org/apache/camel/spri
<p>You can avoid extending Spring classes by using the SpringJUnit4ClassRunner provided by Spring Test.  This custom JUnit runner means you are free to choose your own class hierarchy while retaining all the capabilities of Spring Test.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(SpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest {
@@ -265,7 +262,7 @@ src/test/resources/org/apache/camel/spri
<p>Using org.apache.camel.test.junit4.CamelSpringJUnit4ClassRunner runner with the <b>@RunWith</b> annotation or extending org.apache.camel.testng.AbstractCamelTestNGSpringContextTests provides the full feature set of Spring Test with support for the feature set provided in the CamelTestSupport classes.  A number of Camel specific annotations have been developed in order to provide for declarative manipulation of the Camel context(s) involved in the test.  These annotations free your test classes from having to inherit from the CamelSpringTestSupport classes and also reduce the amount of code required to customize the tests.</p>
<div class="table-wrap">
-<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.  The meth
od must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds
</td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </td><td colspan="
1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
+<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"> Annotation Class </th><th colspan="1" rowspan="1" class="confluenceTh"> Applies To </th><th colspan="1" rowspan="1" class="confluenceTh"> Description </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavioir If Not Present </th><th colspan="1" rowspan="1" class="confluenceTh"> Default Behavior If Present </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.DisableJmx <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if JMX should be globally disabled in the CamelContexts that are bootstrapped  during the test through the use of Spring Test loaded application contexts. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> JMX is disabled </td><td colspan="1" rows
pan="1" class="confluenceTd"> JMX is disabled <br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ExcludeRoutes <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if certain route builder classes should be excluded from discovery.  Initializes a org.apache.camel.spi.PackageScanClassResolver to exclude a set of given classes from being resolved. Typically this is used at test time to exclude certain routes, which might otherwise be just noisy, from being discovered and initialized. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled and no routes are excluded </td><td colspan="1" rowspan="1" class="confluenceTd"> No routes are excluded </td></tr><tr><td co
lspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.LazyLoadTypeConverters (Deprecated) <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates if the CamelContexts that are bootstrapped during the test through the use of Spring Test loaded application contexts should use lazy loading of type converters. </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td><td colspan="1" rowspan="1" class="confluenceTd"> Type converters are not lazy loaded </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpoints <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd
"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on the registration of the mock endpoints. </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint. </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.MockEndpointsAndSkip<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class </td><td colspan="1" rowspan="1" class="confluenceTd"> Triggers the auto-mocking of endpoints whose URIs match the provided filter.  The default filter is "*" which matches all endpoints.  See org.apache.camel.impl.InterceptSendToMockEndpointStrategy for more details on
the registration of the mock endpoints.  This annotation will also skip sending the message to matched endpoints as well.<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Not enabled<br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> All endpoints are sniffed and recorded in a mock endpoint.  The original endpoint is not invoked.<br clear="none" class="atl-forced-newline"> </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ProvidesBreakpoint <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Method </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates that the annotated method returns an org.apache.camel.spi.Breakpoint for use in the test.  Useful for intercepting traffic to all endpoints or simply for setting a break point in an IDE for debugging.
  The method must be public, static, take no arguments, and return org.apache.camel.spi.Breakpoint. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> N/A </td><td colspan="1" rowspan="1" class="confluenceTd"> The returned Breakpoint is registered in the CamelContext(s) </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.ShutdownTimeout <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates to set the shutdown timeout of all CamelContexts instantiated through the use of Spring Test loaded application contexts.  If no annotation is used, the timeout is automatically reduced to 10 seconds by the test framework. <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceT
d"> 10 seconds </td><td colspan="1" rowspan="1" class="confluenceTd"> 10 seconds </td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"> org.apache.camel.test.spring.UseAdviceWith <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Class <br clear="none" class="atl-forced-newline"> </td><td colspan="1" rowspan="1" class="confluenceTd"> Indicates the use of adviceWith() within the test class.  If a class is annotated with this annotation and UseAdviceWith#value() returns true, any CamelContexts bootstrapped during the test through the use of Spring Test loaded application contexts will not be started automatically.  The test author is responsible for injecting the Camel contexts into the test and executing CamelContext#start() on them at the appropriate time after any advice has been applied to the routes in the CamelContext(s). <br clear="none" class="atl-forced-newline"> </t
d><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td><td colspan="1" rowspan="1" class="confluenceTd"> CamelContexts do not automatically start. </td></tr></tbody></table>
</div>
@@ -273,8 +270,7 @@ src/test/resources/org/apache/camel/spri
<p>The following example illustrates the use of the <b>@MockEndpoints</b> annotation in order to setup mock endpoints as interceptors on all endpoints using the Camel Log component and the <b>@DisableJmx</b> annotation to enable JMX which is disabled during tests by default.  Note that we still use the <b>@DirtiesContext</b> annotation to ensure that the CamelContext, routes, and mock endpoints are reinitialized between test methods.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@RunWith(CamelSpringJUnit4ClassRunner.class)
+<pre class="code-java">@RunWith(CamelSpringJUnit4ClassRunner.class)
@ContextConfiguration
@DirtiesContext(classMode = ClassMode.AFTER_EACH_TEST_METHOD)
@MockEndpoints(<span class="code-quote">"log:*"</span>)
@@ -314,8 +310,7 @@ src/test/resources/org/apache/camel/spri
<p>If you wish to programmatically add any new assertions to your test you can easily do so with the following. Notice how we use @EndpointInject to inject a Camel endpoint into our code then the <a shape="rect" href="mock.html" title="Mock">Mock</a> API to add an expectation on a specific message.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -341,8 +336,7 @@ src/test/resources/org/apache/camel/spri
<p>So you can then process the received message exchanges if you like...</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-@ContextConfiguration
+<pre class="code-java">@ContextConfiguration
<span class="code-keyword">public</span> class MyCamelTest <span class="code-keyword">extends</span> AbstractJUnit38SpringContextTests {
@Autowired
@@ -374,8 +368,7 @@ src/test/resources/org/apache/camel/spri
<p>To send or receive messages you should use the <a shape="rect" href="bean-integration.html" title="Bean Integration">Bean Integration</a> mechanism. For example to send messages inject a ProducerTemplate using the @EndpointInject annotation then call the various send methods on this object to send a message to an endpoint. To consume messages use the @MessageDriven annotation on a method to have the method invoked when a message is received.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
-<pre class="code-java">
-<span class="code-keyword">public</span> class Foo {
+<pre class="code-java"><span class="code-keyword">public</span> class Foo {
@EndpointInject(uri=<span class="code-quote">"activemq:foo.bar"</span>)
ProducerTemplate producer;
|