Skip to content

Commit 0e1d743

Browse files
Merge remote-tracking branch 'upstream/master' into convert-typescript
2 parents e5ca35d + 50a2991 commit 0e1d743

File tree

586 files changed

+20717
-7676
lines changed

Some content is hidden

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

586 files changed

+20717
-7676
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@
144144
/x-pack/plugins/licensing/ @elastic/kibana-platform
145145
/x-pack/plugins/global_search/ @elastic/kibana-platform
146146
/x-pack/plugins/cloud/ @elastic/kibana-platform
147+
/x-pack/test/saved_objects_field_count/ @elastic/kibana-platform
147148
/packages/kbn-config-schema/ @elastic/kibana-platform
148149
/src/legacy/server/config/ @elastic/kibana-platform
149150
/src/legacy/server/http/ @elastic/kibana-platform

Jenkinsfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ kibanaPipeline(timeoutMinutes: 155, checkPrChanges: true, setCommitStatus: true)
4141
'xpack-ciGroup9': kibanaPipeline.xpackCiGroupProcess(9),
4242
'xpack-ciGroup10': kibanaPipeline.xpackCiGroupProcess(10),
4343
'xpack-accessibility': kibanaPipeline.functionalTestProcess('xpack-accessibility', './test/scripts/jenkins_xpack_accessibility.sh'),
44+
'xpack-savedObjectsFieldMetrics': kibanaPipeline.functionalTestProcess('xpack-savedObjectsFieldMetrics', './test/scripts/jenkins_xpack_saved_objects_field_metrics.sh'),
4445
// 'xpack-pageLoadMetrics': kibanaPipeline.functionalTestProcess('xpack-pageLoadMetrics', './test/scripts/jenkins_xpack_page_load_metrics.sh'),
4546
'xpack-securitySolutionCypress': { processNumber ->
4647
whenChanged(['x-pack/plugins/security_solution/', 'x-pack/test/security_solution_cypress/']) {

docs/apm/api.asciidoc

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Some APM app features are provided via a REST API:
1010

1111
* <<agent-config-api>>
1212
* <<apm-annotation-api>>
13+
* <<kibana-api,Kibana API>>
1314

1415
[float]
1516
[[apm-api-example]]
@@ -355,6 +356,7 @@ allowing you to easily see how these events are impacting the performance of you
355356

356357
By default, annotations are stored in a newly created `observability-annotations` index.
357358
The name of this index can be changed in your `config.yml` by editing `xpack.observability.annotations.index`.
359+
If you change the default index name, you'll also need to <<apm-app-annotation-user-create,update your user privileges>> accordingly.
358360

359361
The following APIs are available:
360362

@@ -467,3 +469,87 @@ curl -X POST \
467469
}
468470
}
469471
--------------------------------------------------
472+
473+
////
474+
*******************************************************
475+
////
476+
477+
[[kibana-api]]
478+
=== Kibana API
479+
480+
In addition to the APM specific API endpoints, Kibana provides its own <<api,REST API>>
481+
which you can use to automate certain aspects of configuring and deploying Kibana.
482+
An example is below.
483+
484+
[[api-create-apm-index-pattern]]
485+
==== Customize the APM index pattern
486+
487+
As an alternative to updating <<apm-settings-in-kibana,`apm_oss.indexPattern`>> in your `kibana.yml` configuration file,
488+
you can use Kibana's <<saved-objects-api-update,update object API>> to update the default APM index pattern on the fly.
489+
490+
The following example sets the default APM app index pattern to `some-other-pattern-*`:
491+
492+
[source,sh]
493+
----
494+
curl -X PUT "localhost:5601/api/saved_objects/index-pattern/apm_static_index_pattern_id" \ <1>
495+
-H 'Content-Type: application/json' \
496+
-H 'kbn-xsrf: true' \
497+
-H 'Authorization: Basic ${YOUR_AUTH_TOKEN}' \
498+
-d' {
499+
"attributes": {
500+
"title": "some-other-pattern-*", <2>
501+
}
502+
}'
503+
----
504+
<1> `apm_static_index_pattern_id` is the internal, hard-coded ID of the APM index pattern.
505+
This value should not be changed
506+
<2> Your custom index pattern matcher.
507+
508+
The API returns the following:
509+
510+
[source,json]
511+
----
512+
{
513+
"id":"apm_static_index_pattern_id",
514+
"type":"index-pattern",
515+
"updated_at":"2020-07-06T22:55:59.555Z",
516+
"version":"WzYsMV0=",
517+
"attributes":{
518+
"title":"some-other-pattern-*"
519+
}
520+
}
521+
----
522+
523+
To view the new APM app index pattern, use the <<saved-objects-api-get,GET object API>>:
524+
525+
[source,sh]
526+
----
527+
curl -X GET "localhost:5601/api/saved_objects/index-pattern/apm_static_index_pattern_id" \ <1>
528+
-H 'kbn-xsrf: true' \
529+
-H 'Authorization: Basic ${YOUR_AUTH_TOKEN}'
530+
----
531+
<1> `apm_static_index_pattern_id` is the internal, hard-coded ID of the APM index pattern.
532+
533+
The API returns the following:
534+
535+
[source,json]
536+
----
537+
{
538+
"id":"apm_static_index_pattern_id",
539+
"type":"index-pattern",
540+
"updated_at":"2020-07-06T22:55:59.555Z",
541+
"version":"WzYsMV0=",
542+
"attributes":{...}
543+
"fieldFormatMap":"{...}
544+
"fields":"[{...},{...},...]
545+
"sourceFilters":"[{\"value\":\"sourcemap.sourcemap\"}]",
546+
"timeFieldName":"@timestamp",
547+
"title":"some-other-pattern-*"
548+
},
549+
...
550+
}
551+
----
552+
553+
// More examples will go here
554+
555+
More information on Kibana's API is available in <<api,REST API>>.

docs/apm/apm-app-users.asciidoc

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
:beat_default_index_prefix: apm
66
:beat_kib_app: APM app
7-
:annotation_index: `observability-annotations`
7+
:annotation_index: observability-annotations
88

99
++++
1010
<titleabbrev>Users and privileges</titleabbrev>
@@ -102,6 +102,54 @@ Here are two examples:
102102
*********************************** ***********************************
103103
////
104104

105+
[role="xpack"]
106+
[[apm-app-annotation-user-create]]
107+
=== APM app annotation user
108+
109+
++++
110+
<titleabbrev>Create an annotation user</titleabbrev>
111+
++++
112+
113+
NOTE: By default, the `apm_user` built-in role provides access to Observability annotations.
114+
You only need to create an annotation user if the default annotation index
115+
defined in <<apm-settings-kb,`xpack.observability.annotations.index`>> has been customized.
116+
117+
[[apm-app-annotation-user]]
118+
==== Annotation user
119+
120+
View deployment annotations in the APM app.
121+
122+
. Create a new role, named something like `annotation_user`,
123+
and assign the following privileges:
124+
+
125+
[options="header"]
126+
|====
127+
|Type | Privilege | Purpose
128+
129+
|Index
130+
|`read` on +\{ANNOTATION_INDEX\}+^1^
131+
|Read-only access to the observability annotation index
132+
133+
|Index
134+
|`view_index_metadata` on +\{ANNOTATION_INDEX\}+^1^
135+
|Read-only access to observability annotation index metadata
136+
|====
137+
+
138+
^1^ +\{ANNOTATION_INDEX\}+ should be the index name you've defined in
139+
<<apm-settings-kb,`xpack.observability.annotations.index`>>.
140+
141+
. Assign the `annotation_user` created previously, and the built-in roles necessary to create
142+
a <<apm-app-reader-full,full>> or <<apm-app-reader-partial,partial>> APM reader to any users that need to view annotations in the APM app
143+
144+
[[apm-app-annotation-api]]
145+
==== Annotation API
146+
147+
See <<apm-app-api-user>>.
148+
149+
////
150+
*********************************** ***********************************
151+
////
152+
105153
[role="xpack"]
106154
[[apm-app-central-config-user]]
107155
=== APM app central config user

docs/apm/set-up.asciidoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ simply click *Load Kibana objects* at the bottom of the Setup Instructions.
2525
[role="screenshot"]
2626
image::apm/images/apm-index-pattern.png[Setup index pattern for APM in Kibana]
2727

28-
To use a custom index pattern, see <<apm-settings-in-kibana>>.
28+
TIP: To use a custom index pattern,
29+
adjust Kibana's <<apm-settings-in-kibana,settings>> or use the <<api-create-apm-index-pattern,Kibana API>>.
2930

3031
[float]
3132
[[apm-getting-started-next]]

docs/development/core/server/kibana-plugin-core-server.httpserverinfo.host.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

docs/development/core/server/kibana-plugin-core-server.httpserverinfo.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export interface HttpServerInfo
1515

1616
| Property | Type | Description |
1717
| --- | --- | --- |
18-
| [host](./kibana-plugin-core-server.httpserverinfo.host.md) | <code>string</code> | The hostname of the server |
18+
| [hostname](./kibana-plugin-core-server.httpserverinfo.hostname.md) | <code>string</code> | The hostname of the server |
1919
| [name](./kibana-plugin-core-server.httpserverinfo.name.md) | <code>string</code> | The name of the Kibana server |
2020
| [port](./kibana-plugin-core-server.httpserverinfo.port.md) | <code>number</code> | The port the server is listening on |
2121
| [protocol](./kibana-plugin-core-server.httpserverinfo.protocol.md) | <code>'http' &#124; 'https' &#124; 'socket'</code> | The protocol used by the server |

docs/development/plugins/data/public/kibana-plugin-plugins-data-public.indexpattern.destroy.md

Lines changed: 0 additions & 15 deletions
This file was deleted.

docs/development/plugins/data/public/kibana-plugin-plugins-data-public.indexpattern.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ export declare class IndexPattern implements IIndexPattern
3939
| [\_fetchFields()](./kibana-plugin-plugins-data-public.indexpattern._fetchfields.md) | | |
4040
| [addScriptedField(name, script, fieldType, lang)](./kibana-plugin-plugins-data-public.indexpattern.addscriptedfield.md) | | |
4141
| [create(allowOverride)](./kibana-plugin-plugins-data-public.indexpattern.create.md) | | |
42-
| [destroy()](./kibana-plugin-plugins-data-public.indexpattern.destroy.md) | | |
4342
| [getAggregationRestrictions()](./kibana-plugin-plugins-data-public.indexpattern.getaggregationrestrictions.md) | | |
4443
| [getComputedFields()](./kibana-plugin-plugins-data-public.indexpattern.getcomputedfields.md) | | |
4544
| [getFieldByName(name)](./kibana-plugin-plugins-data-public.indexpattern.getfieldbyname.md) | | |

docs/user/alerting/action-types/pre-configured-connectors.asciidoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,12 @@ two out-of-the box connectors: <<slack-action-type, Slack>> and <<webhook-action
2828
my-slack1: <1>
2929
actionTypeId: .slack <2>
3030
name: 'Slack #xyz' <3>
31-
secrets: <4>
31+
secrets:
3232
webhookUrl: 'https://hooks.slack.com/services/abcd/efgh/ijklmnopqrstuvwxyz'
3333
webhook-service:
3434
actionTypeId: .webhook
3535
name: 'Email service'
36-
config:
36+
config: <4>
3737
url: 'https://email-alert-service.elastic.co'
3838
method: post
3939
headers:

0 commit comments

Comments
 (0)