This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push: new b7b4821944b CAMEL-20166: Polished b7b4821944b is described below commit b7b4821944bc9a60153335ab9f53d21e8e4cdb29 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Mon Dec 11 07:27:11 2023 +0100 CAMEL-20166: Polished --- .../apache/camel/catalog/components/elasticsearch-rest-client.json | 2 +- .../rest/client/ElasticsearchRestClientEndpointUriFactory.java | 3 +-- .../elasticsearch/rest/client/elasticsearch-rest-client.json | 2 +- .../elasticsearch/rest/client/ElasticsearchRestClientEndpoint.java | 4 +++- .../endpoint/dsl/ElasticsearchRestClientEndpointBuilderFactory.java | 2 ++ 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/elasticsearch-rest-client.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/elasticsearch-rest-client.json index 23bf39a30ca..14e5fc2505c 100644 --- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/elasticsearch-rest-client.json +++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/elasticsearch-rest-client.json @@ -30,7 +30,7 @@ "connectionTimeout": { "index": 1, "kind": "parameter", "displayName": "Connection Timeout", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "autowired": false, "secret": false, "defaultValue": 30000, "description": "Connection timeout" }, "hostAddressesList": { "index": 2, "kind": "parameter", "displayName": "Host Addresses List", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "List of host Addresses, multiple hosts can be separated by comma." }, "indexName": { "index": 3, "kind": "parameter", "displayName": "Index Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Index Name" }, - "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation", "enum": [ "INDEX_OR_UPDATE", "GET_BY_ID", "DELETE", "CREATE_INDEX", "DELETE_INDEX", "SEARCH" ], "deprecated": false, "autowired": false, "secret": true, "description": "Operation" }, + "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation", "enum": [ "INDEX_OR_UPDATE", "GET_BY_ID", "DELETE", "CREATE_INDEX", "DELETE_INDEX", "SEARCH" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Operation" }, "socketTimeout": { "index": 5, "kind": "parameter", "displayName": "Socket Timeout", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "autowired": false, "secret": false, "defaultValue": 30000, "description": "Socket timeout" }, "lazyStartProducer": { "index": 6, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a produc [...] "enableSniffer": { "index": 7, "kind": "parameter", "displayName": "Enable Sniffer", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Enabling Sniffer" }, diff --git a/components/camel-elasticsearch-rest-client/src/generated/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpointUriFactory.java b/components/camel-elasticsearch-rest-client/src/generated/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpointUriFactory.java index f4c1fa1feda..3aa525691a4 100644 --- a/components/camel-elasticsearch-rest-client/src/generated/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpointUriFactory.java +++ b/components/camel-elasticsearch-rest-client/src/generated/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpointUriFactory.java @@ -37,8 +37,7 @@ public class ElasticsearchRestClientEndpointUriFactory extends org.apache.camel. props.add("socketTimeout"); props.add("user"); PROPERTY_NAMES = Collections.unmodifiableSet(props); - Set<String> secretProps = new HashSet<>(3); - secretProps.add("operation"); + Set<String> secretProps = new HashSet<>(2); secretProps.add("password"); secretProps.add("user"); SECRET_PROPERTY_NAMES = Collections.unmodifiableSet(secretProps); diff --git a/components/camel-elasticsearch-rest-client/src/generated/resources/org/apache/camel/component/elasticsearch/rest/client/elasticsearch-rest-client.json b/components/camel-elasticsearch-rest-client/src/generated/resources/org/apache/camel/component/elasticsearch/rest/client/elasticsearch-rest-client.json index 23bf39a30ca..14e5fc2505c 100644 --- a/components/camel-elasticsearch-rest-client/src/generated/resources/org/apache/camel/component/elasticsearch/rest/client/elasticsearch-rest-client.json +++ b/components/camel-elasticsearch-rest-client/src/generated/resources/org/apache/camel/component/elasticsearch/rest/client/elasticsearch-rest-client.json @@ -30,7 +30,7 @@ "connectionTimeout": { "index": 1, "kind": "parameter", "displayName": "Connection Timeout", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "autowired": false, "secret": false, "defaultValue": 30000, "description": "Connection timeout" }, "hostAddressesList": { "index": 2, "kind": "parameter", "displayName": "Host Addresses List", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "List of host Addresses, multiple hosts can be separated by comma." }, "indexName": { "index": 3, "kind": "parameter", "displayName": "Index Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Index Name" }, - "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation", "enum": [ "INDEX_OR_UPDATE", "GET_BY_ID", "DELETE", "CREATE_INDEX", "DELETE_INDEX", "SEARCH" ], "deprecated": false, "autowired": false, "secret": true, "description": "Operation" }, + "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation", "enum": [ "INDEX_OR_UPDATE", "GET_BY_ID", "DELETE", "CREATE_INDEX", "DELETE_INDEX", "SEARCH" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Operation" }, "socketTimeout": { "index": 5, "kind": "parameter", "displayName": "Socket Timeout", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "autowired": false, "secret": false, "defaultValue": 30000, "description": "Socket timeout" }, "lazyStartProducer": { "index": 6, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a produc [...] "enableSniffer": { "index": 7, "kind": "parameter", "displayName": "Enable Sniffer", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Enabling Sniffer" }, diff --git a/components/camel-elasticsearch-rest-client/src/main/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpoint.java b/components/camel-elasticsearch-rest-client/src/main/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpoint.java index c39d9c49759..06e0013b248 100644 --- a/components/camel-elasticsearch-rest-client/src/main/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpoint.java +++ b/components/camel-elasticsearch-rest-client/src/main/java/org/apache/camel/component/elasticsearch/rest/client/ElasticsearchRestClientEndpoint.java @@ -36,10 +36,12 @@ import org.elasticsearch.client.RestClient; syntax = "elasticsearch-rest-client:clusterName", producerOnly = true, category = { Category.SEARCH }) public class ElasticsearchRestClientEndpoint extends DefaultEndpoint { + @UriPath @Metadata(required = true) private String clusterName; - @UriParam(secret = true) + @UriParam + @Metadata(required = true) ElasticsearchRestClientOperation operation; @UriParam(label = "advanced") diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/ElasticsearchRestClientEndpointBuilderFactory.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/ElasticsearchRestClientEndpointBuilderFactory.java index e45cb7b92e3..8454dc8d963 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/ElasticsearchRestClientEndpointBuilderFactory.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/ElasticsearchRestClientEndpointBuilderFactory.java @@ -113,6 +113,7 @@ public interface ElasticsearchRestClientEndpointBuilderFactory { * The option is a: * <code>org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation</code> type. * + * Required: true * Group: producer * * @param operation the value to set @@ -129,6 +130,7 @@ public interface ElasticsearchRestClientEndpointBuilderFactory { * The option will be converted to a * <code>org.apache.camel.component.elasticsearch.rest.client.ElasticsearchRestClientOperation</code> type. * + * Required: true * Group: producer * * @param operation the value to set