This is an automated email from the ASF dual-hosted git repository. acosentino pushed a commit to branch es-sink-index-fix in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git
commit c319ba302f5702245d25b0c0c70e9af7b1bf15c8 Author: Andrea Cosentino <[email protected]> AuthorDate: Wed Jul 21 15:26:38 2021 +0200 Elasticsearch index Kamelet: Fixed the indexId and indexName default to exchangeId --- elasticsearch-index-sink.kamelet.yaml | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/elasticsearch-index-sink.kamelet.yaml b/elasticsearch-index-sink.kamelet.yaml index 6fc368e..7babac9 100644 --- a/elasticsearch-index-sink.kamelet.yaml +++ b/elasticsearch-index-sink.kamelet.yaml @@ -67,6 +67,15 @@ spec: description: Name of the cluster. type: string example: quickstart + indexName: + title: Index in ElasticSearch + description: The name of the index to act against. + type: string + example: data + indexId: + title: Index ID + description: None + type: string types: out: mediaType: application/json @@ -98,7 +107,7 @@ spec: steps: - set-header: name: "indexId" - simple: "${exchangeId}" + simple: "camel-k-index-es" - choice: when: - simple: "${header[indexName]}" @@ -111,11 +120,6 @@ spec: - set-header: name: "indexName" simple: "${header[ce-indexName]}" - otherwise: - steps: - - set-header: - name: "indexName" - simple: "${exchangeId}" - to: uri: "kamelet-reify:elasticsearch-rest:{{clusterName}}" parameters: @@ -124,5 +128,6 @@ spec: enableSSL: "{{enableSSL}}" user: "{{?user}}" password: "{{?password}}" + indexName: "{{?indexName}}" - marshal: json: { }
