From d7b8bc299e1ace40edb3463baccd0281d2a864ec Mon Sep 17 00:00:00 2001 From: Ashish Agrawal Date: Mon, 20 Sep 2021 10:49:15 -0700 Subject: [PATCH 1/3] Update CI workflow to use OpenSearch 1.1 instead of 1.x --- .github/workflows/multi-node-test-workflow.yml | 2 +- .github/workflows/test-workflow.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/multi-node-test-workflow.yml b/.github/workflows/multi-node-test-workflow.yml index e0eb52ca7..6ba35e52f 100644 --- a/.github/workflows/multi-node-test-workflow.yml +++ b/.github/workflows/multi-node-test-workflow.yml @@ -29,7 +29,7 @@ jobs: with: repository: 'opensearch-project/OpenSearch' path: OpenSearch - ref: '1.x' + ref: '1.1' - name: Build OpenSearch working-directory: ./OpenSearch run: ./gradlew publishToMavenLocal diff --git a/.github/workflows/test-workflow.yml b/.github/workflows/test-workflow.yml index 6098fc7d0..da584240c 100644 --- a/.github/workflows/test-workflow.yml +++ b/.github/workflows/test-workflow.yml @@ -35,7 +35,7 @@ jobs: with: repository: 'opensearch-project/OpenSearch' path: OpenSearch - ref: '1.x' + ref: '1.1' - name: Build OpenSearch working-directory: ./OpenSearch run: ./gradlew publishToMavenLocal From 1e5fa09045198fc016eb5bfa2b19c4d4e9a92ff5 Mon Sep 17 00:00:00 2001 From: Ashish Agrawal Date: Mon, 20 Sep 2021 10:50:53 -0700 Subject: [PATCH 2/3] Update naming Signed-off-by: Ashish Agrawal --- .github/workflows/test-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-workflow.yml b/.github/workflows/test-workflow.yml index da584240c..3c68b05ef 100644 --- a/.github/workflows/test-workflow.yml +++ b/.github/workflows/test-workflow.yml @@ -1,5 +1,5 @@ name: Test Workflow -# This workflow is triggered on pull requests and pushes to main or an opendistro release branch +# This workflow is triggered on pull requests and pushes to main or an opensearch release branch on: pull_request: branches: From d43fdbd0c5b13f69e463c5a7108f5736830af844 Mon Sep 17 00:00:00 2001 From: Ashish Agrawal Date: Mon, 20 Sep 2021 10:52:16 -0700 Subject: [PATCH 3/3] remove integtest.sh Signed-off-by: Ashish Agrawal --- integtest.sh | 77 ---------------------------------------------------- 1 file changed, 77 deletions(-) delete mode 100755 integtest.sh diff --git a/integtest.sh b/integtest.sh deleted file mode 100755 index 6d5aeb392..000000000 --- a/integtest.sh +++ /dev/null @@ -1,77 +0,0 @@ -#!/bin/bash - -set -e - -function usage() { - echo "" - echo "This script is used to run integration tests for plugin installed on a remote OpenSearch/Dashboards cluster." - echo "--------------------------------------------------------------------------" - echo "Usage: $0 [args]" - echo "" - echo "Required arguments:" - echo "None" - echo "" - echo "Optional arguments:" - echo -e "-b BIND_ADDRESS\t, defaults to localhost | 127.0.0.1, can be changed to any IP or domain name for the cluster location." - echo -e "-p BIND_PORT\t, defaults to 9200 or 5601 depends on OpenSearch or Dashboards, can be changed to any port for the cluster location." - echo -e "-s SECURITY_ENABLED\t(true | false), defaults to true. Specify the OpenSearch/Dashboards have security enabled or not." - echo -e "-c CREDENTIAL\t(usename:password), no defaults, effective when SECURITY_ENABLED=true." - echo -e "-h\tPrint this message." - echo "--------------------------------------------------------------------------" -} - -while getopts ":hb:p:s:c:" arg; do - case $arg in - h) - usage - exit 1 - ;; - b) - BIND_ADDRESS=$OPTARG - ;; - p) - BIND_PORT=$OPTARG - ;; - s) - SECURITY_ENABLED=$OPTARG - ;; - c) - CREDENTIAL=$OPTARG - ;; - :) - echo "-${OPTARG} requires an argument" - usage - exit 1 - ;; - ?) - echo "Invalid option: -${OPTARG}" - exit 1 - ;; - esac -done - - -if [ -z "$BIND_ADDRESS" ] -then - BIND_ADDRESS="localhost" -fi - -if [ -z "$BIND_PORT" ] -then - BIND_PORT="9200" -fi - -if [ -z "$SECURITY_ENABLED" ] -then - SECURITY_ENABLED="true" -fi - -if [ -z "$CREDENTIAL" ] -then - CREDENTIAL="admin:admin" - USERNAME=`echo $CREDENTIAL | awk -F ':' '{print $1}'` - PASSWORD=`echo $CREDENTIAL | awk -F ':' '{print $2}'` -fi - -./gradlew integTest -Dtests.rest.cluster="$BIND_ADDRESS:$BIND_PORT" -Dtests.cluster="$BIND_ADDRESS:$BIND_PORT" -Dtests.clustername="opensearch-integrationtest" -Dhttps=$SECURITY_ENABLED -Duser=$USERNAME -Dpassword=$PASSWORD --console=plain -Dsecurity=$SECURITY_ENABLED -