From cac7e081dacb6b870bbaa3fb920e5f957c3b359f Mon Sep 17 00:00:00 2001 From: Derek Ho Date: Mon, 17 Jun 2024 10:48:44 -0400 Subject: [PATCH 1/2] Fix URL duplication issue (#2004) Signed-off-by: Derek Ho --- public/apps/configuration/app-router.tsx | 2 +- .../configuration/test/__snapshots__/app-router.test.tsx.snap | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/public/apps/configuration/app-router.tsx b/public/apps/configuration/app-router.tsx index 53e0e5536..bb317fda6 100644 --- a/public/apps/configuration/app-router.tsx +++ b/public/apps/configuration/app-router.tsx @@ -165,7 +165,7 @@ export function AppRouter(props: AppDependencies) { return ( - + {allNavPanelUrls(multitenancyEnabled).map((route) => ( // Create different routes to update the 'selected' nav item . diff --git a/public/apps/configuration/test/__snapshots__/app-router.test.tsx.snap b/public/apps/configuration/test/__snapshots__/app-router.test.tsx.snap index ce8a72df0..0c19e737f 100644 --- a/public/apps/configuration/test/__snapshots__/app-router.test.tsx.snap +++ b/public/apps/configuration/test/__snapshots__/app-router.test.tsx.snap @@ -12,9 +12,7 @@ exports[`SecurityPluginTopNavMenu renders DataSourceMenu when dataSource is enab } } > - + Date: Wed, 19 Jun 2024 12:25:31 -0400 Subject: [PATCH 2/2] Change JDK to 21 for main branch (#2008) * Change JDK to 21 for main branch Signed-off-by: Derek Ho * Workflow cleanup and change all instances to 21 Signed-off-by: Derek Ho * Remove unecessary step Signed-off-by: Derek Ho * Test if action is whats causing windows failures Signed-off-by: Derek Ho * Use released version with bug fix Signed-off-by: Derek Ho * Use v6 for all Signed-off-by: Derek Ho --------- Signed-off-by: Derek Ho --- .github/actions/run-cypress-tests/action.yml | 8 ++------ .../cypress-test-multidatasources-enabled-e2e.yml | 3 ++- .github/workflows/cypress-test-tenancy-disabled.yml | 8 ++------ .github/workflows/cypress-test.yml | 8 ++------ .github/workflows/integration-test.yml | 11 ++++------- .github/workflows/verify-binary-installation.yml | 3 ++- 6 files changed, 14 insertions(+), 27 deletions(-) diff --git a/.github/actions/run-cypress-tests/action.yml b/.github/actions/run-cypress-tests/action.yml index d77adf5a2..2f8331e66 100644 --- a/.github/actions/run-cypress-tests/action.yml +++ b/.github/actions/run-cypress-tests/action.yml @@ -19,11 +19,6 @@ inputs: runs: using: "composite" steps: - - name: Set up JDK - uses: actions/setup-java@v1 - with: - java-version: 11 - - name: Set env run: | opensearch_version=$(node -p "require('./package.json').opensearchDashboards.version") @@ -41,13 +36,14 @@ runs: download-location: ${{ env.PLUGIN_NAME }} - name: Run Opensearch with A Single Plugin - uses: derek-ho/start-opensearch@v2 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/opensearch-security.zip" security-enabled: true admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} security_config_file: ${{ inputs.security_config_file }} + jdk-version: 21 # OSD bootstrap - name: Run Dashboard with Security Dashboards Plugin diff --git a/.github/workflows/cypress-test-multidatasources-enabled-e2e.yml b/.github/workflows/cypress-test-multidatasources-enabled-e2e.yml index 162941cf1..252920a7e 100644 --- a/.github/workflows/cypress-test-multidatasources-enabled-e2e.yml +++ b/.github/workflows/cypress-test-multidatasources-enabled-e2e.yml @@ -67,7 +67,7 @@ jobs: download-location: ${{env.PLUGIN_NAME}} - name: Run Opensearch with A Single Plugin - uses: derek-ho/start-opensearch@v4 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/opensearch-security.zip" @@ -75,6 +75,7 @@ jobs: admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} security_config_file: config_custom.yml port: 9202 + jdk-version: 21 - name: Check OpenSearch is running # Verify that the server is operational diff --git a/.github/workflows/cypress-test-tenancy-disabled.yml b/.github/workflows/cypress-test-tenancy-disabled.yml index d67e478a4..07679e790 100644 --- a/.github/workflows/cypress-test-tenancy-disabled.yml +++ b/.github/workflows/cypress-test-tenancy-disabled.yml @@ -22,11 +22,6 @@ jobs: runs-on: ${{ matrix.os }} steps: - - name: Set up JDK - uses: actions/setup-java@v1 - with: - java-version: 11 - - name: Checkout Branch uses: actions/checkout@v3 @@ -47,12 +42,13 @@ jobs: download-location: ${{ env.PLUGIN_NAME }} - name: Run Opensearch with security - uses: derek-ho/start-opensearch@v2 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/${{ env.PLUGIN_NAME }}.zip" security-enabled: true admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} + jdk-version: 21 # Configure the Dashboard - name: Configure OpenSearch Dashboards with tenancy disabled diff --git a/.github/workflows/cypress-test.yml b/.github/workflows/cypress-test.yml index c9a85ac6f..5698fa03a 100644 --- a/.github/workflows/cypress-test.yml +++ b/.github/workflows/cypress-test.yml @@ -22,11 +22,6 @@ jobs: runs-on: ${{ matrix.os }} steps: - - name: Set up JDK - uses: actions/setup-java@v1 - with: - java-version: 11 - - name: Checkout Branch uses: actions/checkout@v3 @@ -47,12 +42,13 @@ jobs: download-location: ${{ env.PLUGIN_NAME }} - name: Run Opensearch with security - uses: derek-ho/start-opensearch@v2 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/${{ env.PLUGIN_NAME }}.zip" security-enabled: true admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} + jdk-version: 21 # Configure the Dashboard - name: Configure OpenSearch Dashboards for cypress diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml index 2126ff1d0..477c3da03 100644 --- a/.github/workflows/integration-test.yml +++ b/.github/workflows/integration-test.yml @@ -20,11 +20,6 @@ jobs: steps: - name: Checkout Branch uses: actions/checkout@v3 - - - name: Set up JDK - uses: actions/setup-java@v1 - with: - java-version: 11 - name: Set env run: | @@ -51,7 +46,7 @@ jobs: plugin-version: ${{ env.PLUGIN_VERSION }} - name: Run Opensearch with A Single Plugin Remote Cluster - uses: derek-ho/start-opensearch@v4 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/opensearch-security-${{ env.OPENSEARCH_VERSION }}.zip" @@ -59,6 +54,7 @@ jobs: admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} security_config_file: ${{ inputs.security_config_file }} port: 9202 + jdk-version: 21 - name: Check OpenSearch remote is running run: | @@ -66,12 +62,13 @@ jobs: shell: bash - name: Run Opensearch with security - uses: derek-ho/start-opensearch@v2 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/${{ env.PLUGIN_NAME }}.zip" security-enabled: true admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} + jdk-version: 21 # https://github.com/actions/runner-images/issues/2840#issuecomment-790492173 - name: Remove unnecessary files Linux diff --git a/.github/workflows/verify-binary-installation.yml b/.github/workflows/verify-binary-installation.yml index c19bc3c81..70c210a8b 100644 --- a/.github/workflows/verify-binary-installation.yml +++ b/.github/workflows/verify-binary-installation.yml @@ -39,12 +39,13 @@ jobs: download-location: ${{ env.PLUGIN_NAME }} - name: Run Opensearch with security - uses: derek-ho/start-opensearch@v2 + uses: derek-ho/start-opensearch@v6 with: opensearch-version: ${{ env.OPENSEARCH_VERSION }} plugins: "file:$(pwd)/${{ env.PLUGIN_NAME }}.zip" security-enabled: true admin-password: ${{ env.OPENSEARCH_INITIAL_ADMIN_PASSWORD }} + jdk-version: 21 # Configure the Dashboard - name: Configure OpenSearch Dashboards