Skip to content

Commit

Permalink
Elasticsearch v8 (#1558)
Browse files Browse the repository at this point in the history
  • Loading branch information
delvedor authored Sep 30, 2021
1 parent 4c72b98 commit 1a22745
Show file tree
Hide file tree
Showing 255 changed files with 36,930 additions and 42,043 deletions.
6 changes: 1 addition & 5 deletions .ci/run-repository.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ docker build \
echo -e "\033[1m>>>>> NPM run test:integration >>>>>>>>>>>>>>>>>>>>>>>>>>>>>\033[0m"

repo=$(realpath $(dirname $(realpath -s $0))/../)
run_script_args=""
if [[ "$NODE_JS_VERSION" == "8" ]]; then
run_script_args="--harmony-async-iteration"
fi

docker run \
--network=${network_name} \
Expand All @@ -44,4 +40,4 @@ docker run \
--name elasticsearch-js \
--rm \
elastic/elasticsearch-js \
node ${run_script_args} test/integration/index.js
npm run test:integration
278 changes: 137 additions & 141 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,147 +32,143 @@ jobs:
run: |
npm run test:unit
- name: Acceptance test
run: |
npm run test:acceptance
- name: Type Definitions
run: |
npm run test:types
helpers-integration-test:
name: Helpers integration test
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [12.x, 14.x, 16.x]

steps:
- uses: actions/checkout@v2

- name: Configure sysctl limits
run: |
sudo swapoff -a
sudo sysctl -w vm.swappiness=1
sudo sysctl -w fs.file-max=262144
sudo sysctl -w vm.max_map_count=262144
- name: Runs Elasticsearch
uses: elastic/elastic-github-actions/elasticsearch@master
with:
stack-version: 8.0.0-SNAPSHOT

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: Install
run: |
npm install
- name: Integration test
run: |
npm run test:integration:helpers
bundler-support:
name: Bundler support
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Configure sysctl limits
run: |
sudo swapoff -a
sudo sysctl -w vm.swappiness=1
sudo sysctl -w fs.file-max=262144
sudo sysctl -w vm.max_map_count=262144
- name: Runs Elasticsearch
uses: elastic/elastic-github-actions/elasticsearch@master
with:
stack-version: 8.0.0-SNAPSHOT

- name: Use Node.js 14.x
uses: actions/setup-node@v1
with:
node-version: 14.x

- name: Install
run: |
npm install
npm install --prefix test/bundlers/parcel-test
npm install --prefix test/bundlers/rollup-test
npm install --prefix test/bundlers/webpack-test
- name: Build
run: |
npm run build --prefix test/bundlers/parcel-test
npm run build --prefix test/bundlers/rollup-test
npm run build --prefix test/bundlers/webpack-test
- name: Run bundle
run: |
npm start --prefix test/bundlers/parcel-test
npm start --prefix test/bundlers/rollup-test
npm start --prefix test/bundlers/webpack-test
mock-support:
name: Mock support
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Use Node.js 14.x
uses: actions/setup-node@v1
with:
node-version: 14.x

- name: Install
run: |
npm install
npm install --prefix test/mock
- name: Run test
run: |
npm test --prefix test/mock
code-coverage:
name: Code coverage
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x]

steps:
- uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: Install
run: |
npm install
- name: Code coverage report
run: |
npm run test:coverage-report
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
file: ./coverage.lcov
fail_ci_if_error: true

- name: Code coverage 100%
run: |
npm run test:coverage-100
# - name: Acceptance test
# run: |
# npm run test:acceptance

# helpers-integration-test:
# name: Helpers integration test
# runs-on: ubuntu-latest

# strategy:
# matrix:
# node-version: [12.x, 14.x, 16.x]

# steps:
# - uses: actions/checkout@v2

# - name: Configure sysctl limits
# run: |
# sudo swapoff -a
# sudo sysctl -w vm.swappiness=1
# sudo sysctl -w fs.file-max=262144
# sudo sysctl -w vm.max_map_count=262144

# - name: Runs Elasticsearch
# uses: elastic/elastic-github-actions/elasticsearch@master
# with:
# stack-version: 8.0.0-SNAPSHOT

# - name: Use Node.js ${{ matrix.node-version }}
# uses: actions/setup-node@v1
# with:
# node-version: ${{ matrix.node-version }}

# - name: Install
# run: |
# npm install

# - name: Integration test
# run: |
# npm run test:integration:helpers

# bundler-support:
# name: Bundler support
# runs-on: ubuntu-latest

# steps:
# - uses: actions/checkout@v2

# - name: Configure sysctl limits
# run: |
# sudo swapoff -a
# sudo sysctl -w vm.swappiness=1
# sudo sysctl -w fs.file-max=262144
# sudo sysctl -w vm.max_map_count=262144

# - name: Runs Elasticsearch
# uses: elastic/elastic-github-actions/elasticsearch@master
# with:
# stack-version: 8.0.0-SNAPSHOT

# - name: Use Node.js 14.x
# uses: actions/setup-node@v1
# with:
# node-version: 14.x

# - name: Install
# run: |
# npm install
# npm install --prefix test/bundlers/parcel-test
# npm install --prefix test/bundlers/rollup-test
# npm install --prefix test/bundlers/webpack-test

# - name: Build
# run: |
# npm run build --prefix test/bundlers/parcel-test
# npm run build --prefix test/bundlers/rollup-test
# npm run build --prefix test/bundlers/webpack-test

# - name: Run bundle
# run: |
# npm start --prefix test/bundlers/parcel-test
# npm start --prefix test/bundlers/rollup-test
# npm start --prefix test/bundlers/webpack-test

# mock-support:
# name: Mock support
# runs-on: ubuntu-latest

# steps:
# - uses: actions/checkout@v2

# - name: Use Node.js 14.x
# uses: actions/setup-node@v1
# with:
# node-version: 14.x

# - name: Install
# run: |
# npm install
# npm install --prefix test/mock

# - name: Run test
# run: |
# npm test --prefix test/mock

# code-coverage:
# name: Code coverage
# runs-on: ubuntu-latest

# strategy:
# matrix:
# node-version: [14.x]

# steps:
# - uses: actions/checkout@v2

# - name: Use Node.js ${{ matrix.node-version }}
# uses: actions/setup-node@v1
# with:
# node-version: ${{ matrix.node-version }}

# - name: Install
# run: |
# npm install

# - name: Code coverage report
# run: |
# npm run test:coverage-report

# - name: Upload coverage to Codecov
# uses: codecov/codecov-action@v1
# with:
# file: ./coverage.lcov
# fail_ci_if_error: true

# - name: Code coverage 100%
# run: |
# npm run test:coverage-100

license:
name: License check
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,5 @@ test/benchmarks/macro/fixtures/*

test/bundlers/**/bundle.js
test/bundlers/parcel-test/.parcel-cache

lib
4 changes: 3 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ certs
CODE_OF_CONDUCT.md
CONTRIBUTING.md

src

# CANARY-PACKAGE
api/kibana.d.ts
lib/api/kibana.*
# /CANARY-PACKAGE
Loading

0 comments on commit 1a22745

Please sign in to comment.