You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by GitBox <gi...@apache.org> on 2020/03/11 11:07:49 UTC

[GitHub] [camel-spring-boot] mabulgu opened a new pull request #26: CAMEL-12191

mabulgu opened a new pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26
 
 
   Camel-Strimzi example is added due to the issue [CAMEL-12191](https://issues.apache.org/jira/browse/CAMEL-12191). 
   
   Any comments/reviews will be appreciated.
   
   p.s. Another example will be added to Camel Examples as well without the spring-boot runtime. I started this example with spring-boot before the camel-spring-boot repository is separated.
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391534050
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/spring/camel-context.xml
 ##########
 @@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="        http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd        http://camel.apache.org/schema/spring       http://camel.apache.org/schema/spring/camel-spring.xsd">
+    <bean class="org.apache.camel.example.strimzi.StrimziRouteBuilder" id="strimziRouteBuilder" />
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
 
 Review comment:
   Yeah those examples should be updated

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391264758
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/pom.xml
 ##########
 @@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+
+	<parent>
+		<groupId>org.apache.camel.springboot.example</groupId>
+		<artifactId>examples</artifactId>
+		<version>3.2.0-SNAPSHOT</version>
+	</parent>
+
+	<artifactId>camel-example-spring-boot-strimzi</artifactId>
+	<name>Camel SB Examples :: Strimzi</name>
+	<description>Camel example which a route is defined in XML for Strimzi integration on Openshift/Kubernetes</description>
+
+	<properties>
+		<category>Messaging</category>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+		<spring.boot-version>${spring-boot-version}</spring.boot-version>
+	</properties>
+
+
+	<dependencyManagement>
+		<dependencies>
+			<!-- Spring Boot BOM -->
+			<dependency>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-dependencies</artifactId>
+				<version>${spring.boot-version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+			<!-- Camel BOM -->
+			<dependency>
+				<groupId>org.apache.camel.springboot</groupId>
+				<artifactId>camel-spring-boot-dependencies</artifactId>
+				<version>${project.version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+		</dependencies>
+	</dependencyManagement>
+
+
+	<dependencies>
+
+		<!-- Spring Boot -->
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-web</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-actuator</artifactId>
+		</dependency>
+
+		<!-- Camel -->
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-core</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-support</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-kafka</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-stream</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel.springboot</groupId>
+			<artifactId>camel-spring-boot-starter</artifactId>
+		</dependency>
+	</dependencies>
+
+	<build>
+		<defaultGoal>spring-boot:run</defaultGoal>
+		<plugins>
+			<plugin>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-maven-plugin</artifactId>
+				<version>${spring.boot-version}</version>
+				<executions>
+					<execution>
+						<goals>
+							<goal>repackage</goal>
+						</goals>
+					</execution>
+				</executions>
+			</plugin>
+		</plugins>
+	</build>
+
+	<profiles>
+		<profile>
+			<id>kubernetes</id>
+			<build>
+				<plugins>
+					<plugin>
+						<artifactId>fabric8-maven-plugin</artifactId>
+						<groupId>io.fabric8</groupId>
+						<version>${fabric8-maven-plugin-version}</version>
 
 Review comment:
   We should switch to the new one that is from eclipse. This can be done in another PR. You are welcome to create a JIRA to switch from fmp to that other one

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391533820
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
+        .routeId("Producer Route")
+        .setBody(simple("Hi, this is Camel-Strimzi example from {{environment}} environment"))
+        .to("kafka:{{producer.topic}}?brokers={{kafka.bootstrap.url}}&sslEndpointAlgorithm={{kafka.sslEndpointAlgorithm}}&securityProtocol={{kafka.securityProtocol}}&sslTruststoreLocation={{kafka.truststore.location}}&sslTruststorePassword={{kafka.truststore.password}}");
 
 Review comment:
   Setting the brokers option is likely better on component level so its set for all endpoints. The producer.topic etc is fine as-is etc.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391265602
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
+        .routeId("Producer Route")
+        .setBody(simple("Hi, this is Camel-Strimzi example from {{environment}} environment"))
+        .to("kafka:{{producer.topic}}?brokers={{kafka.bootstrap.url}}&sslEndpointAlgorithm={{kafka.sslEndpointAlgorithm}}&securityProtocol={{kafka.securityProtocol}}&sslTruststoreLocation={{kafka.truststore.location}}&sslTruststorePassword={{kafka.truststore.password}}");
+        ;
+
+        from("kafka:{{producer.topic}}?brokers={{kafka.bootstrap.url}}&sslEndpointAlgorithm={{kafka.sslEndpointAlgorithm}}&securityProtocol={{kafka.securityProtocol}}&sslTruststoreLocation={{kafka.truststore.location}}&sslTruststorePassword={{kafka.truststore.password}}")
+        .routeId("Consumer Route")
+        .log("${body}")
+        ;
 
 Review comment:
   Move semi colon up

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391540177
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/spring/camel-context.xml
 ##########
 @@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="        http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd        http://camel.apache.org/schema/spring       http://camel.apache.org/schema/spring/camel-spring.xsd">
+    <bean class="org.apache.camel.example.strimzi.StrimziRouteBuilder" id="strimziRouteBuilder" />
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
 
 Review comment:
   i know, but one also can use xmls. i just wasn't sure what to do since in this case there may be some camel best practices which i might not master the concept of. So we have to follow the SB best practices AFAIU in this case. Thanks

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391532119
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
+        .routeId("Producer Route")
+        .setBody(simple("Hi, this is Camel-Strimzi example from {{environment}} environment"))
+        .to("kafka:{{producer.topic}}?brokers={{kafka.bootstrap.url}}&sslEndpointAlgorithm={{kafka.sslEndpointAlgorithm}}&securityProtocol={{kafka.securityProtocol}}&sslTruststoreLocation={{kafka.truststore.location}}&sslTruststorePassword={{kafka.truststore.password}}");
 
 Review comment:
   Is that a common approach to set the uris in the .properties file? Isn't that sth out-of-property? Should we consider those as just configurable strings -from properties file- in a plain java class?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392089294
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/pom.xml
 ##########
 @@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+
+	<parent>
+		<groupId>org.apache.camel.springboot.example</groupId>
+		<artifactId>examples</artifactId>
+		<version>3.2.0-SNAPSHOT</version>
+	</parent>
+
+	<artifactId>camel-example-spring-boot-strimzi</artifactId>
+	<name>Camel SB Examples :: Strimzi</name>
+	<description>Camel example which a route is defined in XML for Strimzi integration on Openshift/Kubernetes</description>
+
+	<properties>
+		<category>Messaging</category>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+		<spring.boot-version>${spring-boot-version}</spring.boot-version>
+	</properties>
+
+
+	<dependencyManagement>
+		<dependencies>
+			<!-- Spring Boot BOM -->
+			<dependency>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-dependencies</artifactId>
+				<version>${spring.boot-version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+			<!-- Camel BOM -->
+			<dependency>
+				<groupId>org.apache.camel.springboot</groupId>
+				<artifactId>camel-spring-boot-dependencies</artifactId>
+				<version>${project.version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+		</dependencies>
+	</dependencyManagement>
+
+
+	<dependencies>
+
+		<!-- Spring Boot -->
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-web</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-actuator</artifactId>
+		</dependency>
+
+		<!-- Camel -->
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-core</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-support</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-kafka</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-stream</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel.springboot</groupId>
+			<artifactId>camel-spring-boot-starter</artifactId>
+		</dependency>
+	</dependencies>
+
+	<build>
+		<defaultGoal>spring-boot:run</defaultGoal>
+		<plugins>
+			<plugin>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-maven-plugin</artifactId>
+				<version>${spring.boot-version}</version>
+				<executions>
+					<execution>
+						<goals>
+							<goal>repackage</goal>
+						</goals>
+					</execution>
+				</executions>
+			</plugin>
+		</plugins>
+	</build>
+
+	<profiles>
+		<profile>
+			<id>kubernetes</id>
+			<build>
+				<plugins>
+					<plugin>
+						<artifactId>fabric8-maven-plugin</artifactId>
+						<groupId>io.fabric8</groupId>
+						<version>${fabric8-maven-plugin-version}</version>
 
 Review comment:
   will do this in another PR as suggested.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391264323
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/pom.xml
 ##########
 @@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+
+	<parent>
+		<groupId>org.apache.camel.springboot.example</groupId>
+		<artifactId>examples</artifactId>
+		<version>3.2.0-SNAPSHOT</version>
+	</parent>
+
+	<artifactId>camel-example-spring-boot-strimzi</artifactId>
+	<name>Camel SB Examples :: Strimzi</name>
+	<description>Camel example which a route is defined in XML for Strimzi integration on Openshift/Kubernetes</description>
+
+	<properties>
+		<category>Messaging</category>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+		<spring.boot-version>${spring-boot-version}</spring.boot-version>
+	</properties>
+
+
+	<dependencyManagement>
+		<dependencies>
+			<!-- Spring Boot BOM -->
+			<dependency>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-dependencies</artifactId>
+				<version>${spring.boot-version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+			<!-- Camel BOM -->
+			<dependency>
+				<groupId>org.apache.camel.springboot</groupId>
+				<artifactId>camel-spring-boot-dependencies</artifactId>
+				<version>${project.version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+		</dependencies>
+	</dependencyManagement>
+
+
+	<dependencies>
+
+		<!-- Spring Boot -->
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-web</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-actuator</artifactId>
+		</dependency>
+
+		<!-- Camel -->
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-core</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-support</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-kafka</artifactId>
 
 Review comment:
   Use camel-kafka-starter and also for the others below. And groupid is org apache camel springboot

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391264122
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/pom.xml
 ##########
 @@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+
+	<parent>
+		<groupId>org.apache.camel.springboot.example</groupId>
+		<artifactId>examples</artifactId>
+		<version>3.2.0-SNAPSHOT</version>
+	</parent>
+
+	<artifactId>camel-example-spring-boot-strimzi</artifactId>
+	<name>Camel SB Examples :: Strimzi</name>
+	<description>Camel example which a route is defined in XML for Strimzi integration on Openshift/Kubernetes</description>
+
+	<properties>
+		<category>Messaging</category>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+		<spring.boot-version>${spring-boot-version}</spring.boot-version>
+	</properties>
+
+
+	<dependencyManagement>
+		<dependencies>
+			<!-- Spring Boot BOM -->
+			<dependency>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-dependencies</artifactId>
+				<version>${spring.boot-version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+			<!-- Camel BOM -->
+			<dependency>
+				<groupId>org.apache.camel.springboot</groupId>
+				<artifactId>camel-spring-boot-dependencies</artifactId>
+				<version>${project.version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+		</dependencies>
+	</dependencyManagement>
+
+
+	<dependencies>
+
+		<!-- Spring Boot -->
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-web</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-actuator</artifactId>
+		</dependency>
+
+		<!-- Camel -->
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-core</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.camel</groupId>
+			<artifactId>camel-support</artifactId>
 
 Review comment:
   support not needed when you use core above

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392097404
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+import org.springframework.stereotype.Component;
+
+@Component
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
+        .routeId("Producer Route")
+        .setBody(simple("Hi, this is Camel-Strimzi example from {{environment}} environment"))
+        .to("{{camel.component.kafka}}");
 
 Review comment:
   This is wrong, you would still say "kafka:TestLog" 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391534317
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/spring/camel-context.xml
 ##########
 @@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="        http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd        http://camel.apache.org/schema/spring       http://camel.apache.org/schema/spring/camel-spring.xsd">
+    <bean class="org.apache.camel.example.strimzi.StrimziRouteBuilder" id="strimziRouteBuilder" />
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
 
 Review comment:
   spring boot is not spring xml anymore. Only a few dedicated examples that shows you can still do camel xml routes.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392098036
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/application-local.properties
 ##########
 @@ -0,0 +1,2 @@
+environment=local
+camel.component.kafka=kafka:TestLog?brokers=KAFKA_BOOTSTRAP_ROUTE_URL&sslEndpointAlgorithm=HTTPS&securityProtocol=SSL&sslTruststoreLocation=truststore.jks&sslTruststorePassword=123456
 
 Review comment:
   Here you configure multiple options one by one
   
   camel.component.kafka.brokers=XXX
   camel.component.kafka.security-protocol=SSL
   
   See this doc page for all the option names
   https://github.com/apache/camel-spring-boot/blob/master/components-starter/camel-kafka-starter/src/main/docs/kafka-starter.adoc
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392101361
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/application-local.properties
 ##########
 @@ -0,0 +1,2 @@
+environment=local
+camel.component.kafka=kafka:TestLog?brokers=KAFKA_BOOTSTRAP_ROUTE_URL&sslEndpointAlgorithm=HTTPS&securityProtocol=SSL&sslTruststoreLocation=truststore.jks&sslTruststorePassword=123456
 
 Review comment:
   Ah ok. it is about the naming then. I misunderstood. That's why I was skeptical about this. I forgot those auto-config properties. Sorry.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392096426
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/pom.xml
 ##########
 @@ -0,0 +1,115 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+	<modelVersion>4.0.0</modelVersion>
+
+	<parent>
+		<groupId>org.apache.camel.springboot.example</groupId>
+		<artifactId>examples</artifactId>
+		<version>3.2.0-SNAPSHOT</version>
+	</parent>
+
+	<artifactId>camel-example-spring-boot-strimzi</artifactId>
+	<name>Camel SB Examples :: Strimzi</name>
+	<description>Camel example which a route is defined in XML for Strimzi integration on Openshift/Kubernetes</description>
+
+	<properties>
+		<category>Messaging</category>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+		<spring.boot-version>${spring-boot-version}</spring.boot-version>
+	</properties>
+
+
+	<dependencyManagement>
+		<dependencies>
+			<!-- Spring Boot BOM -->
+			<dependency>
+				<groupId>org.springframework.boot</groupId>
+				<artifactId>spring-boot-dependencies</artifactId>
+				<version>${spring.boot-version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+			<!-- Camel BOM -->
+			<dependency>
+				<groupId>org.apache.camel.springboot</groupId>
+				<artifactId>camel-spring-boot-dependencies</artifactId>
+				<version>${project.version}</version>
+				<type>pom</type>
+				<scope>import</scope>
+			</dependency>
+		</dependencies>
+	</dependencyManagement>
+
+
+	<dependencies>
+
+		<!-- Spring Boot -->
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-web</artifactId>
+		</dependency>
+
+		<dependency>
+			<groupId>org.springframework.boot</groupId>
+			<artifactId>spring-boot-starter-actuator</artifactId>
+		</dependency>
+
+		<!-- Camel -->
+		<dependency>
 
 Review comment:
   This should not be needed as you just depend on the camel-spring-boot-starter

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391265951
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/spring/camel-context.xml
 ##########
 @@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="        http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd        http://camel.apache.org/schema/spring       http://camel.apache.org/schema/spring/camel-spring.xsd">
+    <bean class="org.apache.camel.example.strimzi.StrimziRouteBuilder" id="strimziRouteBuilder" />
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
 
 Review comment:
   You do not need a spring xml file. Just add route builder class and have spring annotation on class, eg @ component. See the other examples

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392096603
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/Application.java
 ##########
 @@ -0,0 +1,32 @@
+/**
+ *  Copyright 2005-2018 Red Hat, Inc.
 
 Review comment:
   Use ASF license header, not Red Hat

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus merged pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus merged pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392096749
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+import org.springframework.stereotype.Component;
+
+@Component
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
 
 Review comment:
   Indent the route DSL so it looks nicer

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391531705
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/spring/camel-context.xml
 ##########
 @@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="        http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd        http://camel.apache.org/schema/spring       http://camel.apache.org/schema/spring/camel-spring.xsd">
+    <bean class="org.apache.camel.example.strimzi.StrimziRouteBuilder" id="strimziRouteBuilder" />
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
 
 Review comment:
   I saw a couple of examples like this: setting the camel context in the xml file and create the bean here. Regarding to your comment i suppose we have to change those as well. (I.e. kafka avro example)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] davsclaus commented on a change in pull request #26: CAMEL-12191

Posted by GitBox <gi...@apache.org>.
davsclaus commented on a change in pull request #26: CAMEL-12191
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r391265503
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/java/org/apache/camel/example/strimzi/StrimziRouteBuilder.java
 ##########
 @@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.example.strimzi;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.kafka.KafkaConstants;
+
+public class StrimziRouteBuilder extends RouteBuilder {
+
+    @Override
+    public void configure() throws Exception {
+
+        from("timer://foo?period=1000")
+        .routeId("Producer Route")
+        .setBody(simple("Hi, this is Camel-Strimzi example from {{environment}} environment"))
+        .to("kafka:{{producer.topic}}?brokers={{kafka.bootstrap.url}}&sslEndpointAlgorithm={{kafka.sslEndpointAlgorithm}}&securityProtocol={{kafka.securityProtocol}}&sslTruststoreLocation={{kafka.truststore.location}}&sslTruststorePassword={{kafka.truststore.password}}");
 
 Review comment:
   Instead of all these uri options, then most of them can be configured in application.properties with camel.component.kafka.xxx=yyy

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [camel-spring-boot] mabulgu commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi

Posted by GitBox <gi...@apache.org>.
mabulgu commented on a change in pull request #26: CAMEL-12191: Camel-Kafka: create an example on Kubernetes/Openshift by using Strimzi
URL: https://github.com/apache/camel-spring-boot/pull/26#discussion_r392101361
 
 

 ##########
 File path: examples/camel-example-spring-boot-strimzi/src/main/resources/application-local.properties
 ##########
 @@ -0,0 +1,2 @@
+environment=local
+camel.component.kafka=kafka:TestLog?brokers=KAFKA_BOOTSTRAP_ROUTE_URL&sslEndpointAlgorithm=HTTPS&securityProtocol=SSL&sslTruststoreLocation=truststore.jks&sslTruststorePassword=123456
 
 Review comment:
   Ah ok. it is about the naming then. I misunderstood. That's why I was skeptical about this.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services