Skip to content

Commit a5505de

Browse files
Merge branch 'master' into issue-39727-document-kbn-config
2 parents 6508be2 + b5133b5 commit a5505de

4,854 files changed

Lines changed: 97025 additions & 57331 deletions

File tree

Some content is hidden

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

.ci/Jenkinsfile_flaky

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ stage("Kibana Pipeline") {
3434
if (!IS_XPACK) {
3535
kibanaPipeline.buildOss()
3636
if (CI_GROUP == '1') {
37-
runbld "./test/scripts/jenkins_build_kbn_tp_sample_panel_action.sh"
37+
runbld("./test/scripts/jenkins_build_kbn_tp_sample_panel_action.sh", "Build kbn tp sample panel action for ciGroup1")
3838
}
3939
} else {
4040
kibanaPipeline.buildXpack()
@@ -62,18 +62,18 @@ stage("Kibana Pipeline") {
6262
def getWorkerFromParams(isXpack, job, ciGroup) {
6363
if (!isXpack) {
6464
if (job == 'firefoxSmoke') {
65-
return kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld './test/scripts/jenkins_firefox_smoke.sh' })
65+
return kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld('./test/scripts/jenkins_firefox_smoke.sh', 'Execute kibana-firefoxSmoke') })
6666
} else if(job == 'visualRegression') {
67-
return kibanaPipeline.getPostBuildWorker('visualRegression', { runbld './test/scripts/jenkins_visual_regression.sh' })
67+
return kibanaPipeline.getPostBuildWorker('visualRegression', { runbld('./test/scripts/jenkins_visual_regression.sh', 'Execute kibana-visualRegression') })
6868
} else {
6969
return kibanaPipeline.getOssCiGroupWorker(ciGroup)
7070
}
7171
}
7272

7373
if (job == 'firefoxSmoke') {
74-
return kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld './test/scripts/jenkins_xpack_firefox_smoke.sh' })
74+
return kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld('./test/scripts/jenkins_xpack_firefox_smoke.sh', 'Execute xpack-firefoxSmoke') })
7575
} else if(job == 'visualRegression') {
76-
return kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld './test/scripts/jenkins_xpack_visual_regression.sh' })
76+
return kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld('./test/scripts/jenkins_xpack_visual_regression.sh', 'Execute xpack-visualRegression') })
7777
} else {
7878
return kibanaPipeline.getXpackCiGroupWorker(ciGroup)
7979
}

.eslintrc.js

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,6 @@ module.exports = {
6464
'jsx-a11y/no-onchange': 'off',
6565
},
6666
},
67-
{
68-
files: ['src/core/public/application/**/*.{js,ts,tsx}'],
69-
rules: {
70-
'react/no-danger': 'off',
71-
},
72-
},
7367
{
7468
files: ['src/legacy/core_plugins/console/**/*.{js,ts,tsx}'],
7569
rules: {
@@ -214,13 +208,6 @@ module.exports = {
214208
'jsx-a11y/click-events-have-key-events': 'off',
215209
},
216210
},
217-
{
218-
files: ['x-pack/legacy/plugins/siem/**/*.{js,ts,tsx}'],
219-
rules: {
220-
'react-hooks/exhaustive-deps': 'off',
221-
'react-hooks/rules-of-hooks': 'off',
222-
},
223-
},
224211
{
225212
files: ['x-pack/legacy/plugins/snapshot_restore/**/*.{js,ts,tsx}'],
226213
rules: {
@@ -839,6 +826,8 @@ module.exports = {
839826
// might be introduced after the other warns are fixed
840827
// 'react/jsx-sort-props': 'error',
841828
'react/jsx-tag-spacing': 'error',
829+
// might be introduced after the other warns are fixed
830+
'react-hooks/exhaustive-deps': 'off',
842831
'require-atomic-updates': 'error',
843832
'rest-spread-spacing': ['error', 'never'],
844833
'symbol-description': 'error',

.github/CODEOWNERS

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,6 @@
2828
# Canvas
2929
/x-pack/legacy/plugins/canvas/ @elastic/kibana-canvas
3030

31-
# Code
32-
/x-pack/legacy/plugins/code/ @teams/code
33-
/x-pack/test/functional/apps/code/ @teams/code
34-
/x-pack/test/api_integration/apis/code/ @teams/code
35-
3631
# Logs & Metrics UI
3732
/x-pack/legacy/plugins/infra/ @elastic/logs-metrics-ui
3833
/x-pack/legacy/plugins/integrations_manager/ @elastic/epm
@@ -45,6 +40,9 @@
4540
# ML team owns the transform plugin, ES team added here for visibility
4641
# because the plugin lives in Kibana's Elasticsearch management section.
4742
/x-pack/legacy/plugins/transform/ @elastic/ml-ui @elastic/es-ui
43+
/x-pack/test/functional/apps/transform/ @elastic/ml-ui
44+
/x-pack/test/functional/services/transform_ui/ @elastic/ml-ui
45+
/x-pack/test/functional/services/transform.ts @elastic/ml-ui
4846

4947
# Operations
5048
/renovate.json5 @elastic/kibana-operations
@@ -77,6 +75,7 @@
7775
/x-pack/test/api_integration/apis/security/ @elastic/kibana-security
7876

7977
# Kibana Stack Services
78+
/src/dev/i18n @elastic/kibana-stack-services
8079
/packages/kbn-analytics/ @elastic/kibana-stack-services
8180
/src/legacy/core_plugins/ui_metric/ @elastic/kibana-stack-services
8281
/x-pack/legacy/plugins/telemetry @elastic/kibana-stack-services

.i18nrc.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@
66
"dashboardEmbeddableContainer": "src/plugins/dashboard_embeddable_container",
77
"data": ["src/legacy/core_plugins/data", "src/plugins/data"],
88
"embeddableApi": "src/plugins/embeddable",
9+
"share": "src/plugins/share",
910
"esUi": "src/plugins/es_ui_shared",
10-
"expressions_np": "src/plugins/expressions",
11-
"expressions": "src/legacy/core_plugins/expressions",
11+
"devTools": "src/plugins/dev_tools",
12+
"expressions": "src/plugins/expressions",
1213
"inputControl": "src/legacy/core_plugins/input_control_vis",
1314
"inspector": "src/plugins/inspector",
1415
"inspectorViews": "src/legacy/core_plugins/inspector_views",
@@ -20,6 +21,7 @@
2021
"kibana_react": "src/legacy/core_plugins/kibana_react",
2122
"kibana-react": "src/plugins/kibana_react",
2223
"navigation": "src/legacy/core_plugins/navigation",
24+
"newsfeed": "src/plugins/newsfeed",
2325
"regionMap": "src/legacy/core_plugins/region_map",
2426
"server": "src/legacy/server",
2527
"statusPage": "src/legacy/core_plugins/status_page",
@@ -33,7 +35,7 @@
3335
"visTypeTagCloud": "src/legacy/core_plugins/vis_type_tagcloud",
3436
"visTypeTimeseries": "src/legacy/core_plugins/vis_type_timeseries",
3537
"visTypeVega": "src/legacy/core_plugins/vis_type_vega",
36-
"visualizations": "src/plugins/visualizations"
38+
"visualizations": ["src/plugins/visualizations", "src/legacy/core_plugins/visualizations"]
3739
},
3840
"exclude": ["src/legacy/ui/ui_render/ui_render_mixin.js"],
3941
"translations": []

.sass-lint.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ files:
22
include:
33
- 'src/legacy/core_plugins/metrics/**/*.s+(a|c)ss'
44
- 'src/legacy/core_plugins/timelion/**/*.s+(a|c)ss'
5-
- 'src/legacy/ui/public/query_bar/**/*.s+(a|c)ss'
65
- 'src/legacy/ui/public/vislib/**/*.s+(a|c)ss'
76
- 'x-pack/legacy/plugins/rollup/**/*.s+(a|c)ss'
87
- 'x-pack/legacy/plugins/security/**/*.s+(a|c)ss'

CONTRIBUTING.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ Note that for VSCode, to enable "live" linting of TypeScript (and other) file ty
325325
"eslint.autoFixOnSave": true,
326326
```
327327

328-
It is **not** recommended to use `prettier` plugin on Kibana project. Because settings are in `eslintrc.js` file and it is applied to too many files that shouldn't be prettier-ized.
328+
:warning: It is **not** recommended to use the [`Prettier` extension/IDE plugin](https://prettier.io/) while maintaining the Kibana project. Formatting and styling roles are set in the multiple `.eslintrc.js` files across the project and some of them use the [NPM version of Prettier](https://www.npmjs.com/package/prettier). Using the IDE extension might cause conflicts, applying the formatting to too many files that shouldn't be prettier-ized and/or highlighting errors that are actually OK.
329329

330330
### Internationalization
331331

@@ -399,13 +399,19 @@ Test runner arguments:
399399
- `[test path]` is the relative path to the test file.
400400

401401
Examples:
402-
- Run the entire elasticsearch_service test suite with yarn:
403-
`node scripts/jest src/core/server/elasticsearch/elasticsearch_service.test.ts`
404-
- Run the jest test case whose description matches 'stops both admin and data clients':
405-
`node scripts/jest -t 'stops both admin and data clients' src/core/server/elasticsearch/elasticsearch_service.test.ts`
402+
- Run the entire elasticsearch_service test suite:
403+
```
404+
node scripts/jest src/core/server/elasticsearch/elasticsearch_service.test.ts
405+
```
406+
- Run the jest test case whose description matches `stops both admin and data clients`:
407+
```
408+
node scripts/jest -t 'stops both admin and data clients' src/core/server/elasticsearch/elasticsearch_service.test.ts
409+
```
406410
- Run the api integration test case whose description matches the given string:
407-
`node scripts/functional_tests_server --config test/api_integration/config.js`
408-
`node scripts/functional_test_runner --config test/api_integration/config.js --grep='should return 404 if id does not match any sample data sets'`
411+
```
412+
node scripts/functional_tests_server --config test/api_integration/config.js
413+
node scripts/functional_test_runner --config test/api_integration/config.js --grep='should return 404 if id does not match any sample data sets'
414+
```
409415
410416
### Debugging Unit Tests
411417

Jenkinsfile

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ library 'kibana-pipeline-library'
44
kibanaLibrary.load()
55

66
stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a little bit
7-
timeout(time: 180, unit: 'MINUTES') {
7+
timeout(time: 120, unit: 'MINUTES') {
88
timestamps {
99
ansiColor('xterm') {
1010
catchError {
@@ -24,9 +24,9 @@ stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a
2424
'oss-ciGroup10': kibanaPipeline.getOssCiGroupWorker(10),
2525
'oss-ciGroup11': kibanaPipeline.getOssCiGroupWorker(11),
2626
'oss-ciGroup12': kibanaPipeline.getOssCiGroupWorker(12),
27-
'oss-firefoxSmoke': kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld './test/scripts/jenkins_firefox_smoke.sh' }),
28-
'oss-accessibility': kibanaPipeline.getPostBuildWorker('accessibility', { runbld './test/scripts/jenkins_accessibility.sh' }),
29-
'oss-visualRegression': kibanaPipeline.getPostBuildWorker('visualRegression', { runbld './test/scripts/jenkins_visual_regression.sh' }),
27+
'oss-firefoxSmoke': kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld('./test/scripts/jenkins_firefox_smoke.sh', 'Execute kibana-firefoxSmoke') }),
28+
'oss-accessibility': kibanaPipeline.getPostBuildWorker('accessibility', { runbld('./test/scripts/jenkins_accessibility.sh', 'Execute kibana-accessibility') }),
29+
'oss-visualRegression': kibanaPipeline.getPostBuildWorker('visualRegression', { runbld('./test/scripts/jenkins_visual_regression.sh', 'Execute kibana-visualRegression') }),
3030
]),
3131
'kibana-xpack-agent': kibanaPipeline.withWorkers('kibana-xpack-tests', { kibanaPipeline.buildXpack() }, [
3232
'xpack-ciGroup1': kibanaPipeline.getXpackCiGroupWorker(1),
@@ -39,9 +39,9 @@ stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a
3939
'xpack-ciGroup8': kibanaPipeline.getXpackCiGroupWorker(8),
4040
'xpack-ciGroup9': kibanaPipeline.getXpackCiGroupWorker(9),
4141
'xpack-ciGroup10': kibanaPipeline.getXpackCiGroupWorker(10),
42-
'xpack-firefoxSmoke': kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld './test/scripts/jenkins_xpack_firefox_smoke.sh' }),
43-
'xpack-accessibility': kibanaPipeline.getPostBuildWorker('xpack-accessibility', { runbld './test/scripts/jenkins_xpack_accessibility.sh' }),
44-
'xpack-visualRegression': kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld './test/scripts/jenkins_xpack_visual_regression.sh' }),
42+
'xpack-firefoxSmoke': kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld('./test/scripts/jenkins_xpack_firefox_smoke.sh', 'Execute xpack-firefoxSmoke') }),
43+
'xpack-accessibility': kibanaPipeline.getPostBuildWorker('xpack-accessibility', { runbld('./test/scripts/jenkins_xpack_accessibility.sh', 'Execute xpack-accessibility') }),
44+
'xpack-visualRegression': kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld('./test/scripts/jenkins_xpack_visual_regression.sh', 'Execute xpack-visualRegression') }),
4545
]),
4646
])
4747
}

STYLEGUIDE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ You should prefer modern language features in a lot of cases, e.g.:
120120
* Prefer arrow function over storing `this` (no `const self = this;`)
121121
* Prefer template strings over string concatenation
122122
* Prefer the spread operator for copying arrays (`[...arr]`) over `arr.slice()`
123+
* Use optional chaining (`?.`) and nullish Coalescing (`??`) over `lodash.get` (and similar utilities)
123124
124125
### Avoid mutability and state
125126

TYPESCRIPT.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ The first thing that will probably happen when you convert a `.js` file in our s
2121

2222
declare module '@elastic/eui' {
2323
// Add your types here
24-
export const EuiPopoverTitle: React.SFC<EuiPopoverTitleProps>;
24+
export const EuiPopoverTitle: React.FC<EuiPopoverTitleProps>;
2525
...
2626
}
2727
```
@@ -47,13 +47,13 @@ Since `@elastic/eui` already ships with a module declaration, any local addition
4747
// file `typings/@elastic/eui/index.d.ts`
4848

4949
import { CommonProps } from '@elastic/eui';
50-
import { SFC } from 'react';
50+
import { FC } from 'react';
5151

5252
declare module '@elastic/eui' {
5353
export type EuiNewComponentProps = CommonProps & {
5454
additionalProp: string;
5555
};
56-
export const EuiNewComponent: SFC<EuiNewComponentProps>;
56+
export const EuiNewComponent: FC<EuiNewComponentProps>;
5757
}
5858
```
5959

docs/apm/advanced-queries.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ so it's easy to share a specific query or view with others.
1010
In the screenshot below, you can begin to see some of the transaction fields available for filtering on:
1111

1212
[role="screenshot"]
13-
image::apm/images/apm-query-bar.png[Example of the Kibana Query bar in APM UI in Kibana]
13+
image::apm/images/apm-query-bar.png[Example of the Kibana Query bar in APM app in Kibana]
1414

1515
[float]
1616
==== Example queries

0 commit comments

Comments
 (0)