diff --git a/.circleci/config.yml b/.circleci/config.yml index 367757396..757b5db9d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -140,6 +140,9 @@ jobs: - run: name: Run QA Automation command: MODULE_VERSION=$CIRCLE_TAG VERBOSE=1 TEST=release ./tests/qa/run + - run: + name: Run QA Automation (RediSearch Light) + command: MODULE_VERSION=$CIRCLE_TAG VERBOSE=1 TEST=release LIGHT=1 ./tests/qa/run nightly-automation: docker: @@ -150,6 +153,9 @@ jobs: - run: name: Run QA Automation command: MODULE_VERSION=$CIRCLE_BRANCH VERBOSE=1 TEST=nightly ./tests/qa/run + - run: + name: Run QA Automation (RediSearch Light) + command: MODULE_VERSION=$CIRCLE_BRANCH VERBOSE=1 TEST=nightly LIGHT=1 ./tests/qa/run on-any-branch: &on-any-branch diff --git a/README.md b/README.md index 13d387dc9..523f438a0 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@ $ mkdir build $ python configure.py -$ cd buidl +$ cd build $ make diff --git a/ramp.yml b/ramp.yml index da5924d8d..4f9ec4e48 100644 --- a/ramp.yml +++ b/ramp.yml @@ -6,7 +6,7 @@ homepage: 'http://redisearch.io' license: Redis Source Available License Agreement command_line_args: PARTITIONS AUTO min_redis_version: '6.0' -min_redis_pack_version: '6.0' +min_redis_pack_version: '6.0.8' config_command: "_FT.CONFIG SET" capabilities: - types diff --git a/src/dep/RediSearch b/src/dep/RediSearch index 116565362..6f6269aa2 160000 --- a/src/dep/RediSearch +++ b/src/dep/RediSearch @@ -1 +1 @@ -Subproject commit 116565362e7a45a6259f95bc449de0e950829182 +Subproject commit 6f6269aa2d1dd004e09717069659e1c14102e6a2 diff --git a/src/version.h b/src/version.h index d7c636234..a021d7cd8 100644 --- a/src/version.h +++ b/src/version.h @@ -4,7 +4,7 @@ #define RSCOORDINATOR_VERSION_MAJOR 2 #define RSCOORDINATOR_VERSION_MINOR 0 -#define RSCOORDINATOR_VERSION_PATCH 2 +#define RSCOORDINATOR_VERSION_PATCH 3 // convert semver to incremental number as expected by redis #define RSCOORDINATOR_VERSION \ diff --git a/tests/qa/RS_VERSION b/tests/qa/RS_VERSION new file mode 100644 index 000000000..122fea9df --- /dev/null +++ b/tests/qa/RS_VERSION @@ -0,0 +1 @@ +6.0.12-29 \ No newline at end of file diff --git a/tests/qa/nightly.json b/tests/qa/nightly.json index 5012ad6ab..f9e103988 100644 --- a/tests/qa/nightly.json +++ b/tests/qa/nightly.json @@ -6,8 +6,10 @@ "email_recipients": "s5i1u4h5a8c8w2d7@redislabs.slack.com", "sut_environments": [], "tools_environment": {}, - "module_name": "search", "modules_version": "master", + "test_names_modules": [ + "{{RS_MODULE}}" + ], "cycle_environments_setup": [ { "teardown": true, diff --git a/tests/qa/nightly.yml b/tests/qa/nightly.yml index 81162d871..a3128de3a 100644 --- a/tests/qa/nightly.yml +++ b/tests/qa/nightly.yml @@ -1,14 +1,18 @@ +# https://qa-automation-center.redislabs.com/ui#dashboard/info/single_module_test_cycle +# Redis-Enterprise/rl-automation/microservices/cycles/single_module_test_cycle_sanity_and_extended/service.yaml + service_id: single_module_test_cycle name: redisearch automation-testing properties: - sut_version: master + sut_version: {{RS_VERSION}} email_recipients: s5i1u4h5a8c8w2d7@redislabs.slack.com sut_environments: [] tools_environment: {} - module_name: search modules_version: master + test_names_modules: + - {{RS_MODULE}} cycle_environments_setup: - name: bionic-amd64-aws - # module_url: http://redismodules.s3.amazonaws.com/redisearch/snapshots/redisearch.Linux-ubuntu18.04-x86_64.master-snapshot.zip + # module_url: http://redismodules.s3.amazonaws.com/redisearch/snapshots/{{RS_MODULE_FILE_PREFIX}}.Linux-ubuntu18.04-x86_64.master-snapshot.zip teardown: true concurrency: 1 diff --git a/tests/qa/release.json b/tests/qa/release.json index 7ded6bac9..92a0a1e00 100644 --- a/tests/qa/release.json +++ b/tests/qa/release.json @@ -2,32 +2,34 @@ "service_id": "single_module_test_cycle", "name": "redisearch automation-testing", "properties": { - "sut_version": "master", + "sut_version": "{{RS_VERSION}}", "email_recipients": "s5i1u4h5a8c8w2d7@redislabs.slack.com", "sut_environments": [], "tools_environment": {}, - "module_name": "search", "modules_version": "{{MODULE_VERSION}}", + "test_names_modules": [ + "{{RS_MODULE}}" + ], "cycle_environments_setup": [ { "teardown": true, "name":"trusty-amd64-aws", - "concurrency": 4 + "concurrency": 1 }, { "teardown": true, "name": "xenial-amd64-aws", - "concurrency": 4 + "concurrency": 1 }, { "teardown": true, "name": "bionic-amd64-aws", - "concurrency": 4 + "concurrency": 1 }, { "teardown": true, "name": "rhel7.7-x86_64-aws", - "concurrency": 4 + "concurrency": 1 } ] } diff --git a/tests/qa/release.yml b/tests/qa/release.yml index af4e77f38..b588c4332 100644 --- a/tests/qa/release.yml +++ b/tests/qa/release.yml @@ -1,26 +1,30 @@ +# https://qa-automation-center.redislabs.com/ui#dashboard/info/single_module_test_cycle +# Redis-Enterprise/rl-automation/microservices/cycles/single_module_test_cycle_sanity_and_extended/service.yaml + service_id: single_module_test_cycle name: redisearch automation-testing properties: - sut_version: master + sut_version: {{RS_VERSION}} email_recipients: s5i1u4h5a8c8w2d7@redislabs.slack.com sut_environments: [] tools_environment: {} - module_name: search - modules_version: "{{MODULE_VERSION}}" + modules_version: {{MODULE_VERSION}} + test_names_modules: + - {{RS_MODULE}} cycle_environments_setup: - name: trusty-amd64-aws - # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/redisearch.Linux-ubuntu18.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" + # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/{{RS_MODULE_FILE_PREFIX}}.Linux-ubuntu14.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" teardown: true - concurrency: 4 + concurrency: 1 - name: xenial-amd64-aws - # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/redisearch.Linux-ubuntu18.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" + # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/{{RS_MODULE_FILE_PREFIX}}.Linux-ubuntu16.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" teardown: true - concurrency: 4 + concurrency: 1 - name: bionic-amd64-aws - # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/redisearch.Linux-ubuntu18.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" + # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/{{RS_MODULE_FILE_PREFIX}}.Linux-ubuntu18.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" teardown: true - concurrency: 4 - - name: rhel7.8-amd64-aws - # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/redisearch.Linux-ubuntu18.04-x86_64.{{MODULE_VERSION}}-snapshot.zip" + concurrency: 1 + - name: rhel7.7-amd64-aws + # module_url: "http://redismodules.s3.amazonaws.com/redisearch/snapshots/{{RS_MODULE_FILE_PREFIX}}.Linux-rhel7-x86_64.{{MODULE_VERSION}}-snapshot.zip" teardown: true - concurrency: 4 + concurrency: 1 diff --git a/tests/qa/run b/tests/qa/run index a86727bcd..97e797714 100755 --- a/tests/qa/run +++ b/tests/qa/run @@ -1,7 +1,31 @@ #!/bin/bash HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" -ROOT=$HERE/../.. +ROOT=$(cd $HERE/../..; pwd) + +(( $VERBOSE > 1 )) && { set -x; PS4='$LINENO: '; } + +if [[ $1 == --help || $1 == help ]]; then + cat <<-END + Invoke QA Automation tests + + [ARGVARS...] run [--help|help] + + Argument variables: + QA_AUTOMATION_USERNAME=name QA automation (Opereto) username + QA_AUTOMATION_PASS=pass QA automation (Opereto) password + TEST=name Name of .json parameters file + MODULE_VERSION=ver Module version to test. Default: master + LIGHT=1 Test RediSearch Light + NOP=1 Do not execute automation command + VERBOSE=N Set verbosity level (N=1,2) + + Other configuration: + RS_VERSION file includes Redis Enterprive version for release tests. + + END + exit 0 +fi if [[ -z $QA_AUTOMATION_USERNAME ]]; then echo "Variable QA_AUTOMATION_USERNAME is undefined." >&2 @@ -13,7 +37,26 @@ if [[ -z $QA_AUTOMATION_PASS ]]; then fi export TEST=${TEST:-release} -export MODULE_VERSION=${MODULE_VERSION:-master} +if [[ ! -f $HERE/$TEST.json ]]; then + echo "Invalid TEST name: $TEST" >&2 + exit 1 +fi + +export RS_VERSION=$(cat $HERE/RS_VERSION) + +if [[ -z $MODULE_VERSION ]]; then + export MODULE_VERSION=master +else + export MODULE_VERSION=$(echo "$MODULE_VERSION" | sed 's/^v\(.*\)/\1/') +fi + +if [[ $LIGHT == 1 ]]; then + export RS_MODULE=RedisearchLight + export RS_MODULE_FILE_PREFIX=redisearch-light +else + export RS_MODULE=RediSearchEnterprise + export RS_MODULE_FILE_PREFIX=redisearch +fi results() { echo "$JSON" | jq "$1" | cut -d\" -f2 @@ -22,8 +65,10 @@ results() { cd $HERE json_in=$(mktemp /tmp/$TEST.json.XXXX) -$ROOT/deps/readies/bin/xtx -e MODULE_VERSION $TEST.json > $json_in -[[ $VERBOSE == 1 ]] && cat $json_in +$ROOT/deps/readies/bin/xtx -e RS_MODULE -e MODULE_VERSION -e RS_VERSION $TEST.json > $json_in +(( $VERBOSE >= 1 )) && cat $json_in + +[[ $NOP == 1 ]] && exit 0 JSON=$(curl -sk \ -u "$QA_AUTOMATION_USERNAME":"$QA_AUTOMATION_PASS" \