camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [camel] 07/22: CAMEL-16757: YAML DSL to support route configuration
Date Tue, 03 Aug 2021 12:33:37 GMT
This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch CAMEL-16757b
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 1748351edab6de6cf926da8d76e44f09b3f1db6f
Author: Claus Ibsen <claus.ibsen@gmail.com>
AuthorDate: Mon Aug 2 13:31:01 2021 +0200

    CAMEL-16757: YAML DSL to support route configuration
---
 .../camel/dsl/yaml/deserializers/RouteDefinitionDeserializer.java     | 4 ++++
 .../camel-yaml-dsl/src/generated/resources/camel-yaml-dsl.json        | 3 +++
 2 files changed, 7 insertions(+)

diff --git a/dsl/camel-yaml-dsl/camel-yaml-dsl-deserializers/src/main/java/org/apache/camel/dsl/yaml/deserializers/RouteDefinitionDeserializer.java
b/dsl/camel-yaml-dsl/camel-yaml-dsl-deserializers/src/main/java/org/apache/camel/dsl/yaml/deserializers/RouteDefinitionDeserializer.java
index 9170fcb..074a387 100644
--- a/dsl/camel-yaml-dsl/camel-yaml-dsl-deserializers/src/main/java/org/apache/camel/dsl/yaml/deserializers/RouteDefinitionDeserializer.java
+++ b/dsl/camel-yaml-dsl/camel-yaml-dsl-deserializers/src/main/java/org/apache/camel/dsl/yaml/deserializers/RouteDefinitionDeserializer.java
@@ -37,6 +37,7 @@ import org.snakeyaml.engine.v2.nodes.NodeTuple;
           properties = {
                   @YamlProperty(name = "id", type = "string"),
                   @YamlProperty(name = "group", type = "string"),
+                  @YamlProperty(name = "route-configuration", type = "string"),
                   @YamlProperty(name = "from", type = "object:org.apache.camel.model.FromDefinition",
required = true),
                   @YamlProperty(name = "steps", type = "array:org.apache.camel.model.ProcessorDefinition",
required = true)
           })
@@ -70,6 +71,9 @@ public class RouteDefinitionDeserializer extends YamlDeserializerBase<RouteDefin
                 case "group":
                     target.setGroup(asText(val));
                     break;
+                case "route-configuration":
+                    target.setRouteConfiguration(asText(val));
+                    break;
                 case "from":
                     target.setInput(asType(val, FromDefinition.class));
                     break;
diff --git a/dsl/camel-yaml-dsl/camel-yaml-dsl/src/generated/resources/camel-yaml-dsl.json
b/dsl/camel-yaml-dsl/camel-yaml-dsl/src/generated/resources/camel-yaml-dsl.json
index 51527d7..924421b 100644
--- a/dsl/camel-yaml-dsl/camel-yaml-dsl/src/generated/resources/camel-yaml-dsl.json
+++ b/dsl/camel-yaml-dsl/camel-yaml-dsl/src/generated/resources/camel-yaml-dsl.json
@@ -2095,6 +2095,9 @@
           "id" : {
             "type" : "string"
           },
+          "route-configuration" : {
+            "type" : "string"
+          },
           "steps" : {
             "type" : "array",
             "items" : {

Mime
View raw message