Skip to content

Commit

Permalink
Merge branch 'master' into fix-eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
streamich authored Oct 29, 2019
2 parents 89b1563 + dad9d6b commit 385f494
Show file tree
Hide file tree
Showing 374 changed files with 6,638 additions and 4,741 deletions.
195 changes: 195 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,201 @@ module.exports = {
extends: ['@elastic/eslint-config-kibana', 'plugin:@elastic/eui/recommended'],

overrides: [
/**
* Temporarily disable some react rules for specific plugins, remove in separate PRs
*/
{
files: ['packages/kbn-ui-framework/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/no-onchange': 'off',
},
},
{
files: ['src/core/public/application/**/*.{js,ts,tsx}'],
rules: {
'react/no-danger': 'off',
},
},
{
files: ['src/legacy/core_plugins/console/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/data/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/expressions/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/kbn_vislib_vis_types/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/kibana/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/tile_map/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_markdown/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_metric/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_table/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_vega/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/ui/public/vis/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/es_ui_shared/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/eui_utils/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/kibana_react/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/kibana_utils/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/canvas/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/cross_cluster_replication/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/graph/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/index_management/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/infra/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/lens/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/ml/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/monitoring/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/siem/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/snapshot_restore/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/transform/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/uptime/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/watcher/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},

/**
* Prettier
*/
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ _Note: The version numbers below are only examples, meant to illustrate the rela

## Questions? Problems? Suggestions?

- If you've found a bug or want to request a feature, please create a [GitHub Issue](https://github.com/elastic/kibana/issues/new).
Please check to make sure someone else hasn't already created an issue for the same topic.
- If you've found a bug or want to request a feature, please create a [GitHub Issue](https://github.com/elastic/kibana/issues/new/choose).
Please check to make sure someone else hasn't already created an issue for the same topic.
- Need help using Kibana? Ask away on our [Kibana Discuss Forum](https://discuss.elastic.co/c/kibana) and a fellow community member or
Elastic engineer will be glad to help you out.
4 changes: 2 additions & 2 deletions docs/infrastructure/getting-started.asciidoc
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[role="xpack"]
[[xpack-metrics-getting-started]]
== Getting started with infrastructure monitoring
== Getting started with metrics

To get started with the Metrics app in Kibana, you need to start collecting metrics data for your infrastructure.

Kibana provides step-by-step instructions to help you add metrics data.
The {metrics-guide}[Metrics Monitoring Guide] is a good source for more detailed information and instructions.

[role="screenshot"]
image::infrastructure/images/metrics-add-data.png[Screenshot showing Add metric data to Kibana UI]
image::infrastructure/images/metrics-add-data.png[Screenshot showing Add metric data to Kibana]
4 changes: 2 additions & 2 deletions docs/infrastructure/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

[partintro]
--
The Metrics app enables you to monitor your infrastructure and identify problems in real time.
The Metrics app enables you to monitor your infrastructure metrics and identify problems in real time.
You start with a visual summary of your infrastructure where you can view basic metrics for common servers, containers, and services.
Then you can drill down to view more detailed metrics or other information for that component.

You can:

* View an inventory of your infrastructure by hosts, Kubernetes pod or Docker containers.
* View your infrastructure metrics by hosts, Kubernetes pods or Docker containers.
You can group and filter the data in various ways to help you identify the items that interest you.

* View current and historic values for metrics such as CPU usage, memory usage, and network traffic for each component.
Expand Down
4 changes: 2 additions & 2 deletions docs/infrastructure/infra-ui.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
[[infra-ui]]
== Using the Metrics app

Use the Metrics app in {kib} to monitor your infrastructure and identify problems in real time.
Use the Metrics app in {kib} to monitor your infrastructure metrics and identify problems in real time.
You can explore metrics for hosts, containers, and services.
You can also drill down to view more detailed metrics, or seamlessly switch to view the corresponding logs, application traces, and uptime information.

Initially, the *Inventory* tab shows an overview of the hosts in of your infrastructure and the current CPU usage for each host.
From here, you can drill down into areas of interest.
From here, you can view other metrics or drill down into areas of interest.

[role="screenshot"]
image::infrastructure/images/infra-sysmon.png[Infrastructure Overview in Kibana]
Expand Down
2 changes: 1 addition & 1 deletion docs/infrastructure/metrics-explorer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ image::infrastructure/images/metrics-explorer-screen.png[Metrics Explorer in Kib

* Metrics Explorer uses data collected from {metricbeat-ref}/metricbeat-overview.html[Metricbeat].
* You need read permissions on `metricbeat-*` or the metric index specified in the Metrics configuration.
* Metrics Explorer uses the timestamp field set in the Infrastructure configuration.
* Metrics Explorer uses the timestamp field from the *Settings* tab.
By default that is set to `@timestamp`.
* The interval for the X Axis is set to `auto`.
The bucket size is determined by the time range.
Expand Down
2 changes: 1 addition & 1 deletion docs/logs/using.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ image::logs/images/logs-console.png[Logs Console in Kibana]
Use the search bar to perform ad hoc searches for specific text.
You can also create structured queries using {kibana-ref}/kuery-query.html[Kibana Query Language].
For example, enter `host.hostname : "host1"` to see only the information for `host1`.
// ++ this isn't quite the same as the corresponding infrastructure description now.
// ++ this isn't quite the same as the corresponding metrics description now.

[float]
[[logs-configure-source]]
Expand Down
4 changes: 2 additions & 2 deletions docs/settings/general-infra-logs-ui-settings.asciidoc
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
`xpack.infra.enabled`:: Set to `false` to disable the Logs and Metrics UI plugin {kib}. Defaults to `true`.
`xpack.infra.enabled`:: Set to `false` to disable the Logs and Metrics app plugin {kib}. Defaults to `true`.

`xpack.infra.sources.default.logAlias`:: Index pattern for matching indices that contain log data. Defaults to `filebeat-*,kibana_sample_data_logs*`. To match multiple wildcard patterns, use a comma to separate the names, with no space after the comma. For example, `logstash-app1-*,default-logs-*`.

`xpack.infra.sources.default.metricAlias`:: Index pattern for matching indices that contain Metricbeat data. Defaults to `metricbeat-*`. To match multiple wildcard patterns, use a comma to separate the names, with no space after the comma. For example, `logstash-app1-*,default-logs-*`.

`xpack.infra.sources.default.fields.timestamp`:: Timestamp used to sort log entries. Defaults to `@timestamp`.

`xpack.infra.sources.default.fields.message`:: Fields used to display messages in the Logs UI. Defaults to `['message', '@message']`.
`xpack.infra.sources.default.fields.message`:: Fields used to display messages in the Logs app. Defaults to `['message', '@message']`.

`xpack.infra.sources.default.fields.tiebreaker`:: Field used to break ties between two entries with the same timestamp. Defaults to `_doc`.

Expand Down
8 changes: 4 additions & 4 deletions docs/settings/infrastructure-ui-settings.asciidoc
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[role="xpack"]
[[infrastructure-ui-settings-kb]]
=== Metrics UI settings in Kibana
=== Metrics settings in Kibana
++++
<titleabbrev>Metrics UI settings</titleabbrev>
<titleabbrev>Metrics settings</titleabbrev>
++++

You do not need to configure any settings to use the Metrics UI. It is enabled by default.
You do not need to configure any settings to use the Metrics app in {kib}. It is enabled by default.

[float]
[[general-infra-ui-settings-kb]]
==== General Metrics UI settings
==== General Metrics settings

include::general-infra-logs-ui-settings.asciidoc[]
8 changes: 4 additions & 4 deletions docs/settings/logs-ui-settings.asciidoc
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[role="xpack"]
[[logs-ui-settings-kb]]
=== Logs UI settings in Kibana
=== Logs app settings in Kibana
++++
<titleabbrev>Logs UI settings</titleabbrev>
<titleabbrev>Logs settings</titleabbrev>
++++

You do not need to configure any settings to use the Logs UI. It is enabled by default.
You do not need to configure any settings to use the Logs app in {kib}. It is enabled by default.

[float]
[[general-logs-ui-settings-kb]]
==== General Logs UI settings
==== General Logs settings

include::general-infra-logs-ui-settings.asciidoc[]
4 changes: 2 additions & 2 deletions docs/uptime-guide/overview.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ The {kibana-ref}/xpack-uptime.html[Elasticsearch Uptime app] in Kibana provides

[float]
=== Example deployments
// ++ I like the Infra/logging diagram which shows Infrastructure and Logging apps as separate components inside Kibana
// ++ In diagram, should be Uptime app, not Uptime UI, possibly even Elastic Uptime? Also applies to Infra/logging/APM.
// ++ I like the Infra/logging diagram which shows Metrics and Logging apps as separate components inside Kibana
// ++ In diagram, should be Uptime app, not Uptime UI, possibly even Elastic Uptime? Also applies to Metrics/Logging/APM.
// ++ Need more whitespace around components.

image::images/uptime-simple-deployment.png[Uptime simple deployment]
Expand Down
4 changes: 2 additions & 2 deletions docs/uptime/overview.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ in an `up` or `down` state are displayed, based on the last check reported by He
for each monitor.

Next to the counts, there is a histogram displaying the change over time throughout the
selected date range.
selected date range.

[float]
=== Monitor list
Expand All @@ -56,7 +56,7 @@ ID and URL, its IP address, and a dedicated sparkline showing its check status o
image::uptime/images/observability_integrations.png[Observability integrations]

The Monitor list also contains a menu of possible integrations. If Uptime detects Kubernetes or
Docker related host information, it will provide links to open the Metrics UI or Logs UI pre-filtered
Docker related host information, it will provide links to open the Metrics app or Logs app pre-filtered
for this host. Additionally, this feature supplies links to simply filter the other views on the host's
IP address, to help you quickly determine if these other solutions contain data relevant to your current
interest.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
"@elastic/charts": "^13.5.9",
"@elastic/datemath": "5.0.2",
"@elastic/ems-client": "1.0.5",
"@elastic/eui": "14.7.0",
"@elastic/eui": "14.8.0",
"@elastic/filesaver": "1.1.2",
"@elastic/good": "8.1.1-kibana2",
"@elastic/numeral": "2.3.3",
Expand Down
1 change: 1 addition & 0 deletions packages/eslint-config-kibana/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module.exports = {
'./javascript.js',
'./typescript.js',
'./jest.js',
'./react.js',
],
plugins: ['@kbn/eslint-plugin-eslint'],

Expand Down
Loading

0 comments on commit 385f494

Please sign in to comment.