You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2019/12/06 05:48:57 UTC

[camel] branch master updated (439ee88 -> c98a203)

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

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


    from 439ee88  Fixed build and regen
     new 003666d  CAMEL-14263: Make property configurer for component and endpoints into only class.
     new 934698b  Fixed build
     new bee7c98  CAMEL-14263: Fixed CS
     new c98a203  CAMEL-14240: Add backlogTracing into the spring/blueprint XML

The 4 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:
 components/camel-rest-openapi/pom.xml              |   1 +
 .../xml/AbstractCamelContextFactoryBeanTest.java   |   2 +-
 .../apt/ComponentPropertyConfigurerGenerator.java  | 169 ---------------------
 .../tools/apt/EndpointAnnotationProcessor.java     |  21 ++-
 ...rator.java => PropertyConfigurerGenerator.java} |  27 ++--
 .../camel/tools/apt/model/ComponentOption.java     |   2 +-
 .../camel/tools/apt/model/EndpointOption.java      |   2 +-
 .../camel/tools/apt/model/PropertyOption.java      |  11 +-
 8 files changed, 35 insertions(+), 200 deletions(-)
 delete mode 100644 tooling/apt/src/main/java/org/apache/camel/tools/apt/ComponentPropertyConfigurerGenerator.java
 rename tooling/apt/src/main/java/org/apache/camel/tools/apt/{EndpointPropertyConfigurerGenerator.java => PropertyConfigurerGenerator.java} (89%)
 copy components/camel-sql/src/test/java/org/apache/camel/component/sql/stored/CustomType.java => tooling/apt/src/main/java/org/apache/camel/tools/apt/model/PropertyOption.java (83%)


[camel] 04/04: CAMEL-14240: Add backlogTracing into the spring/blueprint XML

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

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

commit c98a2034a55185ca9471c6c92b1b85a4d20b40bb
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Fri Dec 6 06:47:49 2019 +0100

    CAMEL-14240: Add backlogTracing into the spring/blueprint XML
---
 .../org/apache/camel/core/xml/AbstractCamelContextFactoryBeanTest.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/core/camel-core-xml/src/test/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBeanTest.java b/core/camel-core-xml/src/test/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBeanTest.java
index 21b9822..cc2088a 100644
--- a/core/camel-core-xml/src/test/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBeanTest.java
+++ b/core/camel-core-xml/src/test/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBeanTest.java
@@ -85,7 +85,7 @@ public class AbstractCamelContextFactoryBeanTest {
         new DefaultFactoryFinder(new DefaultClassResolver(), "META-INF/services/org/apache/camel/"), false);
 
     // properties that should return value that can be converted to boolean
-    Set<String> valuesThatReturnBoolean = new HashSet<>(asList("{{getStreamCache}}", "{{getTrace}}",
+    Set<String> valuesThatReturnBoolean = new HashSet<>(asList("{{getStreamCache}}", "{{getDebug}}", "{{getTrace}}", "{{getBacklogTrace}}",
         "{{getMessageHistory}}", "{{getLogMask}}", "{{getLogExhaustedMessageBody}}", "{{getHandleFault}}",
         "{{getAutoStartup}}", "{{getUseMDCLogging}}", "{{getUseDataType}}", "{{getUseBreadcrumb}}", "{{getAllowUseOriginalMessage}}"));
 


[camel] 03/04: CAMEL-14263: Fixed CS

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

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

commit bee7c989c550e2e266831fb22f544c0cae642b77
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Fri Dec 6 06:38:29 2019 +0100

    CAMEL-14263: Fixed CS
---
 .../org/apache/camel/tools/apt/EndpointAnnotationProcessor.java     | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
index 0d840bc..ca103e0 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
@@ -52,7 +52,11 @@ import org.apache.camel.spi.annotations.Component;
 import org.apache.camel.tools.apt.helper.EndpointHelper;
 import org.apache.camel.tools.apt.helper.JsonSchemaHelper;
 import org.apache.camel.tools.apt.helper.Strings;
-import org.apache.camel.tools.apt.model.*;
+import org.apache.camel.tools.apt.model.ComponentModel;
+import org.apache.camel.tools.apt.model.ComponentOption;
+import org.apache.camel.tools.apt.model.EndpointOption;
+import org.apache.camel.tools.apt.model.EndpointPath;
+import org.apache.camel.tools.apt.model.PropertyOption;
 import org.apache.camel.util.json.JsonObject;
 import org.apache.camel.util.json.Jsoner;
 


[camel] 01/04: CAMEL-14263: Make property configurer for component and endpoints into only class.

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

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

commit 003666df9faf4d9e2335637d2167e62a9070f9ed
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Fri Dec 6 06:11:52 2019 +0100

    CAMEL-14263: Make property configurer for component and endpoints into only class.
---
 .../apt/ComponentPropertyConfigurerGenerator.java  | 169 ---------------------
 .../tools/apt/EndpointAnnotationProcessor.java     |  25 +--
 ...rator.java => PropertyConfigurerGenerator.java} |  27 ++--
 .../camel/tools/apt/model/ComponentOption.java     |   2 +-
 .../camel/tools/apt/model/EndpointOption.java      |   2 +-
 .../camel/tools/apt/model/PropertyOption.java      |  27 ++++
 6 files changed, 55 insertions(+), 197 deletions(-)

diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/ComponentPropertyConfigurerGenerator.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/ComponentPropertyConfigurerGenerator.java
deleted file mode 100644
index 6685cf5..0000000
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/ComponentPropertyConfigurerGenerator.java
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
- * 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.tools.apt;
-
-import java.io.IOException;
-import java.io.Writer;
-import java.util.Set;
-
-import javax.annotation.processing.ProcessingEnvironment;
-import javax.lang.model.element.TypeElement;
-import javax.tools.Diagnostic;
-import javax.tools.FileObject;
-import javax.tools.JavaFileObject;
-import javax.tools.StandardLocation;
-
-import org.apache.camel.tools.apt.helper.IOHelper;
-import org.apache.camel.tools.apt.model.ComponentOption;
-
-import static org.apache.camel.tools.apt.AnnotationProcessorHelper.dumpExceptionToErrorFile;
-
-// TODO: ComponentPropertyConfigurerGenerator and EndpointPropertyConfigurerGenerator can be merged to one
-// TODO: Add support for ignore case
-
-public final class ComponentPropertyConfigurerGenerator {
-
-    private ComponentPropertyConfigurerGenerator() {
-    }
-
-    public static void generateExtendConfigurer(ProcessingEnvironment processingEnv, TypeElement parent,
-                                                String pn, String cn, String fqn) {
-
-        Writer w = null;
-        try {
-            JavaFileObject src = processingEnv.getFiler().createSourceFile(fqn, parent);
-            w = src.openWriter();
-
-            w.write("/* Generated by org.apache.camel:apt */\n");
-            w.write("package " + pn + ";\n");
-            w.write("\n");
-            w.write("import " + parent.getQualifiedName().toString() + ";\n");
-            w.write("\n");
-            w.write("/**\n");
-            w.write(" * Source code generated by org.apache.camel:apt\n");
-            w.write(" */\n");
-            w.write("public class " + cn + " extends " + parent.getSimpleName().toString() + " {\n");
-            w.write("\n");
-            w.write("}\n");
-            w.write("\n");
-        } catch (Exception e) {
-            processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "Unable to generate source code file: " + fqn + ": " + e.getMessage());
-            dumpExceptionToErrorFile("camel-apt-error.log", "Unable to generate source code file: " + fqn, e);
-        } finally {
-            IOHelper.close(w);
-        }
-    }
-
-    public static void generatePropertyConfigurer(ProcessingEnvironment processingEnv, TypeElement parent,
-                                                  String pn, String cn, String fqn, String en,
-                                                  Set<ComponentOption> options) {
-
-        Writer w = null;
-        try {
-            JavaFileObject src = processingEnv.getFiler().createSourceFile(fqn, parent);
-            w = src.openWriter();
-
-            int size = options.size();
-
-            w.write("/* Generated by org.apache.camel:apt */\n");
-            w.write("package " + pn + ";\n");
-            w.write("\n");
-            w.write("import java.util.HashMap;\n");
-            w.write("import java.util.Map;\n");
-            w.write("\n");
-            w.write("import org.apache.camel.CamelContext;\n");
-            w.write("import org.apache.camel.spi.GeneratedPropertyConfigurer;\n");
-            w.write("import org.apache.camel.support.component.PropertyConfigurerSupport;\n");
-            w.write("\n");
-            w.write("/**\n");
-            w.write(" * Source code generated by org.apache.camel:apt\n");
-            w.write(" */\n");
-            w.write("@SuppressWarnings(\"unchecked\")\n");
-            w.write("public class " + cn + " extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer {\n");
-            w.write("\n");
-            w.write("    @Override\n");
-            w.write("    public boolean configure(CamelContext camelContext, Object component, String name, Object value, boolean ignoreCase) {\n");
-            w.write("        if (ignoreCase) {\n");
-            w.write("            return doConfigureIgnoreCase(camelContext, component, name, value);\n");
-            w.write("        } else {\n");
-            w.write("            return doConfigure(camelContext, component, name, value);\n");
-            w.write("        }\n");
-            w.write("    }\n");
-            w.write("\n");
-            w.write("    private static boolean doConfigure(CamelContext camelContext, Object component, String name, Object value) {\n");
-            w.write("        switch (name) {\n");
-            for (ComponentOption option : options) {
-                String getOrSet = option.getName();
-                getOrSet = Character.toUpperCase(getOrSet.charAt(0)) + getOrSet.substring(1);
-                String setterLambda = setterLambda(en, getOrSet, option.getType(), option.getConfigurationField());
-                w.write(String.format("        case \"%s\": %s; return true;\n", option.getName(), setterLambda));
-            }
-            w.write("            default: return false;\n");
-            w.write("        }\n");
-            w.write("    }\n");
-            w.write("\n");
-            w.write("    private static boolean doConfigureIgnoreCase(CamelContext camelContext, Object component, String name, Object value) {\n");
-            w.write("        switch (name.toLowerCase()) {\n");
-            for (ComponentOption option : options) {
-                String getOrSet = option.getName();
-                getOrSet = Character.toUpperCase(getOrSet.charAt(0)) + getOrSet.substring(1);
-                String setterLambda = setterLambda(en, getOrSet, option.getType(), option.getConfigurationField());
-                w.write(String.format("        case \"%s\": %s; return true;\n", option.getName().toLowerCase(), setterLambda));
-            }
-            w.write("            default: return false;\n");
-            w.write("        }\n");
-            w.write("    }\n");
-            w.write("\n");
-            w.write("}\n");
-            w.write("\n");
-        } catch (Exception e) {
-            processingEnv.getMessager().printMessage(Diagnostic.Kind.ERROR, "Unable to generate source code file: " + fqn + ": " + e.getMessage());
-            dumpExceptionToErrorFile("camel-apt-error.log", "Unable to generate source code file: " + fqn, e);
-        } finally {
-            IOHelper.close(w);
-        }
-    }
-
-    private static String setterLambda(String en, String getOrSet, String type, String configurationField) {
-        // type may contain generics so remove those
-        if (type.indexOf('<') != -1) {
-            type = type.substring(0, type.indexOf('<'));
-        }
-        if (configurationField != null) {
-            getOrSet = "get" + Character.toUpperCase(configurationField.charAt(0)) + configurationField.substring(1) + "().set" + getOrSet;
-        } else {
-            getOrSet = "set" + getOrSet;
-        }
-
-        // ((LogEndpoint) endpoint).setGroupSize(property(camelContext, java.lang.Integer.class, value))
-        return String.format("((%s) component).%s(property(camelContext, %s.class, value))", en, getOrSet, type);
-    }
-
-    public static void generateMetaInfConfigurer(ProcessingEnvironment processingEnv, String name, String fqn) {
-        try {
-            FileObject resource = processingEnv.getFiler().createResource(StandardLocation.CLASS_OUTPUT, "",
-                    "META-INF/services/org/apache/camel/configurer/" + name);
-            try (Writer w = resource.openWriter()) {
-                w.append("# Generated by camel annotation processor\n");
-                w.append("class=").append(fqn).append("\n");
-            }
-        } catch (IOException e) {
-            throw new RuntimeException(e);
-        }
-    }
-
-}
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
index 2505e26..0d840bc 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
@@ -52,10 +52,7 @@ import org.apache.camel.spi.annotations.Component;
 import org.apache.camel.tools.apt.helper.EndpointHelper;
 import org.apache.camel.tools.apt.helper.JsonSchemaHelper;
 import org.apache.camel.tools.apt.helper.Strings;
-import org.apache.camel.tools.apt.model.ComponentModel;
-import org.apache.camel.tools.apt.model.ComponentOption;
-import org.apache.camel.tools.apt.model.EndpointOption;
-import org.apache.camel.tools.apt.model.EndpointPath;
+import org.apache.camel.tools.apt.model.*;
 import org.apache.camel.util.json.JsonObject;
 import org.apache.camel.util.json.Jsoner;
 
@@ -206,13 +203,15 @@ public class EndpointAnnotationProcessor extends AbstractCamelAnnotationProcesso
         String fqClassName = packageName + "." + className;
 
         if ("activemq".equals(scheme) || "amqp".equals(scheme)) {
-            ComponentPropertyConfigurerGenerator.generateExtendConfigurer(processingEnv, parent, packageName, className, fqClassName);
-            ComponentPropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-component", fqClassName);
+            PropertyConfigurerGenerator.generateExtendConfigurer(processingEnv, parent, packageName, className, fqClassName);
+            PropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-component", fqClassName);
         } else if (uriEndpoint.generateConfigurer() && !componentOptions.isEmpty()) {
             // only generate this once for the first scheme
             if (schemes == null || schemes[0].equals(scheme)) {
-                ComponentPropertyConfigurerGenerator.generatePropertyConfigurer(processingEnv, parent, packageName, className, fqClassName, componentClassName, componentOptions);
-                ComponentPropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-component", fqClassName);
+                Set<PropertyOption> set = new LinkedHashSet<>();
+                set.addAll(componentOptions);
+                PropertyConfigurerGenerator.generatePropertyConfigurer(processingEnv, parent, packageName, className, fqClassName, componentClassName, set);
+                PropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-component", fqClassName);
             }
         }
     }
@@ -233,13 +232,15 @@ public class EndpointAnnotationProcessor extends AbstractCamelAnnotationProcesso
         String fqClassName = packageName + "." + className;
 
         if ("activemq".equals(scheme) || "amqp".equals(scheme)) {
-            EndpointPropertyConfigurerGenerator.generateExtendConfigurer(processingEnv, parent, packageName, className, fqClassName);
-            EndpointPropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-endpoint", fqClassName);
+            PropertyConfigurerGenerator.generateExtendConfigurer(processingEnv, parent, packageName, className, fqClassName);
+            PropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-endpoint", fqClassName);
         } else if (uriEndpoint.generateConfigurer() && !endpointOptions.isEmpty()) {
             // only generate this once for the first scheme
             if (schemes == null || schemes[0].equals(scheme)) {
-                EndpointPropertyConfigurerGenerator.generatePropertyConfigurer(processingEnv, parent, packageName, className, fqClassName, endpointClassName, endpointOptions);
-                EndpointPropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-endpoint", fqClassName);
+                Set<PropertyOption> set = new LinkedHashSet<>();
+                set.addAll(endpointOptions);
+                PropertyConfigurerGenerator.generatePropertyConfigurer(processingEnv, parent, packageName, className, fqClassName, endpointClassName, set);
+                PropertyConfigurerGenerator.generateMetaInfConfigurer(processingEnv, componentModel.getScheme() + "-endpoint", fqClassName);
             }
         }
     }
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointPropertyConfigurerGenerator.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/PropertyConfigurerGenerator.java
similarity index 89%
rename from tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointPropertyConfigurerGenerator.java
rename to tooling/apt/src/main/java/org/apache/camel/tools/apt/PropertyConfigurerGenerator.java
index 54ef7c0..6c8af09 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointPropertyConfigurerGenerator.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/PropertyConfigurerGenerator.java
@@ -28,15 +28,13 @@ import javax.tools.JavaFileObject;
 import javax.tools.StandardLocation;
 
 import org.apache.camel.tools.apt.helper.IOHelper;
-import org.apache.camel.tools.apt.model.EndpointOption;
+import org.apache.camel.tools.apt.model.PropertyOption;
 
 import static org.apache.camel.tools.apt.AnnotationProcessorHelper.dumpExceptionToErrorFile;
 
-// TODO: ComponentPropertyConfigurerGenerator and EndpointPropertyConfigurerGenerator can be merged to one
+public final class PropertyConfigurerGenerator {
 
-public final class EndpointPropertyConfigurerGenerator {
-
-    private EndpointPropertyConfigurerGenerator() {
+    private PropertyConfigurerGenerator() {
     }
 
     public static void generateExtendConfigurer(ProcessingEnvironment processingEnv, TypeElement parent,
@@ -69,7 +67,7 @@ public final class EndpointPropertyConfigurerGenerator {
 
     public static void generatePropertyConfigurer(ProcessingEnvironment processingEnv, TypeElement parent,
                                                   String pn, String cn, String fqn, String en,
-                                                  Set<EndpointOption> options) {
+                                                  Set<PropertyOption> options) {
 
         Writer w = null;
         try {
@@ -95,17 +93,17 @@ public final class EndpointPropertyConfigurerGenerator {
             w.write("public class " + cn + " extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer {\n");
             w.write("\n");
             w.write("    @Override\n");
-            w.write("    public boolean configure(CamelContext camelContext, Object endpoint, String name, Object value, boolean ignoreCase) {\n");
+            w.write("    public boolean configure(CamelContext camelContext, Object target, String name, Object value, boolean ignoreCase) {\n");
             w.write("        if (ignoreCase) {\n");
-            w.write("            return doConfigureIgnoreCase(camelContext, endpoint, name, value);\n");
+            w.write("            return doConfigureIgnoreCase(camelContext, target, name, value);\n");
             w.write("        } else {\n");
-            w.write("            return doConfigure(camelContext, endpoint, name, value);\n");
+            w.write("            return doConfigure(camelContext, target, name, value);\n");
             w.write("        }\n");
             w.write("    }\n");
             w.write("\n");
-            w.write("    private static boolean doConfigure(CamelContext camelContext, Object endpoint, String name, Object value) {\n");
+            w.write("    private static boolean doConfigure(CamelContext camelContext, Object target, String name, Object value) {\n");
             w.write("        switch (name) {\n");
-            for (EndpointOption option : options) {
+            for (PropertyOption option : options) {
                 String getOrSet = option.getName();
                 getOrSet = Character.toUpperCase(getOrSet.charAt(0)) + getOrSet.substring(1);
                 String setterLambda = setterLambda(en, getOrSet, option.getType(), option.getConfigurationField());
@@ -115,9 +113,9 @@ public final class EndpointPropertyConfigurerGenerator {
             w.write("        }\n");
             w.write("    }\n");
             w.write("\n");
-            w.write("    private static boolean doConfigureIgnoreCase(CamelContext camelContext, Object endpoint, String name, Object value) {\n");
+            w.write("    private static boolean doConfigureIgnoreCase(CamelContext camelContext, Object target, String name, Object value) {\n");
             w.write("        switch (name.toLowerCase()) {\n");
-            for (EndpointOption option : options) {
+            for (PropertyOption option : options) {
                 String getOrSet = option.getName();
                 getOrSet = Character.toUpperCase(getOrSet.charAt(0)) + getOrSet.substring(1);
                 String setterLambda = setterLambda(en, getOrSet, option.getType(), option.getConfigurationField());
@@ -148,7 +146,8 @@ public final class EndpointPropertyConfigurerGenerator {
             getOrSet = "set" + getOrSet;
         }
 
-        return String.format("((%s) endpoint).%s(property(camelContext, %s.class, value))", en, getOrSet, type);
+        // ((LogComponent) target).setGroupSize(property(camelContext, java.lang.Integer.class, value))
+        return String.format("((%s) target).%s(property(camelContext, %s.class, value))", en, getOrSet, type);
     }
 
     public static void generateMetaInfConfigurer(ProcessingEnvironment processingEnv, String name, String fqn) {
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/ComponentOption.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/ComponentOption.java
index 537594b..dd77337 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/ComponentOption.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/ComponentOption.java
@@ -20,7 +20,7 @@ import java.util.Set;
 
 import static org.apache.camel.tools.apt.helper.Strings.isNullOrEmpty;
 
-public final class ComponentOption {
+public final class ComponentOption implements PropertyOption {
 
     private String name;
     private String displayName;
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/EndpointOption.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/EndpointOption.java
index a225e1d..c44ef4f 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/EndpointOption.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/EndpointOption.java
@@ -20,7 +20,7 @@ import java.util.Set;
 
 import static org.apache.camel.tools.apt.helper.Strings.isNullOrEmpty;
 
-public final class EndpointOption {
+public final class EndpointOption implements PropertyOption {
 
     private String name;
     private String displayName;
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/PropertyOption.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/PropertyOption.java
new file mode 100644
index 0000000..3bcfc77
--- /dev/null
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/model/PropertyOption.java
@@ -0,0 +1,27 @@
+/*
+ * 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.tools.apt.model;
+
+public interface PropertyOption {
+
+    String getName();
+
+    String getType();
+
+    String getConfigurationField();
+
+}


[camel] 02/04: Fixed build

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

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

commit 934698bbfbc57d8742e62ef36e8e3a4d4a69e9d5
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Fri Dec 6 06:14:00 2019 +0100

    Fixed build
---
 components/camel-rest-openapi/pom.xml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/components/camel-rest-openapi/pom.xml b/components/camel-rest-openapi/pom.xml
index f14910a..67e73ea 100644
--- a/components/camel-rest-openapi/pom.xml
+++ b/components/camel-rest-openapi/pom.xml
@@ -48,6 +48,7 @@
         <dependency>
             <groupId>io.apicurio</groupId>
             <artifactId>apicurio-data-models</artifactId>
+            <version>${apicurio-version}</version>
         </dependency>
 
         <!-- test -->