-
Notifications
You must be signed in to change notification settings - Fork 894
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
Bump Node.js from 14 to 18 Proposal #3601
Comments
How to bump to node.js 18 using node-sassSteps
Need to fix the type errors. The 3 errors in src/core/server/status/status_service.ts by specifying return type. For example:
The error is due to a wrong path. ResultAfter step 10, OSD runs up successfully using v18.12.0. Run
Reference: |
Thanks @ananzh! This is great.
Can you add the list of dependent packages you are aware of?
Looks like the 10-13% startup slow down is addressed here. We should confirm though. But even if not, the pros of the upgrade outweigh the con. |
Changed dependency packages
Performance compareFrom the following compare, we could see node.js v14.20.1 does 49 bundle using 138.1 sec and v18.15.0 (latest v18 LTS) does 48 bundles with 53 sec (This has one less bundle because I removed
|
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Dev errorBuild and Verify on Linux error
Monaco build errorMonaco uses a different build script and
|
[Unit test] async handle issue
After fixing, see errors on Windows:
Analysis and ReproductionTo debug in RxJs observables, two things are useful:
After debug, found out the stuck place is this
This
It seems that To confirm this hypothesis, we could try to reproduce the issue in a simple standalone script using Node.js 14 and Node.js 18. If the issue only occurs with Node.js 18, it would be reasonable to assume that the problem is related to changes in the newer version of Node.js. Let's create a test:
The result:
Well, it seems the issue is not with SolutionsChange to synchronous methodTo resolve this issue, we used the synchronous version of readFile, called readFileSync. This function reads the file content in a synchronous manner, meaning it blocks the execution of the code until the read operation is completed. Since this function doesn't rely on callbacks or Promises, it is not affected by the same issues as the asynchronous version when used with mock-fs.
Pass a default
|
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com>
DeprecationsSee some deprecation msg when running tests.
|
Revert "add node fiber to improve performance (opensearch-project#2319)" Revert "[CVE-2022-25758] Use dart-sass instead of node-sass (opensearch-project#2054)" Revert back to use node-sass and bump to 8.0.0 Change lmdb-store to lmdb Bump node.js to 18 and fix errors Issue Resolved: opensearch-project#3601 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Fix async unit test timeout issue Signed-off-by: Anan Zhuang <ananzh@amazon.com> [Nodejs 18] fix lmdb and plugins discovery unit tests Signed-off-by: Anan Zhuang <ananzh@amazon.com> Fix windows path Signed-off-by: Anan Zhuang <ananzh@amazon.com> Increase memory limit for unit test and fix memory leak Signed-off-by: Anan Zhuang <ananzh@amazon.com>
[Unit test] memory leak
First of all, fix any memory leak. I see some memory leak on
The memory leak issue might be caused by updating the component's state after the component has been unmounted. When a component gets unmounted, it's removed from the DOM, but if there's a pending async operation that tries to update the component's state, it can cause a memory leak. Here the Solution is to add
Second, increase memory allocation
|
[Unit test] lmdb can't be recognized
|
[Mocha test] a flaky test
|
[Integration test] receive 500 response (local+remote build)
The issue occurs because in The By removing either the In conclusion, it's better to keep the
|
[BWC Test] Fail due to
|
[Integration Test]
|
const { error, status, stdout, stderr } = spawnSync( |
By adding console logs in the test
describe('cli invalid config support', function () {
it(
'exits with statusCode 64 and logs a single line when config is invalid',
function () {
// Unused keys only throw once LegacyService starts, so disable migrations so that Core
// will finish the start lifecycle without a running OpenSearch instance.
// eslint-disable-next-line no-console
console.log('REPO_ROOT is:', REPO_ROOT); // Added log
// eslint-disable-next-line no-console
console.log('INVALID_CONFIG_PATH is:', INVALID_CONFIG_PATH); // Added log
const { error, status, stdout, stderr } = spawnSync(
process.execPath,
[
'scripts/opensearch_dashboards',
'--config',
INVALID_CONFIG_PATH,
'--migrations.skip=true',
],
{
cwd: REPO_ROOT,
}
);
// eslint-disable-next-line no-console
console.log('spawnSync error is:', error); // Added log
// eslint-disable-next-line no-console
console.log('spawnSync stdout is:', stdout.toString('utf8')); // Added log
// eslint-disable-next-line no-console
console.log('spawnSync stderr is:', stderr.toString('utf8')); // Added log
const [fatalLogLine] = stdout
.toString('utf8')
.split('\n')
.filter(Boolean)
.map((line) => JSON.parse(line) as LogEntry)
.filter((line) => line.tags.includes('fatal'))
.map((obj) => ({
...obj,
pid: '## PID ##',
'@timestamp': '## @timestamp ##',
error: '## Error with stack trace ##',
}));
expect(error).toBe(undefined);
if (!fatalLogLine) {
throw new Error(
`cli did not log the expected fatal error message:\n\nstdout: \n${stdout}\n\nstderr:\n${stderr}`
);
}
expect(fatalLogLine.message).toContain(
'Error: Unknown configuration key(s): "unknown.key", "other.unknown.key", "other.third", "some.flat.key", ' +
'"some.array". Check for spelling errors and ensure that expected plugins are installed.'
);
expect(fatalLogLine.tags).toEqual(['fatal', 'root']);
expect(fatalLogLine.type).toEqual('log');
expect(status).toBe(64);
},
20 * 1000
);
});
And see the logs in the Github env:
yarn run v1.22.10
$ scripts/use_node scripts/jest_integration --ci --colors
console.log
REPO_ROOT is: D:\a\OpenSearch-Dashboards\OpenSearch-Dashboards
at Object.<anonymous> (src/cli/serve/integration_tests/invalid_config.test.ts:51:15)
console.log
INVALID_CONFIG_PATH is: D:\a\OpenSearch-Dashboards\OpenSearch-Dashboards\src\cli\serve\integration_tests\__fixtures__\invalid_config.yml
at Object.<anonymous> (src/cli/serve/integration_tests/invalid_config.test.ts:53:15)
Error: The operation was canceled.
It shows clearly that this script doesn’t terminate correctly or hangs which causes the child process never finishes in the GitHub environment.
@peterzhuamazon i found that node18 can be built from source on centos 7, it runs ok and doesn't require glibc > 2.17. but centos 7 build tools need to be updated ❯ objdump -T ./node | awk '{print $5}' | grep -i glibc | sort | uniq
GLIBC_2.10
GLIBC_2.14
GLIBC_2.16
GLIBC_2.17
GLIBC_2.2.5
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_2.6
GLIBC_2.7
GLIBC_2.9
GLIBCXX_3.4
GLIBCXX_3.4.11
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.18
GLIBCXX_3.4.9 build script used cat << 'EOF' | docker build -t nodejs - && docker create --name nodejs nodejs && docker cp nodejs:/build/nodejs . && docker rm nodejs && docker rmi nodejs
FROM centos:7
WORKDIR /build
ENV NODE_VERSION=v18.15.0
RUN yum install -y centos-release-scl-rh centos-release-scl && \
yum install -y devtoolset-11-gcc devtoolset-11-gcc-c++ devtoolset-11-make python3 python3-pip && \
source /opt/rh/devtoolset-11/enable && \
curl -sL -o- https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION.tar.xz | tar -xJv && cd node-$NODE_VERSION && \
./configure --prefix=$PWD/../node-$NODE_VERSION-linux-$(arch) && make -j $(nproc) && make install && cd .. && \
strip ./node-$NODE_VERSION-linux-$(arch)/bin/node && \
mkdir -p nodejs && tar cvzf nodejs/node-$NODE_VERSION-linux-$(arch).tar.gz ./node-$NODE_VERSION-linux-$(arch)
EOF If we need to run this on older systems probably need to build a custom version of node. i'm not sure if there will be significant performance differences or other issues due to lower glibc version used to compile |
…inishing opensearch-project#3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com>
…inishing opensearch-project#3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com>
* Bump Node.js requirements to 18 Signed-off-by: Miki <miki@amazon.com> * Replace `lmdb-store` with `lmdb` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump `elastic-apm-node` to the latest minor Signed-off-by: Miki <miki@amazon.com> * Replace webpack and plugins with a patched version that uses xxhash64 * Use `xxhash64` as the hashing algorithm of webpack * Upgrade `globby` * Remove `fibers` Signed-off-by: Miki <miki@amazon.com> * Replace `fs.rmdir` with `fs.rm` in cross-platform tests Signed-off-by: Miki <miki@amazon.com> * Increase listener limit Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add promise-stripping serializer Signed-off-by: Miki <miki@amazon.com> * Bump heap for CI Signed-off-by: Miki <miki@amazon.com> * Correct use of fs/promises in @osd/pm Signed-off-by: Miki <miki@amazon.com> * Use fs/promise in plugin post-install cleanup Signed-off-by: Miki <miki@amazon.com> * Set the test server's host to `0.0.0.0` Signed-off-by: Miki <miki@amazon.com> * Sync `.node-version` file Signed-off-by: Miki <miki@amazon.com> * Support both `isPrimary`, for Node 18, and `isMaster`, for Node 14 Signed-off-by: Miki <miki@amazon.com> * Add types when using `isDeepStrictEqual` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add names to `SchemaError` to log more specific errors Signed-off-by: Miki <miki@amazon.com> * Fix failing vega visualization tests outside the CI Signed-off-by: Miki <miki@amazon.com> * Fix snapshot of errors thrown for undefined accessors Signed-off-by: Miki <miki@amazon.com> * Fix flakiness of log_rotator Signed-off-by: Miki <miki@amazon.com> * Fix asynchronous `fs` usafe in plugin discover Signed-off-by: Miki <miki@amazon.com> * Fix mocks in @osd/optimizer Signed-off-by: Miki <miki@amazon.com> * Fix memory leaks caused by setting states on unloaded components Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump Node in Dockerfile Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove the response `close` event as an indicator of the requesting finishing #3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * [BWC] Timeout after 3 mins of waiting for OSD to be running in tests Signed-off-by: Miki <miki@amazon.com> * Make build use the same node version that tests are run against Signed-off-by: Miki <miki@amazon.com> * Make Node resolve DNS by IPv4 first * This is helpful to resolve `locahost` to `127.0.0.1` Signed-off-by: Miki <miki@amazon.com> * Standardize patterns used by plugin discovery * Enhance absolute path serialization on Windows Signed-off-by: Miki <amoo_miki@yahoo.com> * Mock fetch in SenseEditor tests Signed-off-by: Miki <amoo_miki@yahoo.com> * Restore node-sass usage to fix build performance * `sass-loader@10` is the last version that supports webpack@4 * `sass` is extremely slow when using the legacy API (`render`) and to use the "Modern API" (`compileStringAsync`), `sass-loader@13` would be needed. * The performance of `sass@10` is made acceptable only with `fibers` but that is deprecated and doesn't work on Node 18 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Revert "[CI] setup Chrome and utilize binary path (#3997)" This reverts commit 0188d05 Signed-off-by: Miki <miki@amazon.com> * Prevent fast-fail while running functional test in CI Signed-off-by: Miki <miki@amazon.com> * Revert "Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976)" This reverts commit 5ea0cbe. Signed-off-by: Miki <miki@amazon.com> * Save Cypress results artifacts during CI Signed-off-by: Miki <miki@amazon.com> * Add missing required dependency on `set-value` * Also force all to ^4.1.0 due to a vulnerability fixed in 3.1.0. Signed-off-by: Miki <miki@amazon.com> * Prevent multiple calls to bootstrap's shutdown Signed-off-by: Miki <miki@amazon.com> * Use Node 18.16.0 in distributions * Bump jest-canvas-mock to fix failing tests * Extend Node engines versions Signed-off-by: Miki <miki@amazon.com> * Normalize test snapshots across Node 14, 16, and 18 Signed-off-by: Miki <miki@amazon.com> * Update CHANGELOG for Node.js >=14.20.1 <19 support Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com>
* Bump Node.js requirements to 18 Signed-off-by: Miki <miki@amazon.com> * Replace `lmdb-store` with `lmdb` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump `elastic-apm-node` to the latest minor Signed-off-by: Miki <miki@amazon.com> * Replace webpack and plugins with a patched version that uses xxhash64 * Use `xxhash64` as the hashing algorithm of webpack * Upgrade `globby` * Remove `fibers` Signed-off-by: Miki <miki@amazon.com> * Replace `fs.rmdir` with `fs.rm` in cross-platform tests Signed-off-by: Miki <miki@amazon.com> * Increase listener limit Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add promise-stripping serializer Signed-off-by: Miki <miki@amazon.com> * Bump heap for CI Signed-off-by: Miki <miki@amazon.com> * Correct use of fs/promises in @osd/pm Signed-off-by: Miki <miki@amazon.com> * Use fs/promise in plugin post-install cleanup Signed-off-by: Miki <miki@amazon.com> * Set the test server's host to `0.0.0.0` Signed-off-by: Miki <miki@amazon.com> * Sync `.node-version` file Signed-off-by: Miki <miki@amazon.com> * Support both `isPrimary`, for Node 18, and `isMaster`, for Node 14 Signed-off-by: Miki <miki@amazon.com> * Add types when using `isDeepStrictEqual` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add names to `SchemaError` to log more specific errors Signed-off-by: Miki <miki@amazon.com> * Fix failing vega visualization tests outside the CI Signed-off-by: Miki <miki@amazon.com> * Fix snapshot of errors thrown for undefined accessors Signed-off-by: Miki <miki@amazon.com> * Fix flakiness of log_rotator Signed-off-by: Miki <miki@amazon.com> * Fix asynchronous `fs` usafe in plugin discover Signed-off-by: Miki <miki@amazon.com> * Fix mocks in @osd/optimizer Signed-off-by: Miki <miki@amazon.com> * Fix memory leaks caused by setting states on unloaded components Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump Node in Dockerfile Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove the response `close` event as an indicator of the requesting finishing opensearch-project#3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * [BWC] Timeout after 3 mins of waiting for OSD to be running in tests Signed-off-by: Miki <miki@amazon.com> * Make build use the same node version that tests are run against Signed-off-by: Miki <miki@amazon.com> * Make Node resolve DNS by IPv4 first * This is helpful to resolve `locahost` to `127.0.0.1` Signed-off-by: Miki <miki@amazon.com> * Standardize patterns used by plugin discovery * Enhance absolute path serialization on Windows Signed-off-by: Miki <amoo_miki@yahoo.com> * Mock fetch in SenseEditor tests Signed-off-by: Miki <amoo_miki@yahoo.com> * Restore node-sass usage to fix build performance * `sass-loader@10` is the last version that supports webpack@4 * `sass` is extremely slow when using the legacy API (`render`) and to use the "Modern API" (`compileStringAsync`), `sass-loader@13` would be needed. * The performance of `sass@10` is made acceptable only with `fibers` but that is deprecated and doesn't work on Node 18 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Revert "[CI] setup Chrome and utilize binary path (opensearch-project#3997)" This reverts commit 0188d05 Signed-off-by: Miki <miki@amazon.com> * Prevent fast-fail while running functional test in CI Signed-off-by: Miki <miki@amazon.com> * Revert "Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (opensearch-project#3976)" This reverts commit 5ea0cbe. Signed-off-by: Miki <miki@amazon.com> * Save Cypress results artifacts during CI Signed-off-by: Miki <miki@amazon.com> * Add missing required dependency on `set-value` * Also force all to ^4.1.0 due to a vulnerability fixed in 3.1.0. Signed-off-by: Miki <miki@amazon.com> * Prevent multiple calls to bootstrap's shutdown Signed-off-by: Miki <miki@amazon.com> * Use Node 18.16.0 in distributions * Bump jest-canvas-mock to fix failing tests * Extend Node engines versions Signed-off-by: Miki <miki@amazon.com> * Normalize test snapshots across Node 14, 16, and 18 Signed-off-by: Miki <miki@amazon.com> * Update CHANGELOG for Node.js >=14.20.1 <19 support Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com>
* Add support for Node.js >=14.20.1 <19 (#4071) * Bump Node.js requirements to 18 Signed-off-by: Miki <miki@amazon.com> * Replace `lmdb-store` with `lmdb` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump `elastic-apm-node` to the latest minor Signed-off-by: Miki <miki@amazon.com> * Replace webpack and plugins with a patched version that uses xxhash64 * Use `xxhash64` as the hashing algorithm of webpack * Upgrade `globby` * Remove `fibers` Signed-off-by: Miki <miki@amazon.com> * Replace `fs.rmdir` with `fs.rm` in cross-platform tests Signed-off-by: Miki <miki@amazon.com> * Increase listener limit Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add promise-stripping serializer Signed-off-by: Miki <miki@amazon.com> * Bump heap for CI Signed-off-by: Miki <miki@amazon.com> * Correct use of fs/promises in @osd/pm Signed-off-by: Miki <miki@amazon.com> * Use fs/promise in plugin post-install cleanup Signed-off-by: Miki <miki@amazon.com> * Set the test server's host to `0.0.0.0` Signed-off-by: Miki <miki@amazon.com> * Sync `.node-version` file Signed-off-by: Miki <miki@amazon.com> * Support both `isPrimary`, for Node 18, and `isMaster`, for Node 14 Signed-off-by: Miki <miki@amazon.com> * Add types when using `isDeepStrictEqual` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add names to `SchemaError` to log more specific errors Signed-off-by: Miki <miki@amazon.com> * Fix failing vega visualization tests outside the CI Signed-off-by: Miki <miki@amazon.com> * Fix snapshot of errors thrown for undefined accessors Signed-off-by: Miki <miki@amazon.com> * Fix flakiness of log_rotator Signed-off-by: Miki <miki@amazon.com> * Fix asynchronous `fs` usafe in plugin discover Signed-off-by: Miki <miki@amazon.com> * Fix mocks in @osd/optimizer Signed-off-by: Miki <miki@amazon.com> * Fix memory leaks caused by setting states on unloaded components Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump Node in Dockerfile Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove the response `close` event as an indicator of the requesting finishing #3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * [BWC] Timeout after 3 mins of waiting for OSD to be running in tests Signed-off-by: Miki <miki@amazon.com> * Make build use the same node version that tests are run against Signed-off-by: Miki <miki@amazon.com> * Make Node resolve DNS by IPv4 first * This is helpful to resolve `locahost` to `127.0.0.1` Signed-off-by: Miki <miki@amazon.com> * Standardize patterns used by plugin discovery * Enhance absolute path serialization on Windows Signed-off-by: Miki <amoo_miki@yahoo.com> * Mock fetch in SenseEditor tests Signed-off-by: Miki <amoo_miki@yahoo.com> * Restore node-sass usage to fix build performance * `sass-loader@10` is the last version that supports webpack@4 * `sass` is extremely slow when using the legacy API (`render`) and to use the "Modern API" (`compileStringAsync`), `sass-loader@13` would be needed. * The performance of `sass@10` is made acceptable only with `fibers` but that is deprecated and doesn't work on Node 18 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Revert "[CI] setup Chrome and utilize binary path (#3997)" This reverts commit 0188d05 Signed-off-by: Miki <miki@amazon.com> * Prevent fast-fail while running functional test in CI Signed-off-by: Miki <miki@amazon.com> * Revert "Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976)" This reverts commit 5ea0cbe. Signed-off-by: Miki <miki@amazon.com> * Save Cypress results artifacts during CI Signed-off-by: Miki <miki@amazon.com> * Add missing required dependency on `set-value` * Also force all to ^4.1.0 due to a vulnerability fixed in 3.1.0. Signed-off-by: Miki <miki@amazon.com> * Prevent multiple calls to bootstrap's shutdown Signed-off-by: Miki <miki@amazon.com> * Use Node 18.16.0 in distributions * Bump jest-canvas-mock to fix failing tests * Extend Node engines versions Signed-off-by: Miki <miki@amazon.com> * Normalize test snapshots across Node 14, 16, and 18 Signed-off-by: Miki <miki@amazon.com> * Update CHANGELOG for Node.js >=14.20.1 <19 support Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Set node version to 16.x Signed-off-by: Kawika Avilla <kavilla414@gmail.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Kawika Avilla <kavilla414@gmail.com> Co-authored-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com>
* Fix header icon (#3910) (#3915) * fixes header change * Update src/core/public/chrome/ui/header/header_help_menu.tsx * fixes snapshots --------- (cherry picked from commit 3cca088) Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Add server side private IP blocking for data source endpoints validation (#3912) Signed-off-by: Kristen Tian <tyarong@amazon.com> * Docs (Jest): Update jest documentation links (#3931) Signed-off-by: Josh Romero <rmerqg@amazon.com> * Revert "[CCI] Replace jquery usage in console plugin with native methods (#3733)" (#3929) This reverts commit ffe4556. * [BUG][Dashboard listing] push to history if dashboard otherwise nav (#3922) History push will just to the current route. However, dashboardsProvider was implemented with the expectation that it was a different app. So when a plugin registered it was attempting to navigate to `app/dashboard#/app/{url}` Add tests and extra data test subject. Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * remove jquery console release note for #3929 revert (#3930) Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Ashwin P Chandran <ashwinpc@amazon.com> * [CCI] Update js-yaml to v4.0.5 (#3770) * Update js-yaml to 4.0.5 (#3659) * Update CHANGELOG.md (#3659) Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> --------- Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Update README.md (#3788) * Update README.md Signed-off-by: Melissa Vagi <vagimeli@amazon.com> * Update README.md Co-authored-by: Miki <amoo_miki@yahoo.com> --------- Signed-off-by: Melissa Vagi <vagimeli@amazon.com> Co-authored-by: Miki <miki@amazon.com> Co-authored-by: Miki <amoo_miki@yahoo.com> * Bump yaml to 2.2.2 (#3947) Signed-off-by: Manasvini B Suryanarayana <manasvis@amazon.com> Co-authored-by: Sean Neumann <1413295+seanneumann@users.noreply.github.com> * Bump `joi` to v14 to avoid the possibility of prototype poisoning in a nested dependency (#3952) Signed-off-by: Miki <miki@amazon.com> * [Doc] Add communication guide (#3837) * docs(COMMUNICATION): Add communication guide with info on slack, forum, and developer office hours link from README, CONTRIBUTING, DEVELOPER_GUIDE Signed-off-by: Josh Romero <rmerqg@amazon.com> --------- Signed-off-by: Josh Romero <rmerqg@amazon.com> * Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976) The latest version of chromedriver is 112.0.1 which does not support node 14. This PR hardcodes chromedriver to 112.0.0 temporarily. Pls revert it once we bump to node 18. Issue Resolved #3975 Signed-off-by: ananzh <ananzh@amazon.com> * Fix wording and duplicate code in embeddable example plugin (#3911) * Fix wording and duplicate code in embeddable example plugin Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> * Fix some wording in the embeddable readme Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> --------- Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> * [CI] setup Chrome and utilize binary path (#3997) Within the CI, the virtual runner that we are utilizing has Chrome installed already. The version of Chrome is installed periodically. The most recent version of Chrome requires updates to dependencies that drop support for Node 14. This downloads chrome in the CI and then checks the chromedriver from the environment variable `TEST_BROWSER_BINARY_PATH`. Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * [Dashboards listing] fix listing limit (#4021) Initial page size was passed to the search function instead of the listing limit causing the max amount received to be significantly less than the previously implementation. Saved objects per page is `20` by default and the listing limit per page is `1000` by default. Issue: #4017 Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * [CCI] Fix EUI/OUI type errors (#3798) * Update find_test_subject imports for tests Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Update to available imports for findTestSubject Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Fix available import for Query and custom icon Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Add changelog entry Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Add ts-ignore Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> --------- Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com> * Fix bottom bar visibility using create portal (#3336) (#3978) Signed-off-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Andrey Myssak <andreymyssak@gmail.com> * Adds threshold to code coverage changes for project (#4040) * Fixes code coverage workflow failures for the project test due to inderect flakey changes Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Adds changelog Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> --------- Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Updates PR template for screenshots and test instructions (#4042) Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Replace re2 with RegExp in timeline and add unit tests (#3908) Remove re2 usage and replace it with JavaScript built-in RegExp object. Also add more unit tests to make sure that using RegExp has same expressions as using re2 library. Issue Resolve #3901 Signed-off-by: Anan Zhuang <ananzh@amazon.com> * [Console] [CCI] Remove unused ul element and its custom styling. (#3993) * remove unused ul element Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Update CHANGELOG.md Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> --------- Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Add 1.3.10 release note (#4060) (#4063) * Add release note for 1.3.10 * Address comments and add one CVE PR --------- (cherry picked from commit 4371587) Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> * [Multiple Datasource] Support Amazon OpenSearch Serverless (#3957) * [Multiple Datasource]Support Amazon OpenSearch Serverless in SigV4 * remove experimental text in yml * Refactor create data source form for authentication Signed-off-by: Su <szhongna@amazon.com> * Remove Sass from `tile_map` plugin (#4110) * Remove Sass from tile_map plugin Signed-off-by: Matt Provost <provomat@amazon.com> * Update changelog Signed-off-by: Matt Provost <provomat@amazon.com> --------- Signed-off-by: Matt Provost <provomat@amazon.com> * Design for New Saved Object Service Interface for Custom Repository (#3954) * Adds design document for new saved object service interface for custom repository Signed-off-by: Bandini Bhopi <bandinib@amazon.com> * enhance grouping for context menu options (#3924) * enhance grouping for context menu options * build panels tests and more comments Signed-off-by: David Sinclair <dsincla@rei.com> --------- Signed-off-by: David Sinclair <david@sinclair.tech> Signed-off-by: David Sinclair <dsincla@rei.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Adding Tao and Zilong to MAINTAINERS (#4137) * Adding Tao and Zilong to MAINTAINERS Signed-off-by: Yan Zeng <zengyan@amazon.com> * [MD]Update data-test-subj for functional tests & fix bug in edit flow (#4126) Signed-off-by: Su <szhongna@amazon.com> * Add support for Node.js >=14.20.1 <19 (#4071) * Bump Node.js requirements to 18 Signed-off-by: Miki <miki@amazon.com> * Replace `lmdb-store` with `lmdb` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump `elastic-apm-node` to the latest minor Signed-off-by: Miki <miki@amazon.com> * Replace webpack and plugins with a patched version that uses xxhash64 * Use `xxhash64` as the hashing algorithm of webpack * Upgrade `globby` * Remove `fibers` Signed-off-by: Miki <miki@amazon.com> * Replace `fs.rmdir` with `fs.rm` in cross-platform tests Signed-off-by: Miki <miki@amazon.com> * Increase listener limit Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add promise-stripping serializer Signed-off-by: Miki <miki@amazon.com> * Bump heap for CI Signed-off-by: Miki <miki@amazon.com> * Correct use of fs/promises in @osd/pm Signed-off-by: Miki <miki@amazon.com> * Use fs/promise in plugin post-install cleanup Signed-off-by: Miki <miki@amazon.com> * Set the test server's host to `0.0.0.0` Signed-off-by: Miki <miki@amazon.com> * Sync `.node-version` file Signed-off-by: Miki <miki@amazon.com> * Support both `isPrimary`, for Node 18, and `isMaster`, for Node 14 Signed-off-by: Miki <miki@amazon.com> * Add types when using `isDeepStrictEqual` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add names to `SchemaError` to log more specific errors Signed-off-by: Miki <miki@amazon.com> * Fix failing vega visualization tests outside the CI Signed-off-by: Miki <miki@amazon.com> * Fix snapshot of errors thrown for undefined accessors Signed-off-by: Miki <miki@amazon.com> * Fix flakiness of log_rotator Signed-off-by: Miki <miki@amazon.com> * Fix asynchronous `fs` usafe in plugin discover Signed-off-by: Miki <miki@amazon.com> * Fix mocks in @osd/optimizer Signed-off-by: Miki <miki@amazon.com> * Fix memory leaks caused by setting states on unloaded components Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump Node in Dockerfile Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove the response `close` event as an indicator of the requesting finishing #3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * [BWC] Timeout after 3 mins of waiting for OSD to be running in tests Signed-off-by: Miki <miki@amazon.com> * Make build use the same node version that tests are run against Signed-off-by: Miki <miki@amazon.com> * Make Node resolve DNS by IPv4 first * This is helpful to resolve `locahost` to `127.0.0.1` Signed-off-by: Miki <miki@amazon.com> * Standardize patterns used by plugin discovery * Enhance absolute path serialization on Windows Signed-off-by: Miki <amoo_miki@yahoo.com> * Mock fetch in SenseEditor tests Signed-off-by: Miki <amoo_miki@yahoo.com> * Restore node-sass usage to fix build performance * `sass-loader@10` is the last version that supports webpack@4 * `sass` is extremely slow when using the legacy API (`render`) and to use the "Modern API" (`compileStringAsync`), `sass-loader@13` would be needed. * The performance of `sass@10` is made acceptable only with `fibers` but that is deprecated and doesn't work on Node 18 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Revert "[CI] setup Chrome and utilize binary path (#3997)" This reverts commit 0188d05 Signed-off-by: Miki <miki@amazon.com> * Prevent fast-fail while running functional test in CI Signed-off-by: Miki <miki@amazon.com> * Revert "Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976)" This reverts commit 5ea0cbe. Signed-off-by: Miki <miki@amazon.com> * Save Cypress results artifacts during CI Signed-off-by: Miki <miki@amazon.com> * Add missing required dependency on `set-value` * Also force all to ^4.1.0 due to a vulnerability fixed in 3.1.0. Signed-off-by: Miki <miki@amazon.com> * Prevent multiple calls to bootstrap's shutdown Signed-off-by: Miki <miki@amazon.com> * Use Node 18.16.0 in distributions * Bump jest-canvas-mock to fix failing tests * Extend Node engines versions Signed-off-by: Miki <miki@amazon.com> * Normalize test snapshots across Node 14, 16, and 18 Signed-off-by: Miki <miki@amazon.com> * Update CHANGELOG for Node.js >=14.20.1 <19 support Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove timeline application (#3971) * Remove timeline application In this PR, we made the following changes: First of all, clean out some advanced settings specific to timeline application and tests. * Remove timelion:default_rows: This setting defines the default number of rows that a new Timelion sheet should have. * Remove timelion:default_rows: This setting defines the default number of columns that a new Timelion sheet should have. * Remove timelion:showTutorial. Second, remove src/plugin/timeline completely and modify timeline vis. Third, remove all the functional tests related to timeline application. Issue resolve #3519 #3593 Signed-off-by: ananzh <ananzh@amazon.com> --------- Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: ananzh <ananzh@amazon.com> * Use `exec` in the CLI shell scripts to prevent new process creation (#3955) Signed-off-by: Miki <miki@amazon.com> * chore (lychee): Add company.net to exclusion list (#4171) Signed-off-by: Josh Romero <rmerqg@amazon.com> * Bundle Node 14 as a fallback for operating systems that cannot run Node 18 (#4151) Signed-off-by: ananzh <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Refactor authentication description message (#4179) resolves #4173 Signed-off-by: Su <szhongna@amazon.com> --------- Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Signed-off-by: Kristen Tian <tyarong@amazon.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Signed-off-by: Kawika Avilla <kavilla414@gmail.com> Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> Signed-off-by: Melissa Vagi <vagimeli@amazon.com> Signed-off-by: Manasvini B Suryanarayana <manasvis@amazon.com> Signed-off-by: Miki <miki@amazon.com> Signed-off-by: ananzh <ananzh@amazon.com> Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> Signed-off-by: Sergey Myssak <sergey.myssak@gmail.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> Signed-off-by: Su <szhongna@amazon.com> Signed-off-by: Matt Provost <provomat@amazon.com> Signed-off-by: Bandini Bhopi <bandinib@amazon.com> Signed-off-by: David Sinclair <david@sinclair.tech> Signed-off-by: David Sinclair <dsincla@rei.com> Signed-off-by: Yan Zeng <zengyan@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Ashish Agrawal <ashisagr@amazon.com> Co-authored-by: opensearch-trigger-bot[bot] <98922864+opensearch-trigger-bot[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Kristen Tian <105667444+kristenTian@users.noreply.github.com> Co-authored-by: Kawika Avilla <kavilla414@gmail.com> Co-authored-by: Ashwin P Chandran <ashwinpc@amazon.com> Co-authored-by: Andrey Myssak <40265277+andreymyssak@users.noreply.github.com> Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Melissa Vagi <vagimeli@amazon.com> Co-authored-by: Miki <miki@amazon.com> Co-authored-by: Miki <amoo_miki@yahoo.com> Co-authored-by: Manasvini B Suryanarayana <manasvis@amazon.com> Co-authored-by: Sean Neumann <1413295+seanneumann@users.noreply.github.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com> Co-authored-by: Alexei Karikov <karikov.alist.ru@gmail.com> Co-authored-by: Andrey Myssak <andreymyssak@gmail.com> Co-authored-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> Co-authored-by: Zhongnan Su <szhongna@amazon.com> Co-authored-by: Matt Provost <provomat@amazon.com> Co-authored-by: Bandini <63824432+bandinib-amzn@users.noreply.github.com> Co-authored-by: David Sinclair <24573542+sikhote@users.noreply.github.com> Co-authored-by: Yan Zeng <46499415+zengyan-amazon@users.noreply.github.com>
* Fix header icon (#3910) (#3915) * fixes header change * Update src/core/public/chrome/ui/header/header_help_menu.tsx * fixes snapshots --------- (cherry picked from commit 3cca088) Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Add server side private IP blocking for data source endpoints validation (#3912) Signed-off-by: Kristen Tian <tyarong@amazon.com> * Docs (Jest): Update jest documentation links (#3931) Signed-off-by: Josh Romero <rmerqg@amazon.com> * Revert "[CCI] Replace jquery usage in console plugin with native methods (#3733)" (#3929) This reverts commit ffe4556. * [BUG][Dashboard listing] push to history if dashboard otherwise nav (#3922) History push will just to the current route. However, dashboardsProvider was implemented with the expectation that it was a different app. So when a plugin registered it was attempting to navigate to `app/dashboard#/app/{url}` Add tests and extra data test subject. Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * remove jquery console release note for #3929 revert (#3930) Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Ashwin P Chandran <ashwinpc@amazon.com> * [CCI] Update js-yaml to v4.0.5 (#3770) * Update js-yaml to 4.0.5 (#3659) * Update CHANGELOG.md (#3659) Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> --------- Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Update README.md (#3788) * Update README.md Signed-off-by: Melissa Vagi <vagimeli@amazon.com> * Update README.md Co-authored-by: Miki <amoo_miki@yahoo.com> --------- Signed-off-by: Melissa Vagi <vagimeli@amazon.com> Co-authored-by: Miki <miki@amazon.com> Co-authored-by: Miki <amoo_miki@yahoo.com> * Bump yaml to 2.2.2 (#3947) Signed-off-by: Manasvini B Suryanarayana <manasvis@amazon.com> Co-authored-by: Sean Neumann <1413295+seanneumann@users.noreply.github.com> * Bump `joi` to v14 to avoid the possibility of prototype poisoning in a nested dependency (#3952) Signed-off-by: Miki <miki@amazon.com> * [Doc] Add communication guide (#3837) * docs(COMMUNICATION): Add communication guide with info on slack, forum, and developer office hours link from README, CONTRIBUTING, DEVELOPER_GUIDE Signed-off-by: Josh Romero <rmerqg@amazon.com> --------- Signed-off-by: Josh Romero <rmerqg@amazon.com> * Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976) The latest version of chromedriver is 112.0.1 which does not support node 14. This PR hardcodes chromedriver to 112.0.0 temporarily. Pls revert it once we bump to node 18. Issue Resolved #3975 Signed-off-by: ananzh <ananzh@amazon.com> * Fix wording and duplicate code in embeddable example plugin (#3911) * Fix wording and duplicate code in embeddable example plugin Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> * Fix some wording in the embeddable readme Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> --------- Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> * [CI] setup Chrome and utilize binary path (#3997) Within the CI, the virtual runner that we are utilizing has Chrome installed already. The version of Chrome is installed periodically. The most recent version of Chrome requires updates to dependencies that drop support for Node 14. This downloads chrome in the CI and then checks the chromedriver from the environment variable `TEST_BROWSER_BINARY_PATH`. Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * [Dashboards listing] fix listing limit (#4021) Initial page size was passed to the search function instead of the listing limit causing the max amount received to be significantly less than the previously implementation. Saved objects per page is `20` by default and the listing limit per page is `1000` by default. Issue: #4017 Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * [CCI] Fix EUI/OUI type errors (#3798) * Update find_test_subject imports for tests Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Update to available imports for findTestSubject Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Fix available import for Query and custom icon Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Add changelog entry Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Add ts-ignore Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> --------- Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com> * Fix bottom bar visibility using create portal (#3336) (#3978) Signed-off-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Andrey Myssak <andreymyssak@gmail.com> * Adds threshold to code coverage changes for project (#4040) * Fixes code coverage workflow failures for the project test due to inderect flakey changes Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Adds changelog Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> --------- Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Updates PR template for screenshots and test instructions (#4042) Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> * Replace re2 with RegExp in timeline and add unit tests (#3908) Remove re2 usage and replace it with JavaScript built-in RegExp object. Also add more unit tests to make sure that using RegExp has same expressions as using re2 library. Issue Resolve #3901 Signed-off-by: Anan Zhuang <ananzh@amazon.com> * [Console] [CCI] Remove unused ul element and its custom styling. (#3993) * remove unused ul element Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Update CHANGELOG.md Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> --------- Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Add 1.3.10 release note (#4060) (#4063) * Add release note for 1.3.10 * Address comments and add one CVE PR --------- (cherry picked from commit 4371587) Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> * [Multiple Datasource] Support Amazon OpenSearch Serverless (#3957) * [Multiple Datasource]Support Amazon OpenSearch Serverless in SigV4 * remove experimental text in yml * Refactor create data source form for authentication Signed-off-by: Su <szhongna@amazon.com> * Remove Sass from `tile_map` plugin (#4110) * Remove Sass from tile_map plugin Signed-off-by: Matt Provost <provomat@amazon.com> * Update changelog Signed-off-by: Matt Provost <provomat@amazon.com> --------- Signed-off-by: Matt Provost <provomat@amazon.com> * Design for New Saved Object Service Interface for Custom Repository (#3954) * Adds design document for new saved object service interface for custom repository Signed-off-by: Bandini Bhopi <bandinib@amazon.com> * enhance grouping for context menu options (#3924) * enhance grouping for context menu options * build panels tests and more comments Signed-off-by: David Sinclair <dsincla@rei.com> --------- Signed-off-by: David Sinclair <david@sinclair.tech> Signed-off-by: David Sinclair <dsincla@rei.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> * Adding Tao and Zilong to MAINTAINERS (#4137) * Adding Tao and Zilong to MAINTAINERS Signed-off-by: Yan Zeng <zengyan@amazon.com> * [MD]Update data-test-subj for functional tests & fix bug in edit flow (#4126) Signed-off-by: Su <szhongna@amazon.com> * Add support for Node.js >=14.20.1 <19 (#4071) * Bump Node.js requirements to 18 Signed-off-by: Miki <miki@amazon.com> * Replace `lmdb-store` with `lmdb` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump `elastic-apm-node` to the latest minor Signed-off-by: Miki <miki@amazon.com> * Replace webpack and plugins with a patched version that uses xxhash64 * Use `xxhash64` as the hashing algorithm of webpack * Upgrade `globby` * Remove `fibers` Signed-off-by: Miki <miki@amazon.com> * Replace `fs.rmdir` with `fs.rm` in cross-platform tests Signed-off-by: Miki <miki@amazon.com> * Increase listener limit Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add promise-stripping serializer Signed-off-by: Miki <miki@amazon.com> * Bump heap for CI Signed-off-by: Miki <miki@amazon.com> * Correct use of fs/promises in @osd/pm Signed-off-by: Miki <miki@amazon.com> * Use fs/promise in plugin post-install cleanup Signed-off-by: Miki <miki@amazon.com> * Set the test server's host to `0.0.0.0` Signed-off-by: Miki <miki@amazon.com> * Sync `.node-version` file Signed-off-by: Miki <miki@amazon.com> * Support both `isPrimary`, for Node 18, and `isMaster`, for Node 14 Signed-off-by: Miki <miki@amazon.com> * Add types when using `isDeepStrictEqual` Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Add names to `SchemaError` to log more specific errors Signed-off-by: Miki <miki@amazon.com> * Fix failing vega visualization tests outside the CI Signed-off-by: Miki <miki@amazon.com> * Fix snapshot of errors thrown for undefined accessors Signed-off-by: Miki <miki@amazon.com> * Fix flakiness of log_rotator Signed-off-by: Miki <miki@amazon.com> * Fix asynchronous `fs` usafe in plugin discover Signed-off-by: Miki <miki@amazon.com> * Fix mocks in @osd/optimizer Signed-off-by: Miki <miki@amazon.com> * Fix memory leaks caused by setting states on unloaded components Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Bump Node in Dockerfile Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove the response `close` event as an indicator of the requesting finishing #3601 (comment) Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * [BWC] Timeout after 3 mins of waiting for OSD to be running in tests Signed-off-by: Miki <miki@amazon.com> * Make build use the same node version that tests are run against Signed-off-by: Miki <miki@amazon.com> * Make Node resolve DNS by IPv4 first * This is helpful to resolve `locahost` to `127.0.0.1` Signed-off-by: Miki <miki@amazon.com> * Standardize patterns used by plugin discovery * Enhance absolute path serialization on Windows Signed-off-by: Miki <amoo_miki@yahoo.com> * Mock fetch in SenseEditor tests Signed-off-by: Miki <amoo_miki@yahoo.com> * Restore node-sass usage to fix build performance * `sass-loader@10` is the last version that supports webpack@4 * `sass` is extremely slow when using the legacy API (`render`) and to use the "Modern API" (`compileStringAsync`), `sass-loader@13` would be needed. * The performance of `sass@10` is made acceptable only with `fibers` but that is deprecated and doesn't work on Node 18 Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Revert "[CI] setup Chrome and utilize binary path (#3997)" This reverts commit 0188d05 Signed-off-by: Miki <miki@amazon.com> * Prevent fast-fail while running functional test in CI Signed-off-by: Miki <miki@amazon.com> * Revert "Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests (#3976)" This reverts commit 5ea0cbe. Signed-off-by: Miki <miki@amazon.com> * Save Cypress results artifacts during CI Signed-off-by: Miki <miki@amazon.com> * Add missing required dependency on `set-value` * Also force all to ^4.1.0 due to a vulnerability fixed in 3.1.0. Signed-off-by: Miki <miki@amazon.com> * Prevent multiple calls to bootstrap's shutdown Signed-off-by: Miki <miki@amazon.com> * Use Node 18.16.0 in distributions * Bump jest-canvas-mock to fix failing tests * Extend Node engines versions Signed-off-by: Miki <miki@amazon.com> * Normalize test snapshots across Node 14, 16, and 18 Signed-off-by: Miki <miki@amazon.com> * Update CHANGELOG for Node.js >=14.20.1 <19 support Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Miki <miki@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> * Remove timeline application (#3971) * Remove timeline application In this PR, we made the following changes: First of all, clean out some advanced settings specific to timeline application and tests. * Remove timelion:default_rows: This setting defines the default number of rows that a new Timelion sheet should have. * Remove timelion:default_rows: This setting defines the default number of columns that a new Timelion sheet should have. * Remove timelion:showTutorial. Second, remove src/plugin/timeline completely and modify timeline vis. Third, remove all the functional tests related to timeline application. Issue resolve #3519 #3593 Signed-off-by: ananzh <ananzh@amazon.com> --------- Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: ananzh <ananzh@amazon.com> * Use `exec` in the CLI shell scripts to prevent new process creation (#3955) Signed-off-by: Miki <miki@amazon.com> * chore (lychee): Add company.net to exclusion list (#4171) Signed-off-by: Josh Romero <rmerqg@amazon.com> * Bundle Node 14 as a fallback for operating systems that cannot run Node 18 (#4151) Signed-off-by: ananzh <ananzh@amazon.com> Signed-off-by: Miki <miki@amazon.com> * Refactor authentication description message (#4179) resolves #4173 Signed-off-by: Su <szhongna@amazon.com> * [CI] skip checksum verification for cypress tests (#4188) Snapshot checksum verification caused failure in test runs: #4187 Skipping the verification to enable the tests run as the snapshot of OpenSearch should not impact the tests. Issue: n/a Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * Adds plugin manifest config to define OpenSearch plugin dependency and verifies if it is installed (#3116) Resolves Issue -#2799 Signed-off-by: Manasvini B Suryanarayana <manasvis@amazon.com> * [Table Visualization] Remove custom styling for text-align:center in favor of OUI utility class. (#4164) * remove custom styling in favor of oui utility class Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Update CHANGELOG.md Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> --------- Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> * Add new MAINTAINERS to CODEOWNERS file (#4199) * Add new code owners Signed-off-by: Tao Liu <liutaoaz@amazon.com> * modify changelog.md Signed-off-by: Tao Liu <liutaoaz@amazon.com> --------- Signed-off-by: Tao Liu <liutaoaz@amazon.com> * Add 2.8.0 release notes (#4204) * Add 2.8.0 release notes Co-authored-by: Josh Romero <rmerqg@amazon.com> Signed-off-by: Kawika Avilla <kavilla414@gmail.com> * Chore(CHANGELOG): Update with 2.7, 2.8 releases (#3890) * Chore(CHANGELOG): Update with 2.7 release * align changelog with 2.8 release notes * update 2.8 release notes * add 1.3.10 release notes to changelog --------- Signed-off-by: Josh Romero <rmerqg@amazon.com> * [Saved Object Service] Adds Repository Factory Provider (#4149) * Adds Repository Factory Provider Signed-off-by: Bandini Bhopi <bandinib@amazon.com> * add category option for context menus (#4144) * enhance grouping for context menu options Signed-off-by: David Sinclair <david@sinclair.tech> * change log Signed-off-by: David Sinclair <david@sinclair.tech> * remove type export Signed-off-by: David Sinclair <david@sinclair.tech> * revert border and prevent destroy options Signed-off-by: David Sinclair <david@sinclair.tech> * update comments for building panels Signed-off-by: David Sinclair <dsincla@rei.com> * build panels tests and more comments Signed-off-by: David Sinclair <dsincla@rei.com> * add category option for context menus Signed-off-by: David Sinclair <dsincla@rei.com> * changelog Signed-off-by: David Sinclair <dsincla@rei.com> * add order to groups Signed-off-by: David Sinclair <dsincla@rei.com> * documentation, shorter copyrighty, minor cleanup Signed-off-by: David Sinclair <dsincla@rei.com> * changelog Signed-off-by: David Sinclair <dsincla@rei.com> --------- Signed-off-by: David Sinclair <david@sinclair.tech> Signed-off-by: David Sinclair <dsincla@rei.com> Signed-off-by: Ashish Agrawal <ashish81394@gmail.com> Co-authored-by: Ashish Agrawal <ashish81394@gmail.com> * [CCI] Add bluebird replaces for src/plugins/saved_objects (#4026) * Add bluebird replaces for src/plugins/saved_objects * Add changelog entry --------- Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> * Validate and correct change log after 2.8 release (#4275) Signed-off-by: Su <szhongna@amazon.com> --------- Signed-off-by: Ashwin P Chandran <ashwinpc@amazon.com> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Signed-off-by: Kristen Tian <tyarong@amazon.com> Signed-off-by: Josh Romero <rmerqg@amazon.com> Signed-off-by: Kawika Avilla <kavilla414@gmail.com> Signed-off-by: Andrey Myssak <andreymyssak@gmail.com> Signed-off-by: Melissa Vagi <vagimeli@amazon.com> Signed-off-by: Manasvini B Suryanarayana <manasvis@amazon.com> Signed-off-by: Miki <miki@amazon.com> Signed-off-by: ananzh <ananzh@amazon.com> Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com> Signed-off-by: Alexei Karikov <karikov.alist.ru@gmail.com> Signed-off-by: Sergey Myssak <sergey.myssak@gmail.com> Signed-off-by: Anan Zhuang <ananzh@amazon.com> Signed-off-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> Signed-off-by: Su <szhongna@amazon.com> Signed-off-by: Matt Provost <provomat@amazon.com> Signed-off-by: Bandini Bhopi <bandinib@amazon.com> Signed-off-by: David Sinclair <david@sinclair.tech> Signed-off-by: David Sinclair <dsincla@rei.com> Signed-off-by: Yan Zeng <zengyan@amazon.com> Signed-off-by: Miki <amoo_miki@yahoo.com> Signed-off-by: Tao Liu <liutaoaz@amazon.com> Signed-off-by: Ashish Agrawal <ashish81394@gmail.com> Signed-off-by: Ashish Agrawal <ashisagr@amazon.com> Co-authored-by: opensearch-trigger-bot[bot] <98922864+opensearch-trigger-bot[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Kristen Tian <105667444+kristenTian@users.noreply.github.com> Co-authored-by: Kawika Avilla <kavilla414@gmail.com> Co-authored-by: Ashwin P Chandran <ashwinpc@amazon.com> Co-authored-by: Andrey Myssak <40265277+andreymyssak@users.noreply.github.com> Co-authored-by: Sergey Myssak <sergey.myssak@gmail.com> Co-authored-by: Melissa Vagi <vagimeli@amazon.com> Co-authored-by: Miki <miki@amazon.com> Co-authored-by: Miki <amoo_miki@yahoo.com> Co-authored-by: Manasvini B Suryanarayana <manasvis@amazon.com> Co-authored-by: Sean Neumann <1413295+seanneumann@users.noreply.github.com> Co-authored-by: Anan Zhuang <ananzh@amazon.com> Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com> Co-authored-by: Alexei Karikov <karikov.alist.ru@gmail.com> Co-authored-by: Andrey Myssak <andreymyssak@gmail.com> Co-authored-by: Sirazh Gabdullin <sirazh.gabdullin@nu.edu.kz> Co-authored-by: Zhongnan Su <szhongna@amazon.com> Co-authored-by: Matt Provost <provomat@amazon.com> Co-authored-by: Bandini <63824432+bandinib-amzn@users.noreply.github.com> Co-authored-by: David Sinclair <24573542+sikhote@users.noreply.github.com> Co-authored-by: Yan Zeng <46499415+zengyan-amazon@users.noreply.github.com> Co-authored-by: Tao Liu <33105471+Flyingliuhub@users.noreply.github.com>
Background
This is a proposal to bump Node.js from 14 to 18. Major concern is the security support. Based on the announcement of nodejs [1], here is a list of end of security support for different node.js package.
Node.js 14 (LTS): Security Support Ends in 1 month on 30 Apr 2023
Node.js 16 (LTS): Security Support Ends in 6 months on 11 Sep 2023
Node.js 18 (LTS): Security Support Ends in 2 years on 30 Apr 2025
Node.js 19 (latest version but no LTS): Security Support Ends in 3 months on 01 Jun 2023
The best one we could do is version 18.
Pros and Cons of 18
Pros [2],[3]
Cons
Upgrade Propsal
There are some detail proposals to bump to node.js 18. The main difference is the sass package we use. Currently, we are using
dart-sass
(#2054). To improve dart sass performance, we brought infibers
package (https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2319
). However,fibers
is no longer maintained and it doesn't support node.js 18. When bump to 18, you will see the following errorsTherefore, I propose to either go back to
node-sass
or usesass-embedded
.Proposal-1 Bump node-sass to v8.0.0 which supports node.js 18. Then bump node.js to 18.
node-sass
is deprecated but still maintained. It recently released v8.0.0 [8], about 4 months ago, to support node.js v18.sass-loader
also patch the latest 10.4.1, 4 months ago, to supportnode-sass
v8.0.0 [9].pros
node-sass
before.cons
node-sass
is deprecated which means there is new features, no further improvement on the performance.Proposal-2 Use the latest
sass-embedded
and bump webpack from v4 to v5. Then bump node.js to 18.This approach requires to bump sass-loader to v12.6.0+ which is the version that starts to support sass-embedded. Then we will observe the following errors during bootstrap:
This error needs us to bump webpack to 5 [5].
pros
sass-embedded
to improve performance:Unlike the existing JS-compiled version, this will use the Dart VM. Due to the more static nature of the Dart language, the Dart VM runs Sass substantially faster than Node.js, which will provide about a 2x speed improvement for large stylesheets.
[6]cons
Proposal-3 Bump to a
sass-embedded
that supports webpack v4. Then bump to node.js 18.Well, this is not a working proposal. With my research and implementation, I found the bottleneck is not
sass-embedded
which does not have a request on webpack version, it issass-loader
.sass-loader
supportssass-embedded
since 12.5.0 [7] but version 11.0.0 is the last version that supports Webpack 4. If we need to use Webpack 4, you should install sass-loader version 11.0.0 or an earlier version.Summary
Using
sass-embedded
can improve performance but it requires us to bump webpack to v5. We should discuss whether we want to put upgrading to webpack 5 in our long term roadmap. Right now, seems proposal-1 is our only option to upgrade node.js to version 18 before 4/30/2023.Reference
[1] https://endoflife.date/nodejs
[2] https://nodesource.com/blog/11-features-nodeJS-18-to-try
[3] https://nodejs.org/de/blog/announcements/v18-release-announce/
[4] nodejs/node#45662
[5] webpack-contrib/sass-loader#924
[6] https://sass-lang.com/blog/node-fibers-discontinued
[7] https://github.com/webpack-contrib/sass-loader/releases
[8] https://www.npmjs.com/package/node-sass?activeTab=versions
[9] https://github.com/webpack-contrib/sass-loader/releases
The text was updated successfully, but these errors were encountered: