-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* custom codecs upgrade to lucene99 codec Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com> * moving lucene95 extended codecs to backward_codecs Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com> * introducing bwc framework Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com> * addressing review comments Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com> * re-introducing lucene95 custom stored fields format Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com> --------- Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
- Loading branch information
1 parent
edd8216
commit 8d2dd56
Showing
24 changed files
with
1,386 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: 'Create a backwards compatible ready build' | ||
description: 'Checkouts the official version of a the custom-codecs plugin and builds it so it can be used for BWC tests' | ||
|
||
inputs: | ||
plugin-branch: | ||
description: 'The branch of the plugin that should be built, e.g "2.2", "1.x"' | ||
required: true | ||
|
||
outputs: | ||
built-version: | ||
description: 'The version of OpenSearch that was associated with this branch' | ||
value: ${{ steps.get-opensearch-version.outputs.version }} | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Enable Longpaths if on Windows | ||
if: ${{ runner.os == 'Windows' }} | ||
run: git config --system core.longpaths true | ||
shell: pwsh | ||
|
||
- name: Checkout Branch from Fork | ||
if: ${{ inputs.plugin-branch == 'current_branch' }} | ||
uses: actions/checkout@v2 | ||
with: | ||
path: ${{ inputs.plugin-branch }} | ||
|
||
- uses: actions/checkout@v3 | ||
if: ${{ inputs.plugin-branch != 'current_branch' }} | ||
with: | ||
repository: opensearch-project/custom-codecs | ||
ref: ${{ inputs.plugin-branch }} | ||
path: ${{ inputs.plugin-branch }} | ||
|
||
- name: Build | ||
uses: gradle/gradle-build-action@v2 | ||
with: | ||
cache-disabled: true | ||
arguments: assemble | ||
build-root-directory: ${{ inputs.plugin-branch }} | ||
|
||
- id: get-opensearch-version | ||
uses: peternied/get-opensearch-version@v1 | ||
with: | ||
working-directory: ${{ inputs.plugin-branch }} | ||
|
||
- name: Copy current distro into the expected folder | ||
run: | | ||
mkdir -p ./bwc-test/src/test/resources/${{ steps.get-opensearch-version.outputs.version }} | ||
cp ${{ inputs.plugin-branch }}/build/distributions/opensearch-custom-codecs-${{ steps.get-opensearch-version.outputs.version }}-SNAPSHOT.zip ./bwc-test/src/test/resources/${{ steps.get-opensearch-version.outputs.version }} | ||
shell: bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: 'Runs the backward compatiblity test suite' | ||
description: 'Tests backwards compability between a previous and next version of this plugin' | ||
|
||
inputs: | ||
plugin-previous-branch: | ||
description: 'The branch of the plugin that should be built for the previous version, e.g "2.2", "1.x"' | ||
required: true | ||
|
||
plugin-next-branch: | ||
description: 'The branch of the plugin that should be built for the next version, e.g "2.3", "main"' | ||
required: true | ||
|
||
report-artifact-name: | ||
description: 'The name of the artifacts for this run, e.g. "BWC-2.1-to-2.4-results"' | ||
required: true | ||
|
||
username: | ||
description: 'Username to use for cluster health check in testClusters' | ||
required: true | ||
|
||
password: | ||
description: 'Password to use for cluster health check in testClusters' | ||
required: true | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
|
||
- id: build-previous | ||
uses: ./.github/actions/create-bwc-build | ||
with: | ||
plugin-branch: ${{ inputs.plugin-previous-branch }} | ||
|
||
- id: build-next | ||
uses: ./.github/actions/create-bwc-build | ||
with: | ||
plugin-branch: ${{ inputs.plugin-next-branch }} | ||
|
||
- name: Run BWC tests | ||
uses: gradle/gradle-build-action@v2 | ||
with: | ||
cache-disabled: true | ||
arguments: | | ||
-p bwc-test | ||
bwcTestSuite | ||
-Dtests.security.manager=true | ||
-Dtests.opensearch.username=${{ inputs.username }} | ||
-Dtests.opensearch.password=${{ inputs.password }} | ||
-Dbwc.version.previous=${{ steps.build-previous.outputs.built-version }} | ||
-Dbwc.version.next=${{ steps.build-next.outputs.built-version }} -i | ||
- uses: alehechka/upload-tartifact@v2 | ||
if: always() | ||
with: | ||
name: ${{ inputs.report-artifact-name }} | ||
path: | | ||
./bwc-test/build/reports/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: Backward Compatibility Checks | ||
|
||
on: | ||
push: | ||
branches: | ||
- 2.x | ||
pull_request: | ||
|
||
env: | ||
GRADLE_OPTS: -Dhttp.keepAlive=true | ||
CI_ENVIRONMENT: normal | ||
|
||
jobs: | ||
|
||
backward-compatibility-build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin # Temurin is a distribution of adoptium | ||
java-version: 17 | ||
|
||
- name: Checkout custom-codecs Repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build BWC tests | ||
uses: gradle/gradle-build-action@v2 | ||
with: | ||
cache-disabled: true | ||
arguments: | | ||
-p bwc-test build -x test -x integTest | ||
backward-compatibility: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
jdk: [11, 17] | ||
platform: [ubuntu-latest, windows-latest] | ||
runs-on: ${{ matrix.platform }} | ||
|
||
steps: | ||
- uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin # Temurin is a distribution of adoptium | ||
java-version: ${{ matrix.jdk }} | ||
|
||
- name: Checkout custom-codecs Repo | ||
uses: actions/checkout@v4 | ||
|
||
- id: build-previous | ||
uses: ./.github/actions/run-bwc-suite | ||
with: | ||
plugin-previous-branch: "2.11" | ||
plugin-next-branch: "current_branch" | ||
report-artifact-name: bwc-${{ matrix.platform }}-jdk${{ matrix.jdk }} | ||
username: admin | ||
password: admin |
Oops, something went wrong.