camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nferr...@apache.org
Subject [9/9] camel git commit: CAMEL-10186: Adding routebox to the list of autoconfigured components
Date Tue, 08 Nov 2016 12:54:03 GMT
CAMEL-10186: Adding routebox to the list of autoconfigured components


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/0e0bc1b2
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/0e0bc1b2
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/0e0bc1b2

Branch: refs/heads/master
Commit: 0e0bc1b23a29aef280b3a37e8e8cbae91e7d36c3
Parents: c0c4ced
Author: Nicola Ferraro <ni.ferraro@gmail.com>
Authored: Tue Nov 8 13:53:00 2016 +0100
Committer: Nicola Ferraro <ni.ferraro@gmail.com>
Committed: Tue Nov 8 13:53:00 2016 +0100

----------------------------------------------------------------------
 .../RouteboxComponentAutoConfiguration.java     | 43 ++++++++++++++++++++
 .../main/resources/META-INF/spring.factories    | 19 +++++++++
 2 files changed, 62 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/0e0bc1b2/components-starter/camel-routebox-starter/src/main/java/org/apache/camel/component/routebox/springboot/RouteboxComponentAutoConfiguration.java
----------------------------------------------------------------------
diff --git a/components-starter/camel-routebox-starter/src/main/java/org/apache/camel/component/routebox/springboot/RouteboxComponentAutoConfiguration.java
b/components-starter/camel-routebox-starter/src/main/java/org/apache/camel/component/routebox/springboot/RouteboxComponentAutoConfiguration.java
new file mode 100644
index 0000000..ab06029
--- /dev/null
+++ b/components-starter/camel-routebox-starter/src/main/java/org/apache/camel/component/routebox/springboot/RouteboxComponentAutoConfiguration.java
@@ -0,0 +1,43 @@
+/**
+ * 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.component.routebox.springboot;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.component.routebox.RouteboxComponent;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * Generated by camel-package-maven-plugin - do not edit this file!
+ */
+@Configuration
+@ConditionalOnBean(type = "org.apache.camel.springboot.CamelAutoConfiguration")
+public class RouteboxComponentAutoConfiguration {
+
+    @Bean(name = "routebox-component")
+    @ConditionalOnClass(CamelContext.class)
+    @ConditionalOnMissingBean(RouteboxComponent.class)
+    public RouteboxComponent configureRouteboxComponent(
+            CamelContext camelContext) throws Exception {
+        RouteboxComponent component = new RouteboxComponent();
+        component.setCamelContext(camelContext);
+        return component;
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/camel/blob/0e0bc1b2/components-starter/camel-routebox-starter/src/main/resources/META-INF/spring.factories
----------------------------------------------------------------------
diff --git a/components-starter/camel-routebox-starter/src/main/resources/META-INF/spring.factories
b/components-starter/camel-routebox-starter/src/main/resources/META-INF/spring.factories
new file mode 100644
index 0000000..6fd7813
--- /dev/null
+++ b/components-starter/camel-routebox-starter/src/main/resources/META-INF/spring.factories
@@ -0,0 +1,19 @@
+#
+# 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.
+#
+
+org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
+org.apache.camel.component.routebox.springboot.RouteboxComponentAutoConfiguration


Mime
View raw message