Skip to content

Commit d0b0f48

Browse files
committed
Merge branch 'master' into issue-56872
2 parents 42cc892 + dd8eb62 commit d0b0f48

File tree

3,669 files changed

+77535
-54127
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,669 files changed

+77535
-54127
lines changed

.ci/end2end.groovy

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ pipeline {
2525
durabilityHint('PERFORMANCE_OPTIMIZED')
2626
}
2727
triggers {
28-
issueCommentTrigger('(?i).*jenkins\\W+run\\W+(?:the\\W+)?e2e(?:\\W+please)?.*')
28+
issueCommentTrigger('(?i)(retest|.*jenkins\\W+run\\W+(?:the\\W+)?e2e?.*)')
2929
}
3030
parameters {
3131
booleanParam(name: 'FORCE', defaultValue: false, description: 'Whether to force the run.')
@@ -60,8 +60,14 @@ pipeline {
6060
}
6161
}
6262
steps {
63+
notifyStatus('Starting services', 'PENDING')
6364
dir("${APM_ITS}"){
64-
sh './scripts/compose.py start master --no-kibana --no-xpack-secure'
65+
sh './scripts/compose.py start master --no-kibana'
66+
}
67+
}
68+
post {
69+
unsuccessful {
70+
notifyStatus('Environmental issue', 'FAILURE')
6571
}
6672
}
6773
}
@@ -77,10 +83,16 @@ pipeline {
7783
JENKINS_NODE_COOKIE = 'dontKillMe'
7884
}
7985
steps {
86+
notifyStatus('Preparing kibana', 'PENDING')
8087
dir("${BASE_DIR}"){
8188
sh script: "${CYPRESS_DIR}/ci/prepare-kibana.sh"
8289
}
8390
}
91+
post {
92+
unsuccessful {
93+
notifyStatus('Kibana warm up failed', 'FAILURE')
94+
}
95+
}
8496
}
8597
stage('Smoke Tests'){
8698
options { skipDefaultCheckout() }
@@ -91,6 +103,7 @@ pipeline {
91103
}
92104
}
93105
steps{
106+
notifyStatus('Running smoke tests', 'PENDING')
94107
dir("${BASE_DIR}"){
95108
sh '''
96109
jobs -l
@@ -112,6 +125,12 @@ pipeline {
112125
archiveArtifacts(allowEmptyArchive: false, artifacts: 'apm-its.log')
113126
}
114127
}
128+
unsuccessful {
129+
notifyStatus('Test failures', 'FAILURE')
130+
}
131+
success {
132+
notifyStatus('Tests passed', 'SUCCESS')
133+
}
115134
}
116135
}
117136
}
@@ -123,3 +142,7 @@ pipeline {
123142
}
124143
}
125144
}
145+
146+
def notifyStatus(String description, String status) {
147+
withGithubNotify.notify('end2end-for-apm-ui', description, status, getBlueoceanDisplayURL())
148+
}

.github/CODEOWNERS

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@
7272
# Observability UIs
7373
/x-pack/legacy/plugins/infra/ @elastic/logs-metrics-ui
7474
/x-pack/plugins/infra/ @elastic/logs-metrics-ui
75-
/x-pack/legacy/plugins/integrations_manager/ @elastic/epm
75+
/x-pack/plugins/ingest_manager/ @elastic/ingest
76+
/x-pack/legacy/plugins/ingest_manager/ @elastic/ingest
7677
/x-pack/plugins/observability/ @elastic/logs-metrics-ui @elastic/apm-ui @elastic/uptime @elastic/ingest
7778

7879
# Machine Learning
@@ -149,13 +150,15 @@
149150
# Kibana Alerting Services
150151
/x-pack/legacy/plugins/alerting/ @elastic/kibana-alerting-services
151152
/x-pack/legacy/plugins/actions/ @elastic/kibana-alerting-services
153+
/x-pack/plugins/alerting/ @elastic/kibana-alerting-services
152154
/x-pack/plugins/actions/ @elastic/kibana-alerting-services
153155
/x-pack/plugins/event_log/ @elastic/kibana-alerting-services
154156
/x-pack/plugins/task_manager/ @elastic/kibana-alerting-services
155157
/x-pack/test/alerting_api_integration/ @elastic/kibana-alerting-services
156158
/x-pack/test/plugin_api_integration/plugins/task_manager/ @elastic/kibana-alerting-services
157159
/x-pack/test/plugin_api_integration/test_suites/task_manager/ @elastic/kibana-alerting-services
158160
/x-pack/legacy/plugins/triggers_actions_ui/ @elastic/kibana-alerting-services
161+
/x-pack/plugins/triggers_actions_ui/ @elastic/kibana-alerting-services
159162
/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/ @elastic/kibana-alerting-services
160163
/x-pack/test/functional_with_es_ssl/fixtures/plugins/alerts/ @elastic/kibana-alerting-services
161164

@@ -170,8 +173,14 @@
170173
/x-pack/legacy/plugins/index_lifecycle_management/ @elastic/es-ui
171174
/x-pack/legacy/plugins/index_management/ @elastic/es-ui
172175
/x-pack/legacy/plugins/license_management/ @elastic/es-ui
173-
/x-pack/legacy/plugins/remote_clusters/ @elastic/es-ui
176+
/x-pack/plugins/remote_clusters/ @elastic/es-ui
174177
/x-pack/legacy/plugins/rollup/ @elastic/es-ui
175178
/x-pack/plugins/searchprofiler/ @elastic/es-ui
176179
/x-pack/legacy/plugins/snapshot_restore/ @elastic/es-ui
177180
/x-pack/plugins/watcher/ @elastic/es-ui
181+
182+
# Endpoint
183+
/x-pack/plugins/endpoint/ @elastic/endpoint-app-team
184+
/x-pack/test/api_integration/apis/endpoint/ @elastic/endpoint-app-team
185+
/x-pack/test/functional/apps/endpoint/ @elastic/endpoint-app-team
186+
/x-pack/test/functional/es_archives/endpoint/ @elastic/endpoint-app-team

CONTRIBUTING.md

Lines changed: 14 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,9 @@ Granted that you share your thoughts, we might even be able to come up with crea
5555

5656
First of all, **sorry about that!** We want you to have a great time with Kibana.
5757

58-
Hosting meaningful discussions on GitHub can be challenging. For that reason, we'll sometimes ask that you join us on IRC _([#kibana](https://kiwiirc.com/client/irc.freenode.net/?#kibana) on freenode)_ to chat about your issues. You may also experience **faster response times** when engaging us via IRC.
59-
6058
There's hundreds of open issues and prioritizing what to work on is an important aspect of our daily jobs. We prioritize issues according to impact and difficulty, so some issues can be neglected while we work on more pressing issues.
6159

62-
Feel free to bump your issues if you think they've been neglected for a prolonged period, or just jump on IRC and let us have it!
60+
Feel free to bump your issues if you think they've been neglected for a prolonged period.
6361

6462
### "I want to help!"
6563

@@ -471,11 +469,11 @@ The following table outlines possible test file locations and how to invoke them
471469

472470
| Test runner | Test location | Runner command (working directory is kibana root) |
473471
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- |
474-
| Jest | `src/**/*.test.js`<br>`src/**/*.test.ts` | `node scripts/jest -t regexp [test path]` |
475-
| Jest (integration) | `**/integration_tests/**/*.test.js` | `node scripts/jest_integration -t regexp [test path]` |
472+
| Jest | `src/**/*.test.js`<br>`src/**/*.test.ts` | `yarn test:jest -t regexp [test path]` |
473+
| Jest (integration) | `**/integration_tests/**/*.test.js` | `yarn test:jest_integration -t regexp [test path]` |
476474
| Mocha | `src/**/__tests__/**/*.js`<br>`!src/**/public/__tests__/*.js`<br>`packages/kbn-datemath/test/**/*.js`<br>`packages/kbn-dev-utils/src/**/__tests__/**/*.js`<br>`tasks/**/__tests__/**/*.js` | `node scripts/mocha --grep=regexp [test path]` |
477-
| Functional | `test/*integration/**/config.js`<br>`test/*functional/**/config.js`<br>`test/accessibility/config.js` | `node scripts/functional_tests_server --config test/[directory]/config.js`<br>`node scripts/functional_test_runner --config test/[directory]/config.js --grep=regexp` |
478-
| Karma | `src/**/public/__tests__/*.js` | `npm run test:dev` |
475+
| Functional | `test/*integration/**/config.js`<br>`test/*functional/**/config.js`<br>`test/accessibility/config.js` | `yarn test:ftr:server --config test/[directory]/config.js`<br>`yarn test:ftr:runner --config test/[directory]/config.js --grep=regexp` |
476+
| Karma | `src/**/public/__tests__/*.js` | `yarn test:karma:debug` |
479477

480478
For X-Pack tests located in `x-pack/` see [X-Pack Testing](x-pack/README.md#testing)
481479

@@ -486,56 +484,38 @@ Test runner arguments:
486484
Examples:
487485
- Run the entire elasticsearch_service test suite:
488486
```
489-
node scripts/jest src/core/server/elasticsearch/elasticsearch_service.test.ts
487+
yarn test:jest src/core/server/elasticsearch/elasticsearch_service.test.ts
490488
```
491489
- Run the jest test case whose description matches `stops both admin and data clients`:
492490
```
493-
node scripts/jest -t 'stops both admin and data clients' src/core/server/elasticsearch/elasticsearch_service.test.ts
491+
yarn test:jest -t 'stops both admin and data clients' src/core/server/elasticsearch/elasticsearch_service.test.ts
494492
```
495493
- Run the api integration test case whose description matches the given string:
496494
```
497-
node scripts/functional_tests_server --config test/api_integration/config.js
498-
node scripts/functional_test_runner --config test/api_integration/config.js --grep='should return 404 if id does not match any sample data sets'
495+
yarn test:ftr:server --config test/api_integration/config.js
496+
yarn test:ftr:runner --config test/api_integration/config.js --grep='should return 404 if id does not match any sample data sets'
499497
```
500498
501499
### Debugging Unit Tests
502500
503501
The standard `yarn test` task runs several sub tasks and can take several minutes to complete, making debugging failures pretty painful. In order to ease the pain specialized tasks provide alternate methods for running the tests.
504502
505-
To execute both server and browser tests, but skip linting, use `yarn test:quick`.
506-
507-
```bash
508-
yarn test:quick
509-
```
510-
511-
Use `yarn test:mocha` when you want to run the mocha tests.
512-
513-
```bash
514-
yarn test:mocha
515-
```
516-
517-
When you'd like to execute individual server-side test files, you can use the command below. Note that this command takes care of configuring Mocha with Babel compilation for you, and you'll be better off avoiding a globally installed `mocha` package. This command is great for development and for quickly identifying bugs.
518-
519-
```bash
520-
node scripts/mocha <file>
521-
```
522-
523503
You could also add the `--debug` option so that `node` is run using the `--debug-brk` flag. You'll need to connect a remote debugger such as [`node-inspector`](https://github.com/node-inspector/node-inspector) to proceed in this mode.
524504
525505
```bash
526506
node scripts/mocha --debug <file>
527507
```
528508

529-
With `yarn test:browser`, you can run only the browser tests. Coverage reports are available for browser tests by running `yarn test:coverage`. You can find the results under the `coverage/` directory that will be created upon completion.
509+
With `yarn test:karma`, you can run only the browser tests. Coverage reports are available for browser tests by running `yarn test:coverage`. You can find the results under the `coverage/` directory that will be created upon completion.
530510

531511
```bash
532-
yarn test:browser
512+
yarn test:karma
533513
```
534514

535-
Using `yarn test:dev` initializes an environment for debugging the browser tests. Includes an dedicated instance of the kibana server for building the test bundle, and a karma server. When running this task the build is optimized for the first time and then a karma-owned instance of the browser is opened. Click the "debug" button to open a new tab that executes the unit tests.
515+
Using `yarn test:karma:debug` initializes an environment for debugging the browser tests. Includes an dedicated instance of the kibana server for building the test bundle, and a karma server. When running this task the build is optimized for the first time and then a karma-owned instance of the browser is opened. Click the "debug" button to open a new tab that executes the unit tests.
536516

537517
```bash
538-
yarn test:dev
518+
yarn test:karma:debug
539519
```
540520

541521
In the screenshot below, you'll notice the URL is `localhost:9876/debug.html`. You can append a `grep` query parameter to this URL and set it to a string value which will be used to exclude tests which don't match. For example, if you changed the URL to `localhost:9876/debug.html?query=my test` and then refreshed the browser, you'd only see tests run which contain "my test" in the test description.
@@ -551,7 +531,7 @@ To run the tests for just your particular plugin run the following command from
551531

552532
```bash
553533
yarn test:mocha
554-
yarn test:browser --dev # remove the --dev flag to run them once and close
534+
yarn test:karma:debug # remove the debug flag to run them once and close
555535
```
556536

557537
### Automated Accessibility Testing

Jenkinsfile

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a
1414
'kibana-intake-agent': kibanaPipeline.intakeWorker('kibana-intake', './test/scripts/jenkins_unit.sh'),
1515
'x-pack-intake-agent': kibanaPipeline.intakeWorker('x-pack-intake', './test/scripts/jenkins_xpack.sh'),
1616
'kibana-oss-agent': kibanaPipeline.withWorkers('kibana-oss-tests', { kibanaPipeline.buildOss() }, [
17-
'oss-firefoxSmoke': kibanaPipeline.getPostBuildWorker('firefoxSmoke', {
18-
retryable('kibana-firefoxSmoke') {
19-
runbld('./test/scripts/jenkins_firefox_smoke.sh', 'Execute kibana-firefoxSmoke')
20-
}
21-
}),
17+
// 'oss-firefoxSmoke': kibanaPipeline.getPostBuildWorker('firefoxSmoke', {
18+
// retryable('kibana-firefoxSmoke') {
19+
// runbld('./test/scripts/jenkins_firefox_smoke.sh', 'Execute kibana-firefoxSmoke')
20+
// }
21+
// }),
2222
'oss-ciGroup1': kibanaPipeline.getOssCiGroupWorker(1),
2323
'oss-ciGroup2': kibanaPipeline.getOssCiGroupWorker(2),
2424
'oss-ciGroup3': kibanaPipeline.getOssCiGroupWorker(3),
@@ -39,11 +39,11 @@ stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a
3939
// 'oss-visualRegression': kibanaPipeline.getPostBuildWorker('visualRegression', { runbld('./test/scripts/jenkins_visual_regression.sh', 'Execute kibana-visualRegression') }),
4040
]),
4141
'kibana-xpack-agent': kibanaPipeline.withWorkers('kibana-xpack-tests', { kibanaPipeline.buildXpack() }, [
42-
'xpack-firefoxSmoke': kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', {
43-
retryable('xpack-firefoxSmoke') {
44-
runbld('./test/scripts/jenkins_xpack_firefox_smoke.sh', 'Execute xpack-firefoxSmoke')
45-
}
46-
}),
42+
// 'xpack-firefoxSmoke': kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', {
43+
// retryable('xpack-firefoxSmoke') {
44+
// runbld('./test/scripts/jenkins_xpack_firefox_smoke.sh', 'Execute xpack-firefoxSmoke')
45+
// }
46+
// }),
4747
'xpack-ciGroup1': kibanaPipeline.getXpackCiGroupWorker(1),
4848
'xpack-ciGroup2': kibanaPipeline.getXpackCiGroupWorker(2),
4949
'xpack-ciGroup3': kibanaPipeline.getXpackCiGroupWorker(3),

docs/api/dashboard/import-dashboard.asciidoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ experimental[] Import dashboards and corresponding saved objects.
1616

1717
`force`::
1818
(Optional, boolean) Overwrite any existing objects on ID conflict.
19-
19+
2020
`exclude`::
2121
(Optional, array) Saved object types that you want to exclude from the import.
2222

@@ -28,14 +28,14 @@ Use the complete response body from the <<dashboard-api-export, Export dashboard
2828
[[dashboard-api-import-response-body]]
2929
==== Response body
3030

31-
`objects`::
32-
(array) A top level property that includes the saved objects.
31+
`objects`::
32+
(array) A top level property that includes the saved objects.
3333

3434
[[dashboard-api-import-codes]]
3535
==== Response code
3636

3737
`200`::
38-
Indicates a successful call, even if there are errors importing individual saved objects. If there ar errors, the error information is returned in the response body on an object-by-object basis.
38+
Indicates a successful call, even if there are errors importing individual saved objects. If there are errors, the error information is returned in the response body on an object-by-object basis.
3939

4040
[[dashboard-api-import-example]]
4141
==== Example

docs/developer/plugin/development-plugin-resources.asciidoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,8 @@ To enable TypeScript support, create a `tsconfig.json` file at the root of your
6666
TypeScript code is automatically converted into JavaScript during development,
6767
but not in the distributable version of Kibana. If you use the
6868
{repo}blob/{branch}/packages/kbn-plugin-helpers[@kbn/plugin-helpers] to build your plugin, then your `.ts` and `.tsx` files will be permanently transpiled before your plugin is archived. If you have your own build process, make sure to run the TypeScript compiler on your source files and ship the compilation output so that your plugin will work with the distributable version of Kibana.
69+
70+
==== {kib} platform migration guide
71+
72+
{repo}blob/{branch}/src/core/MIGRATION.md#migrating-legacy-plugins-to-the-new-platform[This guide]
73+
provides an action plan for moving a legacy plugin to the new platform.

docs/development/core/public/kibana-plugin-public.ihttpfetcherror.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ export interface IHttpFetchError extends Error
1616
| Property | Type | Description |
1717
| --- | --- | --- |
1818
| [body](./kibana-plugin-public.ihttpfetcherror.body.md) | <code>any</code> | |
19+
| [name](./kibana-plugin-public.ihttpfetcherror.name.md) | <code>string</code> | |
1920
| [req](./kibana-plugin-public.ihttpfetcherror.req.md) | <code>Request</code> | |
2021
| [request](./kibana-plugin-public.ihttpfetcherror.request.md) | <code>Request</code> | |
2122
| [res](./kibana-plugin-public.ihttpfetcherror.res.md) | <code>Response</code> | |
165 KB
Loading
317 KB
Loading
238 KB
Loading

0 commit comments

Comments
 (0)