You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2019/08/20 12:18:35 UTC

[camel] branch master updated (1f6dde3 -> 931772d)

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git.


    from 1f6dde3  Fixed CS for Camel-Undertow
     new 8df5e97  Upgrade Spring Boot to version 2.1.7.RELEASE
     new 688fc09  Upgrade Spring to version 5.1.9.RELEASE
     new 931772d  Regen

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../modules/ROOT/pages/corda-component.adoc        |  4 +--
 .../components/modules/ROOT/pages/test-junit5.adoc | 37 ++++++++++++++++++++--
 .../modules/ROOT/pages/undertow-component.adoc     |  3 +-
 parent/pom.xml                                     |  4 +--
 .../camel-spring-boot-dependencies/pom.xml         |  2 +-
 platforms/spring-boot/spring-boot-dm/pom.xml       |  2 +-
 6 files changed, 43 insertions(+), 9 deletions(-)


[camel] 01/03: Upgrade Spring Boot to version 2.1.7.RELEASE

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 8df5e97980c26fb87e41a2018509b18d2f4b86fb
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Aug 20 12:07:49 2019 +0200

    Upgrade Spring Boot to version 2.1.7.RELEASE
---
 parent/pom.xml                               | 2 +-
 platforms/spring-boot/spring-boot-dm/pom.xml | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/parent/pom.xml b/parent/pom.xml
index bd23435..c4eff5e 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -576,7 +576,7 @@
         <splunk-version>1.6.5.0_1</splunk-version>
         <spring-batch-version>4.1.2.RELEASE</spring-batch-version>
         <spring-batch-bundle-version>4.1.2.RELEASE_1</spring-batch-bundle-version>
-        <spring-boot-version>2.1.6.RELEASE</spring-boot-version>
+        <spring-boot-version>2.1.7.RELEASE</spring-boot-version>
         <spring-cloud-commons-version>2.0.2.RELEASE</spring-cloud-commons-version>
         <spring-cloud-consul-version>2.1.1.RELEASE</spring-cloud-consul-version>
         <spring-cloud-netflix-version>2.0.2.RELEASE</spring-cloud-netflix-version>
diff --git a/platforms/spring-boot/spring-boot-dm/pom.xml b/platforms/spring-boot/spring-boot-dm/pom.xml
index 309bca0..0574a02 100644
--- a/platforms/spring-boot/spring-boot-dm/pom.xml
+++ b/platforms/spring-boot/spring-boot-dm/pom.xml
@@ -41,7 +41,7 @@
 
     <properties>
         <!-- Spring-Boot target version -->
-        <spring-boot-version>2.1.6.RELEASE</spring-boot-version>
+        <spring-boot-version>2.1.7.RELEASE</spring-boot-version>
 
         <!-- The following dependencies should be aligned with the ones in standard camel parent -->
         <!-- Needed by BOM generator-->


[camel] 03/03: Regen

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 931772d2b4eb8042235692b77c4d67583b6fa324
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Aug 20 14:17:52 2019 +0200

    Regen
---
 .../modules/ROOT/pages/corda-component.adoc        |  4 +--
 .../components/modules/ROOT/pages/test-junit5.adoc | 37 ++++++++++++++++++++--
 .../modules/ROOT/pages/undertow-component.adoc     |  3 +-
 .../camel-spring-boot-dependencies/pom.xml         |  2 +-
 4 files changed, 40 insertions(+), 6 deletions(-)

diff --git a/docs/components/modules/ROOT/pages/corda-component.adoc b/docs/components/modules/ROOT/pages/corda-component.adoc
index e439eb4..9eb1a23 100644
--- a/docs/components/modules/ROOT/pages/corda-component.adoc
+++ b/docs/components/modules/ROOT/pages/corda-component.adoc
@@ -140,7 +140,7 @@ Subscribe for new vault state changes:
 
 [source,java]
 ---------------------------------------------------------------------------------------------
-from("corda://localhost:10006?username=user1&password=test?operation=VAULT_TRACK&contractStateClass=#contractStateClass")
+from("corda://localhost:10006?username=user1&password=test&operation=VAULT_TRACK&contractStateClass=#contractStateClass")
     .to("jms:queue:vault");
 ---------------------------------------------------------------------------------------------
 
@@ -149,5 +149,5 @@ Read the node information:
 [source,java]
 --------------------------------------------------------
 from("direct:start")
-    .to("corda://localhost:10006?username=user1&password=test?operation=NODE_INFO");
+    .to("corda://localhost:10006?username=user1&password=test&operation=NODE_INFO");
 --------------------------------------------------------
diff --git a/docs/components/modules/ROOT/pages/test-junit5.adoc b/docs/components/modules/ROOT/pages/test-junit5.adoc
index 6624d90..0ae295f 100644
--- a/docs/components/modules/ROOT/pages/test-junit5.adoc
+++ b/docs/components/modules/ROOT/pages/test-junit5.adoc
@@ -32,10 +32,10 @@ public class SimpleMockTest extends CamelTestSupport {
     }
 
     @Override
-    protected RoutesBuilder createRouteBuilder() throws Exception {
+    protected RoutesBuilder createRouteBuilder() {
         return new RouteBuilder() {
             @Override
-            public void configure() throws Exception {
+            public void configure() {
                 from("direct:start").to("mock:result");
             }
         };
@@ -44,3 +44,36 @@ public class SimpleMockTest extends CamelTestSupport {
 }
 ----
 
+== Migrating Camel Tests from JUnit 4 to JUnit 5
+Find below some hints to help in migrating camel tests from JUnit 4 to JUnit 5.
+
+=== Referencing the Camel Test JUnit5 library in your project
+Projects using `camel-test` would need to use `camel-test-junit5`. For instance, maven users would update their pom.xml file as below:
+----
+<dependency>
+  <groupId>org.apache.camel</groupId>
+  <artifactId>camel-test-junit5</artifactId>
+  <scope>test</scope>
+</dependency>
+----
+
+=== Typical migration steps linked to JUnit 5 support in Camel Test
+* Imports of `org.apache.camel.test.junit4.\*` should be replaced with `org.apache.camel.test.junit5.*`
+* `TestSupport` static methods should be imported where needed, for instance `import static org.apache.camel.test.junit5.TestSupport.assertIsInstanceOf`
+* Usage of the field `CamelTestSupport.log` should be replaced by another logger, for instance `org.slf4j.LoggerFactory.getLogger(MyCamelTest.class);`
+* Usage of the method `CamelTestSupport.createRegistry` should be replaced by `CamelTestSupport.createCamelRegistry()`
+
+=== Typical migration steps linked to JUnit 5 itself
+Once Camel related steps have been performed, there are still typical JUnit 5 migration steps to remember:
+
+* New JUnit 5 assertions should be imported where needed, for instance `import static org.junit.jupiter.api.Assertions.assertEquals`
+* Assertion messages should be moved to the last parameter where needed, for instance `assertEquals("message", 2, 1)` becomes `assertEquals(2, 1, "message")`
+* `org.junit.Test` should be changed in favor of `org.junit.jupiter.api.Test`
+* `org.junit.Ignore` should be changed in favor of `org.junit.jupiter.api.Disabled`
+* `org.junit.Before` should be changed in favor of `org.junit.jupiter.api.BeforeEach`
+* `org.junit.After` should be changed in favor of `org.junit.jupiter.api.AfterEach`
+* `org.junit.BeforeClass` should be changed in favor of `import org.junit.jupiter.api.BeforeAll`
+* `org.junit.AfterClass` should be changed in favor of `import org.junit.jupiter.api.AfterAll`
+* Built-in `assertThat` from third-party assertion libraries should be used. For instance, use `org.hamcrest.MatcherAssert.assertThat` from `java-hamcrest`
+
+Depending on the context, more involved tips might be needed, please check the https://junit.org/junit5/docs/current/user-guide/[JUnit 5 User Guide] then.
\ No newline at end of file
diff --git a/docs/components/modules/ROOT/pages/undertow-component.adoc b/docs/components/modules/ROOT/pages/undertow-component.adoc
index 1a9da73..7a3eee9 100644
--- a/docs/components/modules/ROOT/pages/undertow-component.adoc
+++ b/docs/components/modules/ROOT/pages/undertow-component.adoc
@@ -78,7 +78,7 @@ with the following path and query parameters:
 |===
 
 
-=== Query Parameters (25 parameters):
+=== Query Parameters (26 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
@@ -92,6 +92,7 @@ with the following path and query parameters:
 | *optionsEnabled* (consumer) | Specifies whether to enable HTTP OPTIONS for this Servlet consumer. By default OPTIONS is turned off. | false | boolean
 | *exceptionHandler* (consumer) | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. |  | ExceptionHandler
 | *exchangePattern* (consumer) | Sets the exchange pattern when the consumer creates an exchange. |  | ExchangePattern
+| *handlers* (consumer) | Specifies a comma-delimited set of io.undertow.server.HttpHandler instances in your Registry (such as your Spring ApplicationContext). These handlers are added to the Undertow handler chain (for example, to add security). Important: You can not use different handlers with different Undertow endpoints using the same port number. The handlers is associated to the port number. If you need different handlers, then use different port numbers. |  | String
 | *cookieHandler* (producer) | Configure a cookie handler to maintain a HTTP session |  | CookieHandler
 | *keepAlive* (producer) | Setting to ensure socket is not closed due to inactivity | true | Boolean
 | *lazyStartProducer* (producer) | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
diff --git a/platforms/spring-boot/spring-boot-dm/camel-spring-boot-dependencies/pom.xml b/platforms/spring-boot/spring-boot-dm/camel-spring-boot-dependencies/pom.xml
index 817ff3e..e353bea 100644
--- a/platforms/spring-boot/spring-boot-dm/camel-spring-boot-dependencies/pom.xml
+++ b/platforms/spring-boot/spring-boot-dm/camel-spring-boot-dependencies/pom.xml
@@ -3768,7 +3768,7 @@
       <dependency>
         <groupId>org.knowm.xchange</groupId>
         <artifactId>xchange-core</artifactId>
-        <version>4.3.20</version>
+        <version>4.3.21</version>
       </dependency>
       <dependency>
         <groupId>org.mozilla</groupId>


[camel] 02/03: Upgrade Spring to version 5.1.9.RELEASE

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 688fc09534762d162827c2ff57a732670585cf91
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Aug 20 12:08:07 2019 +0200

    Upgrade Spring to version 5.1.9.RELEASE
---
 parent/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/parent/pom.xml b/parent/pom.xml
index c4eff5e..f224f42 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -590,7 +590,7 @@
         <spring-ldap-bundle-version>2.3.2.RELEASE_1</spring-ldap-bundle-version>
         <spring-version-range>[5,6)</spring-version-range>
         <spring-version>${spring5-version}</spring-version>
-        <spring5-version>5.1.8.RELEASE</spring5-version>
+        <spring5-version>5.1.9.RELEASE</spring5-version>
         <spring-security-version>5.1.4.RELEASE</spring-security-version>
         <spring-security-bundle-version>5.1.3.RELEASE_1</spring-security-bundle-version>
         <spring-ws-version>3.0.7.RELEASE</spring-ws-version>