Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/elastic/kibana into flaky…
Browse files Browse the repository at this point in the history
…-test-pending-alert
  • Loading branch information
ymao1 committed Jan 13, 2021
2 parents b68f696 + fb67443 commit eedd7c6
Show file tree
Hide file tree
Showing 1,054 changed files with 17,788 additions and 5,962 deletions.
14 changes: 11 additions & 3 deletions .ci/packer_cache_for_branch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ set -e
branch="$1"
checkoutDir="$(pwd)"

function cleanup()
{
if [[ "$branch" != "master" ]]; then
rm --preserve-root -rf "$checkoutDir"
fi

exit 0
}

trap 'cleanup' 0

if [[ "$branch" != "master" ]]; then
checkoutDir="/tmp/kibana-$branch"
git clone https://github.com/elastic/kibana.git --branch "$branch" --depth 1 "$checkoutDir"
Expand Down Expand Up @@ -56,6 +67,3 @@ echo "created $HOME/.kibana/bootstrap_cache/$branch.tar"

.ci/build_docker.sh

if [[ "$branch" != "master" ]]; then
rm --preserve-root -rf "$checkoutDir"
fi
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ x-pack/plugins/telemetry_collection_xpack/schema/xpack_plugins.json @elastic/kib
# Security
/src/core/server/csp/ @elastic/kibana-security @elastic/kibana-core
/src/plugins/security_oss/ @elastic/kibana-security
/src/plugins/spaces_oss/ @elastic/kibana-security
/test/security_functional/ @elastic/kibana-security
/x-pack/plugins/spaces/ @elastic/kibana-security
/x-pack/plugins/encrypted_saved_objects/ @elastic/kibana-security
Expand Down
Binary file added docs/apm/images/all-instances.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/apm/images/error-rate.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/apm/images/latency.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/apm/images/metadata-icons.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/apm/images/spans-dependencies.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/apm/images/traffic-transactions.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
105 changes: 104 additions & 1 deletion docs/apm/service-overview.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,107 @@
[[service-overview]]
=== Service overview

Selecting a <<services,*service*>> brings you to the *Service overview*.
Selecting a <<services,*service*>> brings you to the *Service overview*.
The *Service overview* contains a wide variety of charts and tables that provide
visibility into how a service performs across your infrastructure.

[discrete]
[[service-latency]]
=== Latency

Response times for the service. You can filter the *Latency* chart to display the average,
95th, or 99th percentile latency times for the service.

[role="screenshot"]
image::apm/images/latency.png[Service latency]

[discrete]
[[service-traffic-transactions]]
=== Traffic and transactions

The *Traffic* chart visualizes the average number of transactions per minute for the selected service.

The *Transactions* table displays a list of _transaction groups_ for the
selected service and includes the latency, traffic, error rate, and the impact for each transaction.
Transactions that share the same name are grouped, and only one entry is displayed for each group.

By default, transaction groups are sorted by _Impact_ to show the most used and slowest endpoints in your
service. If there is a particular endpoint you are interested in, click *View transactions* to view a
list of similar transactions on the <<transactions, transactions overview>> page.

[role="screenshot"]
image::apm/images/traffic-transactions.png[Traffic and transactions]

[discrete]
[[service-error-rates]]
=== Error rate and errors

The *Error rate* chart displays the average error rates relating to the service, within a specific time range.

The *Errors* table provides a high-level view of each error message when it first and last occurred,
along with the total number of occurrences. This makes it very easy to quickly see which errors affect
your services and take actions to rectify them. To do so, click *View errors*.

[role="screenshot"]
image::apm/images/error-rate.png[Error rate and errors]

[discrete]
[[service-span-duration]]
=== Span types average duration and dependencies

The *Average duration by span type* chart visualizes each span type's average duration and helps you determine
which spans could be slowing down transactions. The "app" label displayed under the
chart indicates that something was happening within the application. This could signal that the
agent does not have auto-instrumentation for whatever was happening during that time or that the time was spent in the
application code and not in database or external requests.

The *Dependencies* table displays a list of downstream services or external connections relevant
to the service at the selected time range. The table displays latency, traffic, error rate, and the impact of
each dependency. By default, dependencies are sorted by _Impact_ to show the most used and the slowest dependency.
If there is a particular dependency you are interested in, click *View service map* to view the related
<<service-maps, service map>>.

[role="screenshot"]
image::apm/images/spans-dependencies.png[Span type duration and dependencies]

[discrete]
[[service-instances]]
=== All instances

The *All instances* table displays a list of all the available service instances within the selected time range.
Depending on how the service runs, the instance could be a host or a container. The table displays latency, traffic,
errors, CPU usage, and memory usage for each instance. By default, instances are sorted by _Traffic_.

[role="screenshot"]
image::apm/images/all-instances.png[All instances]

[discrete]
[[service-metadata]]
=== Service metadata

To view metadata relating to the service agent, and if relevant, the container and cloud provider,
click on each icon located at the top of the page beside the service name.

[role="screenshot"]
image::apm/images/metadata-icons.png[Service metadata]

*Service information*

* Service version
* Runtime name and version
* Framework name
* Agent name and version

*Container information*

* Operating system
* Containerized - Yes or no.
* Total number of instances
* Orchestration

*Cloud provider information*

* Cloud provider
* Availability zones
* Machine types
* Project ID
1 change: 1 addition & 0 deletions docs/apm/transactions.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ Like in the Transaction duration graph, you can zoom in on anomalies to further

*Error rate*::
Visualize the total number of transactions with errors divided by the total number of transactions.
The error rate value is based on the `event.outcome` field and is the relative number of failed transactions.
Any unexpected increases, decreases, or irregular patterns can be investigated further
with the <<errors,errors overview>>.

Expand Down
5 changes: 4 additions & 1 deletion docs/developer/advanced/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,12 @@
* <<running-elasticsearch>>
* <<development-es-snapshots>>
* <<development-basepath>>
* <<upgrading-nodejs>>

include::development-es-snapshots.asciidoc[leveloffset=+1]

include::running-elasticsearch.asciidoc[leveloffset=+1]

include::development-basepath.asciidoc[leveloffset=+1]
include::development-basepath.asciidoc[leveloffset=+1]

include::upgrading-nodejs.asciidoc[leveloffset=+1]
76 changes: 76 additions & 0 deletions docs/developer/advanced/upgrading-nodejs.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
[[upgrading-nodejs]]
== Upgrading Node.js

{kib} requires a specific Node.js version to run.
When running {kib} from source, you must have this version installed locally.

The required version of Node.js is listed in several different files throughout the {kib} source code.
Theses files must be updated when upgrading Node.js:

- {kib-repo}blob/{branch}/.ci/Dockerfile[`.ci/Dockerfile`] - The version is specified in the `NODE_VERSION` constant.
This is used to pull the relevant image from https://hub.docker.com/_/node[Docker Hub].
Note that Docker Hub can take 24+ hours to be updated with the new images after a new release of Node.js, so if you're upgrading Node.js in Kibana just after the official Node.js release, you have to check if the new images are present on Docker Hub.
If they are not, and the update is urgent, you can skip this file and update it later once Docker Hub has been updated.
- {kib-repo}blob/{branch}/.node-version[`.node-version`]
- {kib-repo}blob/{branch}/.nvmrc[`.nvmrc`]
- {kib-repo}blob/{branch}/package.json[`package.json`] - The version is specified in the `engines.node` field.

See PR {kib-repo}pull/86593[#86593] for an example of how the Node.js version has been upgraded previously.

In the 6.8 branch, the `.ci/Dockerfile` file does not exist, so when upgrading Node.js in that branch, just skip that file.

=== Backporting

The following rules are not set in stone.
Use best judgement when backporting.

Currently version 7.11 and newer run Node.js 14, while 7.10 and older run Node.js 10.
Hence, upgrades to either Node.js 14 or Node.js 10 shold be done as separate PRs.

==== Node.js patch upgrades

Typically, you want to backport Node.js *patch* upgrades to all supported release branches that run the same *major* Node.js version:

- If upgrading Node.js 14, and the current release is 7.11.1, the main PR should target `master` and be backported to `7.x` and `7.11`.
- If upgrading Node.js 10, the main PR should target `6.8` only.

==== Node.js minor upgrades

Typically, you want to backport Node.js *minor* upgrades to the next minor {kib} release branch that runs the same *major* Node.js version:

- If upgrading Node.js 14, and the current release is 7.11.1, the main PR should target `master` and be backported to `7.x`, while leaving the `7.11` branch as-is.
- If upgrading Node.js 10, the main PR should target `6.8` only.

=== Upgrading installed Node.js version

The following instructions expect that https://github.com/nvm-sh/nvm[nvm] is used to manage locally installed Node.js versions.

Run the following to install the new Node.js version. Replace `<version>` with the desired Node.js version:

[source,bash]
----
nvm install <version>
----

To get the same global npm modules installed with the new version of Node.js as is currently installed, use the `--reinstall-packages-from` command-line argument (optionally replace `14` with the desired source version):

[source,bash]
----
nvm install <version> --reinstall-packages-from=14
----

If needed, uninstall the old version of Node.js by running the following. Replace `<old-version>` with the full version number of the version that should be uninstalled:

[source,bash]
----
nvm uninstall <old-version>
----

Optionally, tell nvm to always use the "highest" installed Node.js 14 version. Replace `14` if a different major version is desired:

[source,bash]
----
nvm alias default 14
----

Alternatively, include the full version number at the end to specify a specific default version.
2 changes: 1 addition & 1 deletion docs/developer/getting-started/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ cd kibana

Install the version of Node.js listed in the `.node-version` file. This
can be automated with tools such as
https://github.com/creationix/nvm[nvm],
https://github.com/nvm-sh/nvm[nvm],
https://github.com/coreybutler/nvm-windows[nvm-windows] or
https://github.com/wbyoung/avn[avn]. As we also include a `.nvmrc` file
you can switch to the correct version when using nvm by running:
Expand Down
4 changes: 4 additions & 0 deletions docs/developer/plugin-list.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,10 @@ so they can properly protect the data within their clusters.
|Replaces the legacy ui/share module for registering share context menus.
|{kib-repo}blob/{branch}/src/plugins/spaces_oss/README.md[spacesOss]
|Bridge plugin for consumption of the Spaces feature from OSS plugins.
|{kib-repo}blob/{branch}/src/plugins/telemetry/README.md[telemetry]
|Telemetry allows Kibana features to have usage tracked in the wild. The general term "telemetry" refers to multiple things:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export interface DataPublicPluginStart
| [autocomplete](./kibana-plugin-plugins-data-public.datapublicpluginstart.autocomplete.md) | <code>AutocompleteStart</code> | autocomplete service [AutocompleteStart](./kibana-plugin-plugins-data-public.autocompletestart.md) |
| [fieldFormats](./kibana-plugin-plugins-data-public.datapublicpluginstart.fieldformats.md) | <code>FieldFormatsStart</code> | field formats service [FieldFormatsStart](./kibana-plugin-plugins-data-public.fieldformatsstart.md) |
| [indexPatterns](./kibana-plugin-plugins-data-public.datapublicpluginstart.indexpatterns.md) | <code>IndexPatternsContract</code> | index patterns service [IndexPatternsContract](./kibana-plugin-plugins-data-public.indexpatternscontract.md) |
| [nowProvider](./kibana-plugin-plugins-data-public.datapublicpluginstart.nowprovider.md) | <code>NowProviderPublicContract</code> | |
| [query](./kibana-plugin-plugins-data-public.datapublicpluginstart.query.md) | <code>QueryStart</code> | query service [QueryStart](./kibana-plugin-plugins-data-public.querystart.md) |
| [search](./kibana-plugin-plugins-data-public.datapublicpluginstart.search.md) | <code>ISearchStart</code> | search service [ISearchStart](./kibana-plugin-plugins-data-public.isearchstart.md) |
| [ui](./kibana-plugin-plugins-data-public.datapublicpluginstart.ui.md) | <code>DataPublicPluginStartUi</code> | prewired UI components [DataPublicPluginStartUi](./kibana-plugin-plugins-data-public.datapublicpluginstartui.md) |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-plugins-data-public](./kibana-plugin-plugins-data-public.md) &gt; [DataPublicPluginStart](./kibana-plugin-plugins-data-public.datapublicpluginstart.md) &gt; [nowProvider](./kibana-plugin-plugins-data-public.datapublicpluginstart.nowprovider.md)

## DataPublicPluginStart.nowProvider property

<b>Signature:</b>

```typescript
nowProvider: NowProviderPublicContract;
```
Binary file modified docs/discover/images/Discover-Start.png
100755 → 100644
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/discover/images/document-table-expanded.png
100755 → 100644
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/discover/images/document-table.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/discover/images/visualize-from-discover.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion docs/user/reporting/response-codes.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ the POST URL. This is true even if the job somehow fails later, since report
generation happens asynchronously from queuing.
- **`400` (Bad Request)**: When sending requests to the POST URL, if you don't use
`POST` as the HTTP method, or if your request is missing the `kbn-version` header,
`POST` as the HTTP method, or if your request is missing the `kbn-xsrf` header,
Kibana will return a code `400` status response for the request.
- **`503` (Service Unavailable)**: When using the `path` to request the download, you
Expand Down
8 changes: 4 additions & 4 deletions docs/user/reporting/script-example.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ The response from this request will be JSON, and will contain a `path` property
URL to use to download the generated report. Use the `GET` method in the HTTP request to
download the report.

The request method must be `POST` and it must include a `kbn-version` header for Kibana
The request method must be `POST` and it must include a `kbn-xsrf` header for Kibana
to allow the request.

The following example queues CSV report generation using the `POST` URL with cURL:
Expand All @@ -13,16 +13,16 @@ The following example queues CSV report generation using the `POST` URL with cUR
curl \
-XPOST \ <1>
-u elastic \ <2>
-H 'kbn-version: {version}' \ <3>
-H 'kbn-xsrf: true' \ <3>
'http://0.0.0.0:5601/api/reporting/generate/csv?jobParams=...' <4>
---------------------------------------------------------
// CONSOLE

<1> `POST` method is required.
<2> Provide user credentials for a user with permission to access Kibana and
{report-features}.
<3> The `kbn-version` header is required for all `POST` requests to Kibana.
**The value must match the dotted-numeral version of the Kibana instance.**
<3> The `kbn-xsrf` header is required for all `POST` requests to Kibana. For more information, see <<api-request-headers, API Request
Headers>>.
<4> The POST URL. You can copy and paste the URL for any report from the Kibana UI.

Here is an example response for a successfully queued report:
Expand Down
10 changes: 6 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@
"dedent": "^0.7.0",
"deep-freeze-strict": "^1.1.1",
"del": "^5.1.0",
"elastic-apm-node": "^3.7.0",
"elastic-apm-node": "^3.10.0",
"elasticsearch": "^16.7.0",
"execa": "^4.0.2",
"exit-hook": "^2.2.0",
Expand Down Expand Up @@ -232,6 +232,7 @@
"intl-messageformat": "^2.2.0",
"intl-relativeformat": "^2.1.0",
"io-ts": "^2.0.5",
"ipaddr.js": "2.0.0",
"isbinaryfile": "4.0.2",
"joi": "^13.5.2",
"jquery": "^3.5.0",
Expand Down Expand Up @@ -439,6 +440,7 @@
"@types/enzyme": "^3.10.5",
"@types/eslint": "^6.1.3",
"@types/extract-zip": "^1.6.2",
"@types/faker": "^5.1.5",
"@types/fancy-log": "^1.3.1",
"@types/fetch-mock": "^7.3.1",
"@types/file-saver": "^2.0.0",
Expand Down Expand Up @@ -646,7 +648,7 @@
"eslint-plugin-react-hooks": "^4.2.0",
"eslint-plugin-react-perf": "^3.2.3",
"expose-loader": "^0.7.5",
"faker": "1.1.0",
"faker": "^5.1.0",
"fancy-log": "^1.3.2",
"fast-glob": "2.2.7",
"fetch-mock": "^7.3.9",
Expand Down Expand Up @@ -828,10 +830,10 @@
"url-loader": "^2.2.0",
"use-resize-observer": "^6.0.0",
"val-loader": "^1.1.1",
"vega": "^5.17.3",
"vega": "^5.18.0",
"vega-lite": "^4.17.0",
"vega-schema-url-parser": "^2.1.0",
"vega-tooltip": "^0.24.2",
"vega-tooltip": "^0.25.0",
"venn.js": "0.2.20",
"vinyl-fs": "^3.0.3",
"wait-on": "^5.0.1",
Expand Down
1 change: 1 addition & 0 deletions packages/kbn-optimizer/limits.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,3 +106,4 @@ pageLoadAssetSize:
stackAlerts: 29684
presentationUtil: 28545
runtimeFieldEditor: 46986
spacesOss: 18817
4 changes: 4 additions & 0 deletions src/core/public/doc_links/doc_links_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,10 +201,13 @@ export class DocLinksService {
apiKeyServiceSettings: `${ELASTICSEARCH_DOCS}security-settings.html#api-key-service-settings`,
clusterPrivileges: `${ELASTICSEARCH_DOCS}security-privileges.html#privileges-list-cluster`,
elasticsearchSettings: `${ELASTICSEARCH_DOCS}security-settings.html`,
elasticsearchEnableSecurity: `${ELASTICSEARCH_DOCS}get-started-enable-security.html`,
indicesPrivileges: `${ELASTICSEARCH_DOCS}security-privileges.html#privileges-list-indices`,
kibanaTLS: `${ELASTIC_WEBSITE_URL}guide/en/kibana/${DOC_LINK_VERSION}/configuring-tls.html`,
kibanaPrivileges: `${ELASTIC_WEBSITE_URL}guide/en/kibana/${DOC_LINK_VERSION}/kibana-privileges.html`,
mappingRoles: `${ELASTICSEARCH_DOCS}mapping-roles.html`,
mappingRolesFieldRules: `${ELASTICSEARCH_DOCS}role-mapping-resources.html#mapping-roles-rule-field`,
runAsPrivilege: `${ELASTICSEARCH_DOCS}security-privileges.html#_run_as_privilege`,
},
watcher: {
jiraAction: `${ELASTICSEARCH_DOCS}actions-jira.html`,
Expand All @@ -219,6 +222,7 @@ export class DocLinksService {
createIndex: `${ELASTICSEARCH_DOCS}indices-create-index.html`,
createSnapshotLifecylePolicy: `${ELASTICSEARCH_DOCS}slm-api-put-policy.html`,
createRoleMapping: `${ELASTICSEARCH_DOCS}security-api-put-role-mapping.html`,
createRoleMappingTemplates: `${ELASTICSEARCH_DOCS}security-api-put-role-mapping.html#_role_templates`,
createApiKey: `${ELASTICSEARCH_DOCS}security-api-create-api-key.html`,
createPipeline: `${ELASTICSEARCH_DOCS}put-pipeline-api.html`,
createTransformRequest: `${ELASTICSEARCH_DOCS}put-transform.html#put-transform-request-body`,
Expand Down
Loading

0 comments on commit eedd7c6

Please sign in to comment.