You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2022/01/01 10:12:15 UTC
[camel-spring-boot] branch main updated: Fixed spring-boot doc as xml-routes is changed to routes-include-pattern
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-spring-boot.git
The following commit(s) were added to refs/heads/main by this push:
new 4042c03 Fixed spring-boot doc as xml-routes is changed to routes-include-pattern
4042c03 is described below
commit 4042c0305328694aa754fd275de0fb6b08aec017
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Sat Jan 1 11:12:02 2022 +0100
Fixed spring-boot doc as xml-routes is changed to routes-include-pattern
---
.../camel/model/rest/springboot/CamelRestTest.java | 3 +-
.../src/main/docs/spring-boot.adoc | 47 ++--------------------
.../SupervisingRouteControllerRestartTest.java | 1 -
3 files changed, 5 insertions(+), 46 deletions(-)
diff --git a/components-starter/camel-rest-starter/src/test/java/org/apache/camel/model/rest/springboot/CamelRestTest.java b/components-starter/camel-rest-starter/src/test/java/org/apache/camel/model/rest/springboot/CamelRestTest.java
index 5dcb15a..db34895 100644
--- a/components-starter/camel-rest-starter/src/test/java/org/apache/camel/model/rest/springboot/CamelRestTest.java
+++ b/components-starter/camel-rest-starter/src/test/java/org/apache/camel/model/rest/springboot/CamelRestTest.java
@@ -49,8 +49,7 @@ import org.springframework.test.annotation.DirtiesContext;
},
properties = {
"debug=false",
- "camel.springboot.xml-rests=false",
- "camel.springboot.xml-routes=false",
+ "camel.springboot.routes-include-pattern=false",
"camel.rest.enabled=true",
"camel.rest.component=dummy-rest",
"camel.rest.host=localhost",
diff --git a/core/camel-spring-boot/src/main/docs/spring-boot.adoc b/core/camel-spring-boot/src/main/docs/spring-boot.adoc
index 5361a39..dfc2d04 100644
--- a/core/camel-spring-boot/src/main/docs/spring-boot.adoc
+++ b/core/camel-spring-boot/src/main/docs/spring-boot.adoc
@@ -331,12 +331,12 @@ this off using the configuration option
[source,properties]
----
# turn off
-camel.springboot.xml-routes = false
-# scan in the com/foo/routes classpath
-camel.springboot.xml-routes = classpath:com/foo/routes/*.xml
+camel.springboot.routes-include-pattern = false
+# scan only in the com/foo/routes classpath
+camel.springboot.routes-include-pattern = classpath:com/foo/routes/*.xml
----
-The XML files should be Camel XML routes (not CamelContext) such as
+The XML files should be Camel XML routes (*not* `<CamelContext>`) such as
[source,xml]
----
@@ -351,45 +351,6 @@ The XML files should be Camel XML routes (not CamelContext) such as
</routes>
----
-== Adding XML Rest-DSL
-
-By default, you can put Camel Rest-DSL XML routes in the classpath under the
-directory camel-rest, which camel-spring-boot will auto-detect and include.
-You can configure the directory name or turn this off using the configuration option
-
-[source,properties]
-----
-# turn off
-camel.springboot.xml-rests = false
-# scan in the com/foo/routes classpath
-camel.springboot.xml-rests = classpath:com/foo/rests/*.xml
-----
-
-The Rest-DSL XML files should be Camel XML rests (not CamelContext) such as
-
-[source,xml]
-----
-<rests xmlns="http://camel.apache.org/schema/spring">
- <rest>
- <post uri="/persons">
- <to uri="direct:postPersons"/>
- </post>
- <get uri="/persons">
- <to uri="direct:getPersons"/>
- </get>
- <get uri="/persons/{personId}">
- <to uri="direct:getPersionId"/>
- </get>
- <put uri="/persons/{personId}">
- <to uri="direct:putPersionId"/>
- </put>
- <delete uri="/persons/{personId}">
- <to uri="direct:deletePersionId"/>
- </delete>
- </rest>
-</rests>
-----
-
== Testing the JUnit 4 way (deprecated)
For testing, Maven users will need to add the following dependencies to their `pom.xml`:
diff --git a/core/camel-spring-boot/src/test/java/org/apache/camel/spring/boot/SupervisingRouteControllerRestartTest.java b/core/camel-spring-boot/src/test/java/org/apache/camel/spring/boot/SupervisingRouteControllerRestartTest.java
index 333a0bd..f0c4bba 100644
--- a/core/camel-spring-boot/src/test/java/org/apache/camel/spring/boot/SupervisingRouteControllerRestartTest.java
+++ b/core/camel-spring-boot/src/test/java/org/apache/camel/spring/boot/SupervisingRouteControllerRestartTest.java
@@ -42,7 +42,6 @@ import static org.awaitility.Awaitility.await;
SupervisingRouteControllerRestartTest.TestConfiguration.class
},
properties = {
- "camel.springboot.xml-routes = false",
"camel.springboot.main-run-controller = true",
"camel.springboot.routeControllerSuperviseEnabled = true",
"camel.springboot.routeControllerInitialDelay = 500",