Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge main into 2.x #204

Closed
wants to merge 96 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
9aee213
Remove odfe bwc test (#408)
ps48 Aug 6, 2022
6e6d966
Add Bwc Test for OS 1.1 (#417)
ps48 Aug 16, 2022
c0415eb
Bump moment from 2.29.3 to 2.29.4 in /dashboards-reports (#410)
dependabot[bot] Aug 16, 2022
7899f91
Bump jsdom from 13.1.0 to 16.5.0 in /dashboards-reports (#380)
dependabot[bot] Aug 16, 2022
741cb8b
Update puppeteer flags (#460)
rupal-bq Sep 12, 2022
fc75535
Upgrade puppeteer (#483)
rupal-bq Oct 5, 2022
f37e4f2
feat: enable windows and macos build (#504)
derek-ho Oct 20, 2022
ba9bad5
Bump version to 3.0.0 (#509)
rupal-bq Oct 20, 2022
caad098
add minimatch 3.0.5 to resolutions (#512)
rupal-bq Oct 20, 2022
e1ff0d9
Add loader-utils to resolutions (#524)
rupal-bq Oct 31, 2022
69805c4
Bump loader-utils from 2.0.3 to 2.0.4 in /dashboards-reports (#539)
dependabot[bot] Nov 22, 2022
08ff77b
Fix windows and macos CI (#569)
rupal-bq Dec 6, 2022
3a626ac
Bump qs from 6.5.2 to 6.5.3 in /dashboards-reports (#573)
dependabot[bot] Dec 7, 2022
d943b73
Bump decode-uri-component from 0.2.0 to 0.2.2 in /dashboards-reports …
dependabot[bot] Dec 7, 2022
dbaf95f
Update main to be same as Reporting Repo (#3)
rupal-bq Jan 5, 2023
f9450c4
Add necessary files (#4)
rupal-bq Jan 5, 2023
7bb7e2b
Update dev doc for new repo (#18)
rupal-bq Jan 6, 2023
df8b413
Backport 2.x to main (#25)
rupal-bq Jan 10, 2023
764d02c
Add release notes for 2.5.0.0 (#24) (#27)
opensearch-trigger-bot[bot] Jan 10, 2023
5da4e17
updating plugin-helpers (#28)
ps48 Jan 11, 2023
7a60ae8
Update scrollX and scrollY config for html2canvas (#34)
joshuali925 Jan 13, 2023
9ce6c25
Update yarn dependencies (#48)
rupal-bq Feb 3, 2023
1f4de1d
Added untriaged issue workflow. (#62)
dblock Feb 17, 2023
6c9b69b
Fix Node.js and Yarn installation in CI (#64)
AMoo-Miki Feb 22, 2023
009be3e
Add release notes for 2.6.0 (#66)
rupal-bq Feb 22, 2023
b90a666
Upgrade json2csv to fix missing value for nested field with false/0 (…
rupal-bq Mar 3, 2023
0690cae
baseline repo groups (#76)
derek-ho Mar 27, 2023
7b51bd9
Preserve chart legends in reports (#81)
joshuali925 Mar 27, 2023
503ee05
Add tesseract and foreign object rendering (#86)
joshuali925 Apr 11, 2023
97ad976
Update jsdom to remove request dependency (#89)
rupal-bq Apr 12, 2023
047eb96
Support new notebooks URL (#94)
joshuali925 Apr 18, 2023
37694f6
Add release notes for 2.7.0 (#95)
rupal-bq Apr 18, 2023
d4d620b
update codeowners and maintainers (#101)
derek-ho Apr 26, 2023
3eb68dd
Add fix for CVE-2023-2251 (#102)
rupal-bq Apr 26, 2023
27c1375
add ani to codeowners and maintainers (#112)
derek-ho May 15, 2023
c8be18e
Increment version to 3.0.0.0 (#107)
opensearch-trigger-bot[bot] May 16, 2023
8fc8127
Add release notes for 2.8 (#124)
joshuali925 May 30, 2023
b505370
Add release notes for 1.3.10.0 (#115) (#116)
opensearch-trigger-bot[bot] Jun 8, 2023
2edde4b
Increment version to 3.0.0.0 (#120)
opensearch-trigger-bot[bot] Jun 9, 2023
9d17a87
Upgrade tough-cookie and semver (#135)
rupal-bq Jul 11, 2023
c3a0155
Add 2.9 release notes (#143)
kavithacm Jul 12, 2023
5f91f1a
Update breadcrumb title of isDashboardNavMenu (#142) (#147)
opensearch-trigger-bot[bot] Jul 12, 2023
362724c
bump word-wrap for cve fix (#154)
derek-ho Jul 31, 2023
5ceb55e
fail backport workflow (#156)
derek-ho Jul 31, 2023
2a4b9fc
Update backport CI, add PR merged condition (#167)
ps48 Aug 15, 2023
0c7dd27
Increment version to 3.0.0.0 (#158)
opensearch-trigger-bot[bot] Aug 21, 2023
13288ec
Make the generated report use the correct background color (#165)
AMoo-Miki Aug 31, 2023
24fdcbe
update search snapshots from upstream (#172)
derek-ho Sep 5, 2023
b3d9b73
Add @cypress/request resolution to fix CVE-2023-28155 (#174)
rupal-bq Sep 6, 2023
7b1fe25
Add 2.10 Release notes (#176) (#180)
opensearch-trigger-bot[bot] Sep 7, 2023
baafdf1
support reporting for new discover (#184)
joshuali925 Sep 15, 2023
629d88b
Fix reporting discover (#190) (#193)
opensearch-trigger-bot[bot] Sep 19, 2023
93a8704
Fix date format in csv files (#148)
kavithacm Oct 2, 2023
cb0dad6
Upgrade debug and other deps (#208)
pjfitzgibbons Oct 10, 2023
d9b4116
Support reporting in discover (#212) (#216)
opensearch-trigger-bot[bot] Oct 11, 2023
7ae02f0
Release Notes 2.11 (#217) (#219)
opensearch-trigger-bot[bot] Oct 12, 2023
9a37d7a
Upgrade traverse to address CVE-2023-45133, resolve debug for CVE-20…
derek-ho Oct 18, 2023
8cdb187
Use core navigation instead of hard coding URLs (#229)
derek-ho Oct 19, 2023
3b2ffdc
2.11 Bug fix for checking Date Field presence (#211) (#214)
opensearch-trigger-bot[bot] Oct 24, 2023
407edcd
added Timestamp Feature (#238)
marcohald Nov 1, 2023
a23dbbb
Bump browserify-sign (#240)
derek-ho Nov 1, 2023
47db578
Onboard jenkins prod docker images to github actions (#243)
peterzhuamazon Nov 2, 2023
1dea183
[Bug fix] Update the dependencies in `.babelrc` (#260)
RyanL1997 Dec 15, 2023
8f35526
[CI/CD] Add E2E Cypress workflow for Dashboards Reporting (#262)
RyanL1997 Dec 18, 2023
65d1a62
[CI/CD] Add FTR e2e test workflow for dashboards reporting (#264)
RyanL1997 Dec 19, 2023
cdaa926
Sync dependencies with latest versions (#268)
RyanL1997 Jan 9, 2024
09cb4c1
[Bug Fix] Fix the bootstrap failure on the fresh run (#270)
RyanL1997 Jan 9, 2024
a33c80c
[CI/CD] Add eslint workflow (#273)
RyanL1997 Jan 16, 2024
67f5dc1
added release notes for 2.12 (#286)
sumukhswamy Feb 12, 2024
0441f07
fix (#290)
sumukhswamy Feb 13, 2024
58d52f7
Nav menu length check (#295) (#295)
gulderov Feb 16, 2024
69f6da8
allow negative signs in duration (#284)
joshuali925 Feb 19, 2024
617881a
Add single version flag during bootstrap to fix version conflicts (#303)
RyanL1997 Feb 19, 2024
2d39d24
Fix condition to determine if the date field's value is an array (#299)
rupal-bq Feb 20, 2024
a9c0c95
Add workflow to verify binary installation is successful (#313)
derek-ho Feb 23, 2024
a811806
Add xlsx support (#275)
gulderov Mar 5, 2024
e2fe9a0
fix menu cut off (#315)
gulderov Mar 11, 2024
2f7ae07
added release notes (#326)
sumukhswamy Mar 19, 2024
d2a3cfa
Update showdown.js (#334)
Swiddis Apr 12, 2024
76c567f
Add 2.14.0 release notes (#348)
rupal-bq Apr 30, 2024
105f68c
Fix url parsing (#353)
rupal-bq May 7, 2024
985e623
Add release note for 2.15.0 (#362)
rupal-bq Jun 10, 2024
cc1b533
[Navigation] Register all plugins to NavGroups (#369)
TackAdam Jul 18, 2024
dc43243
[Look&Feel] Adjust header and text sizes in reporting menu options (#…
zhongnansu Jul 22, 2024
a98564e
Update dependency jsdom to v17 (#378)
mend-for-github-com[bot] Jul 22, 2024
7843bd3
Update dependency jsdom to v18 (#381)
mend-for-github-com[bot] Jul 22, 2024
84c72ff
Update dependency ws to v7.5.10 (#385)
rupal-bq Jul 22, 2024
46b28db
Add braces resolution to fix CVE-2024-4068 (#388)
rupal-bq Jul 22, 2024
af864d3
Add v2.16.0 release notes (#390)
rupal-bq Jul 23, 2024
ff37ada
Use smaller and compressed varients of buttons and form components (#…
AMoo-Miki Aug 19, 2024
0af5edd
[Enhancement] De-register reporting when MDS is enabled (#411)
sumukhswamy Aug 28, 2024
20dea69
[Bugfix] Update UI and handle new navigation (#416)
TackAdam Sep 5, 2024
ea9254e
remove line (#419)
TackAdam Sep 5, 2024
09ccd1a
added release notes for 2.17 (#420)
sumukhswamy Sep 5, 2024
f9a236d
Upgrade micromatch to 4.0.8 (#423)
ps48 Sep 6, 2024
d4f95c9
[Feature] Add the ability to configure record limit/count from the UI…
szkly Sep 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .cypress/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
module.exports = {
root: true,
extends: ['plugin:cypress/recommended'],
env: {
'cypress/globals': true,
},
plugins: ['cypress'],
rules: {
// Add cypress specific rules here
'cypress/no-assigning-return-values': 'error',
'cypress/no-unnecessary-waiting': 'error',
'cypress/assertion-before-screenshot': 'warn',
'cypress/no-force': 'warn',
'cypress/no-async-tests': 'error',
},
};

2 changes: 1 addition & 1 deletion .cypress/integration/02-edit.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ describe('Cypress', () => {
cy.wait(1000);

// update the report name
cy.get('#reportSettingsName').type(' update name');
cy.get('#reportSettingsName').type(' update name', { force: true });

// update report description
cy.get('#reportSettingsDescription').type(' update description');
Expand Down
33 changes: 17 additions & 16 deletions .cypress/integration/04-download.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@ describe('Cypress', () => {
);

cy.wait(12500);
cy.get('#landingPageOnDemandDownload').click({ force: true });
cy.get('body').then($body => {
if ($body.find('#downloadInProgressLoadingModal').length > 0) {
return;
}
else {
assert(false);
}
})
cy.get('[id="landingPageOnDemandDownload"]')
.contains('CSV')
.click({ force: true });
cy.get('.euiToastHeader__title')
.contains('Successfully downloaded report')
.should('exist');
});

it('Download pdf from in-context menu', () => {
Expand All @@ -33,7 +30,7 @@ describe('Cypress', () => {
// click Reporting in-context menu
cy.get('#downloadReport > span:nth-child(1) > span:nth-child(1)').click({ force: true });

// download PDF
// download PDF
cy.get('#generatePDF > span:nth-child(1) > span:nth-child(2)').click({ force: true });

cy.get('#reportGenerationProgressModal');
Expand All @@ -59,7 +56,7 @@ describe('Cypress', () => {
cy.wait(5000);

// open saved search list
cy.get('button.euiButtonEmpty:nth-child(3) > span:nth-child(1) > span:nth-child(1)').click({ force: true });
cy.get('[data-test-subj="discoverOpenButton"]').click({ force: true });
cy.wait(5000);

// click first entry
Expand All @@ -72,7 +69,7 @@ describe('Cypress', () => {
});

it('Download from Report definition details page', () => {
// create an on-demand report definition
// create an on-demand report definition

cy.visit(`${Cypress.env('opensearchDashboards')}/app/reports-dashboards#/`);
cy.location('pathname', { timeout: 60000 }).should(
Expand All @@ -81,14 +78,18 @@ describe('Cypress', () => {
);
cy.wait(10000);

cy.get('tr.euiTableRow-isSelectable:nth-child(1) > td:nth-child(1) > div:nth-child(2) > button:nth-child(1)').first().click();
cy.get('tr.euiTableRow-isSelectable:nth-child(1) > td:nth-child(1) > div:nth-child(2) > button:nth-child(1)').first().click();

cy.url().should('include', 'report_definition_details');

cy.get('#generateReportFromDetailsButton').should('exist');
cy.wait(5000);

cy.get('#generateReportFromDetailsFileFormat').should('exist');

cy.get('#generateReportFromDetailsButton').click({ force: true });
cy.get('#generateReportFromDetailsFileFormat').click({ force: true });

cy.get('#downloadInProgressLoadingModal');
cy.get('.euiToastHeader__title')
.contains('Successfully generated report')
.should('exist');
});
});
7 changes: 7 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
node_modules
/data
/build
/target
/.eslintrc.js
/cypress.config.js
!.cypress/
9 changes: 0 additions & 9 deletions .eslintrc

This file was deleted.

59 changes: 59 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
/*
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/

const LICENSE_HEADER = `/*
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/`;

module.exports = {
root: true,
extends: [
'@elastic/eslint-config-kibana',
'plugin:@elastic/eui/recommended',
'plugin:react-hooks/recommended',
'plugin:jest/recommended',
'plugin:prettier/recommended',
],

rules: {
'@typescript-eslint/no-unused-vars': [
'error',
{
argsIgnorePattern: '^_',
varsIgnorePattern: '^_',
caughtErrorsIgnorePattern: '^_',
},
],
'@osd/eslint/no-restricted-paths': [
'error',
{
basePath: __dirname,
zones: [
{
target: ['(public|server)/**/*'],
from: ['../../packages/**/*','packages/**/*'],
},
],
},
],
},
overrides: [
{
files: ['**/*.{js,ts,tsx}'],
rules: {
'@typescript-eslint/no-explicit-any': 'warn',
'no-console': 0,
'@osd/eslint/require-license-header': [
'error',
{
licenses: [LICENSE_HEADER],
},
],
},
},
],
"ignorePatterns": ["**/*.d.ts"]
};
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# This should match the owning team set up in https://github.com/orgs/opensearch-project/teams
* @opensearch-project/dashboards-reports
* @pjfitzgibbons @ps48 @kavithacm @derek-ho @joshuali925 @dai-chen @YANG-DB @rupal-bq @mengweieric @vamsi-amazon @swiddis @penghuo @seankao-az @anirudha
19 changes: 19 additions & 0 deletions .github/workflows/add-untriaged.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Apply 'untriaged' label during issue lifecycle

on:
issues:
types: [opened, reopened, transferred]

jobs:
apply-label:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v6
with:
script: |
github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: ['untriaged']
})
6 changes: 4 additions & 2 deletions .github/workflows/backport.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:

jobs:
backport:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
permissions:
contents: write
Expand All @@ -22,7 +23,8 @@ jobs:
installation_id: 22958780

- name: Backport
uses: VachaShah/backport@v1.1.4
uses: VachaShah/backport@v2.2.0
with:
github_token: ${{ steps.github_app_token.outputs.token }}
branch_name: backport/backport-${{ github.event.number }}
head_template: backport/backport-<%= number %>-to-<%= base %>
failure_labels: backport-failed
168 changes: 168 additions & 0 deletions .github/workflows/cypress-e2e-reporting-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
name: Cypress E2E Dashboards Reporting Plugin Test

on: [pull_request, push]

env:
CI: 1
# avoid warnings like "tput: No value for $TERM and no -T specified"
TERM: xterm
OPENSEARCH_DASHBOARDS_VERSION: 'main'
OPENSEARCH_VERSION: '3.0.0'
OPENSEARCH_PLUGIN_VERSION: '3.0.0.0'
PLUGIN_NAME: dashboards-reporting

jobs:
tests:
name: Run Cypress E2E Dashboards Reporting Plugin Tests
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest ]
jdk: [ 11 ]
runs-on: ${{ matrix.os }}

steps:
- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.jdk }}

- name: Download Job Scheduler artifact
uses: suisei-cn/[email protected]
with:
url: https://aws.oss.sonatype.org/service/local/artifact/maven/redirect?r=snapshots&g=org.opensearch.plugin&a=opensearch-job-scheduler&v=${{ env.OPENSEARCH_PLUGIN_VERSION }}-SNAPSHOT&p=zip
target: plugin-artifacts/
filename: job-scheduler.zip

- name: Download Reports Scheduler artifact
uses: suisei-cn/[email protected]
with:
url: https://aws.oss.sonatype.org/service/local/artifact/maven/redirect?r=snapshots&g=org.opensearch.plugin&a=opensearch-reports-scheduler&v=${{ env.OPENSEARCH_PLUGIN_VERSION }}-SNAPSHOT&p=zip
target: plugin-artifacts/
filename: reports-scheduler.zip

- name: Download OpenSearch
uses: peternied/download-file@v2
with:
url: https://artifacts.opensearch.org/snapshots/core/opensearch/${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/opensearch-min-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT-linux-x64-latest.tar.gz

- name: Extract OpenSearch
run: |
tar -xzf opensearch-*.tar.gz
rm -f opensearch-*.tar.gz
shell: bash

- name: Install Job Scheduler
run: |
/bin/bash -c "yes | ./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/bin/opensearch-plugin install file:$(pwd)/plugin-artifacts/job-scheduler.zip"
shell: bash

- name: Install Reports Scheduler
run: |
/bin/bash -c "yes | ./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/bin/opensearch-plugin install file:$(pwd)/plugin-artifacts/reports-scheduler.zip"
shell: bash

- name: Run OpenSearch
run: |
/bin/bash -c "./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/bin/opensearch &"
sleep 30
shell: bash

- name: Check OpenSearch Running on Linux
if: ${{ runner.os != 'Windows'}}
run: curl http://localhost:9200/
shell: bash

- name: Show OpenSearch Logs
if: always()
run: cat ./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/logs/opensearch.log
shell: bash

- name: Checkout OpenSearch Dashboards
uses: actions/checkout@v2
with:
path: OpenSearch-Dashboards
repository: opensearch-project/OpenSearch-Dashboards
ref: ${{ env.OPENSEARCH_DASHBOARDS_VERSION }}
fetch-depth: 0
filter: |
cypress
test

- name: Checkout Dashboards Reporting Plugin in OpenSearch Dashboards Plugins Dir
uses: actions/checkout@v2
with:
path: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}

- id: tool-versions
run: |
echo "node_version=$(cat .node-version)" >> $GITHUB_OUTPUT
echo "yarn_version=$(jq -r '.engines.yarn' package.json)" >> $GITHUB_OUTPUT
working-directory: OpenSearch-Dashboards
shell: bash

- uses: actions/setup-node@v1
with:
node-version: ${{ steps.tool-versions.outputs.node_version }}
registry-url: 'https://registry.npmjs.org'

- name: Setup Opensearch Dashboards
run: |
npm uninstall -g yarn
echo "Installing yarn ${{ steps.tool-versions.outputs.yarn_version }}"
npm i -g yarn@${{ steps.tool-versions.outputs.yarn_version }}
yarn cache clean
working-directory: OpenSearch-Dashboards
shell: bash

- name: Boodstrap Opensearch Dashboards
run: |
yarn osd bootstrap --single-version=loose
working-directory: OpenSearch-Dashboards

- name: Run Opensearch Dashboards with Dashboards Reporting Plugin Installed
run: |
nohup yarn start --no-base-path --no-watch | tee dashboard.log &
working-directory: OpenSearch-Dashboards

- name : Check If OpenSearch Dashboards Is Ready
if: ${{ runner.os == 'Linux' }}
run: |
if timeout 600 grep -q "bundles compiled successfully after" <(tail -n0 -f dashboard.log); then
echo "OpenSearch Dashboards compiled successfully."
else
echo "Timeout for 600 seconds reached. OpenSearch Dashboards did not finish compiling."
exit 1
fi
working-directory: OpenSearch-Dashboards

- name: Install Cypress
run: |
npx cypress install
shell: bash
working-directory: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}

- name: Get Cypress version
id: cypress_version
run: |
echo "::set-output name=cypress_version::$(cat ./package.json | jq '.dependencies.cypress' | tr -d '"')"
working-directory: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}

- name: Run Cypress tests
run: |
yarn cypress:run --browser chrome --headless
working-directory: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}

- name: Capture failure screenshots
uses: actions/upload-artifact@v1
if: failure()
with:
name: cypress-screenshots-${{ matrix.os }}
path: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}/.cypress/screenshots

- name: Capture test video
uses: actions/upload-artifact@v1
if: failure()
with:
name: cypress-videos-${{ matrix.os }}
path: OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}/.cypress/videos
Loading
Loading