camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dmvo...@apache.org
Subject [camel] 01/02: CAMEL-12564: Add guava version property to the samples and fix doc
Date Mon, 18 Jun 2018 15:47:50 GMT
This is an automated email from the ASF dual-hosted git repository.

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

commit 8adb1d185efa13aa3e76c206c56bd252ec393e9b
Author: Dmitry Volodin <dmvolod@gmail.com>
AuthorDate: Mon Jun 18 17:25:54 2018 +0300

    CAMEL-12564: Add guava version property to the samples and fix doc
---
 components/camel-grpc/pom.xml                                | 12 ++++--------
 components/camel-grpc/src/main/docs/grpc-component.adoc      | 10 ++++++++++
 .../hello-camel-grpc-client-kubernetes/pom.xml               |  4 +++-
 .../apache/camel/example/springboot/grpc/CamelGrpcRoute.java |  2 +-
 .../hello-camel-grpc-server-kubernetes/pom.xml               |  8 ++------
 examples/camel-example-grpc-kubernetes/pom.xml               |  2 ++
 .../hello-camel-grpc-client/pom.xml                          |  4 +++-
 .../apache/camel/example/springboot/grpc/CamelGrpcRoute.java |  4 ++--
 .../hello-camel-grpc-server/pom.xml                          | 11 +++++------
 9 files changed, 32 insertions(+), 25 deletions(-)

diff --git a/components/camel-grpc/pom.xml b/components/camel-grpc/pom.xml
index 22f03e2..7e9d113 100644
--- a/components/camel-grpc/pom.xml
+++ b/components/camel-grpc/pom.xml
@@ -36,6 +36,8 @@
   <properties>
     <camel.osgi.export.pkg>org.apache.camel.component.grpc.*;${camel.osgi.version}</camel.osgi.export.pkg>
     <camel.osgi.export.service>org.apache.camel.spi.ComponentResolver;component=grpc</camel.osgi.export.service>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
   </properties>
 
   <dependencies>
@@ -43,12 +45,12 @@
       <groupId>org.apache.camel</groupId>
       <artifactId>camel-core</artifactId>
     </dependency>
-
+    
     <dependency>
       <groupId>io.grpc</groupId>
       <artifactId>grpc-auth</artifactId>
       <version>${grpc-version}</version>
-    </dependency>    
+    </dependency>
     <dependency>
       <groupId>io.grpc</groupId>
       <artifactId>grpc-netty</artifactId>
@@ -70,12 +72,6 @@
       <artifactId>javassist</artifactId>
       <version>${javassist-version}</version>
     </dependency>
-    
-    <dependency>
-      <groupId>com.google.guava</groupId>
-      <artifactId>guava</artifactId>
-      <version>${grpc-guava-version}</version>
-    </dependency>
 
     <dependency>
       <groupId>io.netty</groupId>
diff --git a/components/camel-grpc/src/main/docs/grpc-component.adoc b/components/camel-grpc/src/main/docs/grpc-component.adoc
index ef8e6b7..122ed9c 100644
--- a/components/camel-grpc/src/main/docs/grpc-component.adoc
+++ b/components/camel-grpc/src/main/docs/grpc-component.adoc
@@ -20,6 +20,16 @@ for this component:
 </dependency>
 ------------------------------------------------------------
 
+Starting with Camel *2.22* gRCP requires strong own of the Google Guava version. It's necessary
to
+add following configuration property to the maven file
+
+[source,xml]
+------------------------------------------------------------
+<properties>
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
+<properties>
+------------------------------------------------------------
+
 ### URI format
 
 [source,java]
diff --git a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/pom.xml
b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/pom.xml
index 10eefb4..8e0d8c0 100644
--- a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/pom.xml
+++ b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/pom.xml
@@ -30,11 +30,13 @@
 
   <artifactId>camel-example-hello-grpc-client-kubernetes</artifactId>
   <name>Camel :: Example :: gRPC :: Hello Camel Client Kubernetes</name>
-  <description>An example showing the Camel Grpc component with Spring Boot runnning
on Kubernetes</description>
+  <description>An example showing the Camel gRPC component with Spring Boot runnning
on Kubernetes</description>
 
   <properties>
     <category>Cloud</category>
     <spring.boot-version>${spring-boot-version}</spring.boot-version>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
   </properties>
 
   <!-- Spring-Boot and Camel BOM -->
diff --git a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
index 19a55ec..03b0e62 100644
--- a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
+++ b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-client-kubernetes/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
@@ -23,7 +23,7 @@ import org.apache.camel.examples.CamelHelloRequest;
 import org.springframework.stereotype.Component;
 
 /**
- * A simple Camel Grpc route example using Spring-boot
+ * A simple Camel gRPC route example using Spring-boot
  */
 @Component
 public class CamelGrpcRoute extends RouteBuilder {
diff --git a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-server-kubernetes/pom.xml
b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-server-kubernetes/pom.xml
index 5b1f83e..af16c7d 100644
--- a/examples/camel-example-grpc-kubernetes/hello-camel-grpc-server-kubernetes/pom.xml
+++ b/examples/camel-example-grpc-kubernetes/hello-camel-grpc-server-kubernetes/pom.xml
@@ -33,6 +33,8 @@
 
   <properties>
     <main.class>org.apache.camel.examples.grpc.HelloCamelServer</main.class>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
   </properties>
 
   <dependencies>
@@ -51,12 +53,6 @@
       <artifactId>grpc-stub</artifactId>
       <version>${grpc-version}</version>
     </dependency>
-    
-    <dependency>
-      <groupId>com.google.guava</groupId>
-      <artifactId>guava</artifactId>
-      <version>${grpc-guava-version}</version>
-    </dependency>
   </dependencies>
   <build>
     <extensions>
diff --git a/examples/camel-example-grpc-kubernetes/pom.xml b/examples/camel-example-grpc-kubernetes/pom.xml
index 1dc6ced..1fde567 100644
--- a/examples/camel-example-grpc-kubernetes/pom.xml
+++ b/examples/camel-example-grpc-kubernetes/pom.xml
@@ -35,6 +35,8 @@
 
   <properties>
     <category>Cloud</category>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
   </properties>
 
   <modules>
diff --git a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/pom.xml b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/pom.xml
index 78b1eda..dc44ed9 100644
--- a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/pom.xml
+++ b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/pom.xml
@@ -30,11 +30,13 @@
 
   <artifactId>camel-example-hello-grpc-client</artifactId>
   <name>Camel :: Example :: gRPC :: Hello Camel Client</name>
-  <description>An example showing the Camel Grpc component with Spring Boot</description>
+  <description>An example showing the Camel gRPC component with Spring Boot</description>
 
   <properties>
     <category>Cloud</category>
     <spring.boot-version>${spring-boot-version}</spring.boot-version>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
   </properties>
 
   <!-- Spring-Boot and Camel BOM -->
diff --git a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
index 784391a..e4d8454 100644
--- a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
+++ b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-client/src/main/java/org/apache/camel/example/springboot/grpc/CamelGrpcRoute.java
@@ -23,7 +23,7 @@ import org.apache.camel.examples.CamelHelloRequest;
 import org.springframework.stereotype.Component;
 
 /**
- * A simple Camel Grpc route example using Spring-boot
+ * A simple Camel gRPC route example using Spring-boot
  */
 @Component
 public class CamelGrpcRoute extends RouteBuilder {
@@ -32,7 +32,7 @@ public class CamelGrpcRoute extends RouteBuilder {
     public void configure() throws Exception {
 
         CamelHelloRequest request = CamelHelloRequest.newBuilder().setName("Camel").build();
-        from("timer://foo?period=10000&repeatCount=1").process(new Processor() {
+        from("timer://foo?period=10000&repeatCount=5").process(new Processor() {
 
             @Override
             public void process(Exchange exchange) throws Exception {
diff --git a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-server/pom.xml b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-server/pom.xml
index 79345ef..3671a5b 100644
--- a/examples/camel-example-spring-boot-grpc/hello-camel-grpc-server/pom.xml
+++ b/examples/camel-example-spring-boot-grpc/hello-camel-grpc-server/pom.xml
@@ -30,6 +30,11 @@
   <artifactId>camel-example-hello-grpc-server</artifactId>
   <name>Camel :: Example :: gRPC :: Hello Camel Server</name>
   <description>An example showing a simple gRPC server</description>
+  
+  <properties>
+    <!-- gRPC requires strong own of the Google Guava version -->
+    <google-guava-version>${grpc-guava-version}</google-guava-version>
+  </properties>
 
   <dependencies>
     <dependency>
@@ -47,12 +52,6 @@
       <artifactId>grpc-stub</artifactId>
       <version>${grpc-version}</version>
     </dependency>
-    
-    <dependency>
-      <groupId>com.google.guava</groupId>
-      <artifactId>guava</artifactId>
-      <version>${grpc-guava-version}</version>
-    </dependency>
   </dependencies>
   <build>
     <extensions>

-- 
To stop receiving notification emails like this one, please contact
dmvolod@apache.org.

Mime
View raw message