martinzink commented on code in PR #1349:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1349#discussion_r907637828


##########
docker/test/integration/features/elasticsearch.feature:
##########
@@ -0,0 +1,93 @@
+# 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.
+
+@no-ci  # Elasticsearch container requires more RAM than what the CI 
environment has
+Feature: Managing documents on Elasticsearch with PostElasticsearch
+
+  Background:
+    Given the content of "/tmp/output" is monitored
+
+  Scenario: MiNiFi instance indexes a document on Elasticsearch using Basic 
Authentication
+    Given an Elasticsearch server is set up and running
+    And a GetFile processor with the "Input Directory" property set to 
"/tmp/input"
+    And a file with the content "{ "field1" : "value1" }" is present in 
"/tmp/input"
+    And a PostElasticsearch processor
+    And the "Index" property of the PostElasticsearch processor is set to 
"my_index"
+    And the "Identifier" property of the PostElasticsearch processor is set to 
"my_id"
+    And the "Action" property of the PostElasticsearch processor is set to 
"index"
+    And a SSL context service is set up for PostElasticsearch and Elasticsearch
+    And an ElasticsearchCredentialsService is set up for PostElasticsearch 
with Basic Authentication
+    And a PutFile processor with the "Directory" property set to "/tmp/output"
+    And the "success" relationship of the GetFile processor is connected to 
the PostElasticsearch
+    And the "success" relationship of the PostElasticsearch processor is 
connected to the PutFile
+
+    When both instances start up
+    Then a flowfile with the content "{ "field1" : "value1" }" is placed in 
the monitored directory in less than 20 seconds
+    And Elasticsearch has a document with "my_id" in "my_index" that has 
"value1" set in "field1"
+
+  Scenario: MiNiFi instance creates a document on Elasticsearch using API Key 
authentication

Review Comment:
   makes sense, I've remade them into Scenario Outlines in 
https://github.com/apache/nifi-minifi-cpp/pull/1349/commits/fa725ffb8fc830c7cf8518f40334d7ee9fa0df13#diff-0256a991bbecdae5406fe625e6bca90bfbfe4c3b6390f8749b63658534c80779R40-R43



##########
docker/test/integration/features/opensearch.feature:
##########
@@ -0,0 +1,97 @@
+# 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.
+
+@no-ci  # Opensearch container requires more RAM than what the CI environment 
has
+Feature: PostElasticsearch works on Opensearch (Opensearch doesnt support API 
Keys)
+
+  Background:
+    Given the content of "/tmp/output" is monitored
+
+  Scenario: MiNiFi instance indexes a document on Opensearch using Basic 
Authentication
+    Given an Opensearch server is set up and running
+    And a GetFile processor with the "Input Directory" property set to 
"/tmp/input"
+    And a file with the content "{ "field1" : "value1" }" is present in 
"/tmp/input"
+    And a PostElasticsearch processor
+    And the "Hosts" property of the PostElasticsearch processor is set to 
"https://opensearch:9200";
+    And the "Index" property of the PostElasticsearch processor is set to 
"my_index"
+    And the "Identifier" property of the PostElasticsearch processor is set to 
"my_id"
+    And the "Action" property of the PostElasticsearch processor is set to 
"index"
+    And a SSL context service is set up for PostElasticsearch and Opensearch
+    And an ElasticsearchCredentialsService is set up for PostElasticsearch 
with Basic Authentication
+    And a PutFile processor with the "Directory" property set to "/tmp/output"
+    And the "success" relationship of the GetFile processor is connected to 
the PostElasticsearch
+    And the "success" relationship of the PostElasticsearch processor is 
connected to the PutFile
+
+    When both instances start up
+    Then a flowfile with the content "{ "field1" : "value1" }" is placed in 
the monitored directory in less than 20 seconds
+    And Opensearch has a document with "my_id" in "my_index" that has "value1" 
set in "field1"
+
+  Scenario: MiNiFi instance creates a document on Opensearch using Basic 
Authentication

Review Comment:
   makes sense, I've remade them into Scenario Outlines in 
https://github.com/apache/nifi-minifi-cpp/pull/1349/commits/fa725ffb8fc830c7cf8518f40334d7ee9fa0df13#diff-9f20f0de056cfd00e2e8fa2e58c861a9f213f9c15f0f2bbcb5313feb0862c500R41-R44



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@nifi.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to