Skip to content

Commit

Permalink
Merge branch 'master' into fix-tms-in-legacy-maps
Browse files Browse the repository at this point in the history
  • Loading branch information
elasticmachine authored Jul 29, 2020
2 parents 151a3f6 + 20de32a commit 67c030a
Show file tree
Hide file tree
Showing 418 changed files with 7,742 additions and 4,839 deletions.
18 changes: 0 additions & 18 deletions docs/apm/error-reports-watcher.asciidoc

This file was deleted.

3 changes: 0 additions & 3 deletions docs/apm/how-to-guides.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ Learn how to perform common APM app tasks.
* <<agent-configuration>>
* <<apm-alerts>>
* <<custom-links>>
* <<errors-alerts-with-watcher>>
* <<filters>>
* <<machine-learning-integration>>
* <<advanced-queries>>
Expand All @@ -21,8 +20,6 @@ include::apm-alerts.asciidoc[]

include::custom-links.asciidoc[]

include::error-reports-watcher.asciidoc[]

include::filters.asciidoc[]

include::machine-learning.asciidoc[]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,6 @@ export interface RouteConfigOptions<Method extends RouteMethod>
| [authRequired](./kibana-plugin-core-server.routeconfigoptions.authrequired.md) | <code>boolean &#124; 'optional'</code> | Defines authentication mode for a route: - true. A user has to have valid credentials to access a resource - false. A user can access a resource without any credentials. - 'optional'. A user can access a resource if has valid credentials or no credentials at all. Can be useful when we grant access to a resource but want to identify a user if possible.<!-- -->Defaults to <code>true</code> if an auth mechanism is registered. |
| [body](./kibana-plugin-core-server.routeconfigoptions.body.md) | <code>Method extends 'get' &#124; 'options' ? undefined : RouteConfigOptionsBody</code> | Additional body options [RouteConfigOptionsBody](./kibana-plugin-core-server.routeconfigoptionsbody.md)<!-- -->. |
| [tags](./kibana-plugin-core-server.routeconfigoptions.tags.md) | <code>readonly string[]</code> | Additional metadata tag strings to attach to the route. |
| [timeout](./kibana-plugin-core-server.routeconfigoptions.timeout.md) | <code>number</code> | Timeouts for processing durations. Response timeout is in milliseconds. Default value: 2 minutes |
| [xsrfRequired](./kibana-plugin-core-server.routeconfigoptions.xsrfrequired.md) | <code>Method extends 'get' ? never : boolean</code> | Defines xsrf protection requirements for a route: - true. Requires an incoming POST/PUT/DELETE request to contain <code>kbn-xsrf</code> header. - false. Disables xsrf protection.<!-- -->Set to true by default |

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [RouteConfigOptions](./kibana-plugin-core-server.routeconfigoptions.md) &gt; [timeout](./kibana-plugin-core-server.routeconfigoptions.timeout.md)

## RouteConfigOptions.timeout property

Timeouts for processing durations. Response timeout is in milliseconds. Default value: 2 minutes

<b>Signature:</b>

```typescript
timeout?: number;
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ Helper to setup two-way syncing of global data and a state container
<b>Signature:</b>

```typescript
connectToQueryState: <S extends QueryState>({ timefilter: { timefilter }, filterManager, state$, }: Pick<QueryStart | QuerySetup, 'timefilter' | 'filterManager' | 'state$'>, stateContainer: BaseStateContainer<S>, syncConfig: {
connectToQueryState: <S extends QueryState>({ timefilter: { timefilter }, filterManager, queryString, state$, }: Pick<QueryStart | QuerySetup, 'timefilter' | 'filterManager' | 'queryString' | 'state$'>, stateContainer: BaseStateContainer<S>, syncConfig: {
time?: boolean;
refreshInterval?: boolean;
filters?: FilterStateStore | boolean;
query?: boolean;
}) => () => void
```
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export interface QueryState
| Property | Type | Description |
| --- | --- | --- |
| [filters](./kibana-plugin-plugins-data-public.querystate.filters.md) | <code>Filter[]</code> | |
| [query](./kibana-plugin-plugins-data-public.querystate.query.md) | <code>Query</code> | |
| [refreshInterval](./kibana-plugin-plugins-data-public.querystate.refreshinterval.md) | <code>RefreshInterval</code> | |
| [time](./kibana-plugin-plugins-data-public.querystate.time.md) | <code>TimeRange</code> | |

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; [QueryState](./kibana-plugin-plugins-data-public.querystate.md) &gt; [query](./kibana-plugin-plugins-data-public.querystate.query.md)

## QueryState.query property

<b>Signature:</b>

```typescript
query?: Query;
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Helper to setup syncing of global data with the URL
<b>Signature:</b>

```typescript
syncQueryStateWithUrl: (query: Pick<QueryStart | QuerySetup, 'filterManager' | 'timefilter' | 'state$'>, kbnUrlStateStorage: IKbnUrlStateStorage) => {
syncQueryStateWithUrl: (query: Pick<QueryStart | QuerySetup, 'filterManager' | 'timefilter' | 'queryString' | 'state$'>, kbnUrlStateStorage: IKbnUrlStateStorage) => {
stop: () => void;
hasInheritedQueryFromUrl: boolean;
}
Expand Down
10 changes: 10 additions & 0 deletions docs/redirects.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,13 @@ This page was deleted. See <<development-visualize-index>>.
== Developing Visualizations

This page was deleted. See <<development-visualize-index>>.

[role="exclude",id="errors-alerts-with-watcher"]
== Error reports with Watcher

deprecated::[7.9.0]

Watcher error reports have been removed and replaced with Kibana's <<apm-alerts,alerting and actions>> feature.
To create error alerts with new tool, select **Alerts** - **Create threshold alert** - **Error rate**.

More information on this new feature is available in <<apm-alerts>>.
2 changes: 1 addition & 1 deletion docs/setup/production.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ These can be used to automatically update the list of hosts as a cluster is resi
Kibana has a default maximum memory limit of 1.4 GB, and in most cases, we recommend leaving this unconfigured. In some scenarios, such as large reporting jobs,
it may make sense to tweak limits to meet more specific requirements.

You can modify this limit by setting `--max-old-space-size` in the `node.options` config file that can be found inside `kibana/config` folder or any other configured with the environment variable `KIBANA_PATH_CONF` (for example in debian based system would be `/etc/kibana`).
You can modify this limit by setting `--max-old-space-size` in the `node.options` config file that can be found inside `kibana/config` folder or any other configured with the environment variable `KBN_PATH_CONF` (for example in debian based system would be `/etc/kibana`).

The option accepts a limit in MB:
--------
Expand Down
Binary file added docs/visualize/images/lens_aggregation_labels.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/visualize/images/lens_data_info.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/visualize/images/lens_drag_drop.gif
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/visualize/images/lens_index_pattern.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/visualize/images/lens_layers.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/visualize/images/lens_suggestions.gif
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/visualize/images/lens_tutorial_1.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/visualize/images/lens_tutorial_2.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/visualize/images/lens_tutorial_3.1.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/visualize/images/lens_tutorial_3.2.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/visualize/images/lens_tutorial_3.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/visualize/images/lens_viz_types.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
60 changes: 35 additions & 25 deletions docs/visualize/lens.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,22 @@

beta[]

*Lens* is a simple and fast way to create visualizations of your {es} data. With *Lens*,
*Lens* is a simple and fast way to create visualizations of your {es} data. To create visualizations,
you drag and drop your data fields onto the visualization builder pane, and *Lens* automatically generates
a visualization that best displays your data.

With Lens, you can:

* Explore your data in just a few clicks.
* Use the automatically generated visualization suggestions to change the visualization type.

* Create visualizations with multiple layers and indices.

* Use the automatically generated visualization suggestions to change the visualization type.

* Add your visualizations to dashboards and Canvas workpads.

To get started with *Lens*, click a field in the data panel, then drag and drop the field on a highlighted area.
To get started with *Lens*, select a field in the data panel, then drag and drop the field on a highlighted area.

[role="screenshot"]
image::images/lens_drag_drop.gif[]
image::images/lens_drag_drop.gif[Drag and drop]

You can incorporate many fields into your visualization, and Lens uses heuristics to decide how to apply each one to the visualization.

Expand All @@ -30,9 +28,9 @@ you can still configure the customization options for your visualization.

[float]
[[apply-lens-filters]]
==== Filter the data panel fields
==== Change the data panel fields

The fields in the data panel based on your selected <<index-patterns, index pattern>>, and the <<set-time-filter,time filter>>.
The fields in the data panel are based on the selected <<index-patterns, index pattern>> and <<set-time-filter,time filter>>.

To change the index pattern, click it, then select a new one. The fields in the data panel automatically update.

Expand All @@ -46,12 +44,12 @@ To filter the fields in the data panel:
[[view-data-summaries]]
==== Data summaries

To help you decide exactly the data you want to display, get a quick summary of each field. The summary shows the distribution of values in the time range.
To help you decide exactly the data you want to display, get a quick summary of each field. The summary shows the distribution of values within the selected time range.

To view the field summary information, navigate to the field, then click *i*.

[role="screenshot"]
image::images/lens_data_info.png[]
image::images/lens_data_info.png[Data summary window]

[float]
[[change-the-visualization-type]]
Expand All @@ -62,7 +60,7 @@ image::images/lens_data_info.png[]
*Suggestions* are shortcuts to alternate visualizations that *Lens* generates for you.

[role="screenshot"]
image::images/lens_suggestions.gif[]
image::images/lens_suggestions.gif[Visualization suggestions]

If you'd like to use a visualization type that is not suggested, click the visualization type,
then select a new one.
Expand All @@ -78,19 +76,30 @@ still allows you to make the change.
[[customize-operation]]
==== Change the aggregation and labels

Lens allows some customizations of the data for each visualization.
For each visualization, Lens allows some customizations of the data.

. Click *Drop a field here* or the field name in the column.

. Change the options that appear depending on the type of field.
. Change the options that appear. Options vary depending on the type of field.
+
[role="screenshot"]
image::images/lens_aggregation_labels.png[Quick function options]

[float]
[[layers]]
==== Add layers and indices

Bar, line, and area charts allow you to visualize multiple data layers and indices so that you can compare and analyze data from multiple sources.
Area, line, and bar charts allow you to visualize multiple data layers and indices so that you can compare and analyze data from multiple sources.

To add a layer, click *+*, then drag and drop the fields for the new layer.

[role="screenshot"]
image::images/lens_layers.png[Add layers]

To view a different index, click it, then select a new one.

To add a layer, click *+*, then drag and drop the fields for the new layer. To view a different index, click it, then select a new one.
[role="screenshot"]
image::images/lens_index_pattern.png[Add index pattern]

[float]
[[lens-tutorial]]
Expand All @@ -110,8 +119,6 @@ To start, you'll need to add the <<add-sample-data, sample ecommerce data>>.

Drag and drop your data onto the visualization builder pane.

. Open *Lens*.

. Select the *kibana_sample_data_ecommerce* index pattern.

. Click image:images/time-filter-calendar.png[], then click *Last 7 days*.
Expand All @@ -138,16 +145,19 @@ image::images/lens_tutorial_2.png[Lens tutorial]

Make your visualization look exactly how you want with the customization options.

. Click *Average of taxful_total_price*.

.. Change the *Label* to `Sales`.

. Click *Top values of category.keyword*.
. Click *Average of taxful_total_price*, then change the *Label* to `Sales`.
+
[role="screenshot"]
image::images/lens_tutorial_3.1.png[Lens tutorial]

.. Change *Number of values* to `10`. The visualization updates to show there are only
six available categories.
. Click *Top values of category.keyword*, then change *Number of values* to `10`.
+
[role="screenshot"]
image::images/lens_tutorial_3.2.png[Lens tutorial]
+
The visualization updates to show there are only six available categories.
+
Look at the *Suggestions*. An area chart is not an option, but for sales data, a stacked area chart might be the best option.
Look at the *Suggestions*. An area chart is not an option, but for the sales data, a stacked area chart might be the best option.

. To switch the chart type, click *Stacked bar chart* in the column, then click *Stacked area* from the *Select a visualizations* window.
+
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* under the License.
*/

import React, { useEffect, useRef, useState, useCallback } from 'react';
import React, { useEffect, useRef, useState } from 'react';
import { History } from 'history';
import { FormattedMessage, I18nProvider } from '@kbn/i18n/react';
import { Router } from 'react-router-dom';
Expand Down Expand Up @@ -85,16 +85,9 @@ const App = ({ navigation, data, history, kbnUrlStateStorage }: StateDemoAppDeps
useGlobalStateSyncing(data.query, kbnUrlStateStorage);
useAppStateSyncing(appStateContainer, data.query, kbnUrlStateStorage);

const onQuerySubmit = useCallback(
({ query }) => {
appStateContainer.set({ ...appState, query });
},
[appStateContainer, appState]
);

const indexPattern = useIndexPattern(data);
if (!indexPattern)
return <div>No index pattern found. Please create an intex patter before loading...</div>;
return <div>No index pattern found. Please create an index patter before loading...</div>;

// Render the application DOM.
// Note that `navigation.ui.TopNavMenu` is a stateful component exported on the `navigation` plugin's start contract.
Expand All @@ -107,8 +100,6 @@ const App = ({ navigation, data, history, kbnUrlStateStorage }: StateDemoAppDeps
showSearchBar={true}
indexPatterns={[indexPattern]}
useDefaultBehaviors={true}
onQuerySubmit={onQuerySubmit}
query={appState.query}
showSaveQuery={true}
/>
<EuiPage restrictWidth="1000px">
Expand Down Expand Up @@ -200,7 +191,7 @@ function useAppStateSyncing<AppState extends QueryState>(
const stopSyncingQueryAppStateWithStateContainer = connectToQueryState(
query,
appStateContainer,
{ filters: esFilters.FilterStateStore.APP_STATE }
{ filters: esFilters.FilterStateStore.APP_STATE, query: true }
);

// sets up syncing app state container with url
Expand Down
14 changes: 7 additions & 7 deletions packages/kbn-storybook/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
"dependencies": {
"@kbn/babel-preset": "1.0.0",
"@kbn/dev-utils": "1.0.0",
"@storybook/addon-actions": "^5.2.8",
"@storybook/addon-actions": "^5.3.19",
"@storybook/addon-console": "^1.2.1",
"@storybook/addon-info": "^5.2.8",
"@storybook/addon-knobs": "^5.2.8",
"@storybook/addon-options": "^5.2.8",
"@storybook/addon-storyshots": "^5.2.8",
"@storybook/react": "^5.2.8",
"@storybook/theming": "^5.2.8",
"@storybook/addon-info": "^5.3.19",
"@storybook/addon-knobs": "^5.3.19",
"@storybook/addon-options": "^5.3.19",
"@storybook/addon-storyshots": "^5.3.19",
"@storybook/react": "^5.3.19",
"@storybook/theming": "^5.3.19",
"copy-webpack-plugin": "^6.0.2",
"fast-glob": "2.2.7",
"glob-watcher": "5.0.3",
Expand Down
2 changes: 1 addition & 1 deletion src/core/public/doc_links/doc_links_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ export class DocLinksService {
kibana: `${ELASTIC_WEBSITE_URL}guide/en/kibana/${DOC_LINK_VERSION}/index.html`,
siem: {
guide: `${ELASTIC_WEBSITE_URL}guide/en/security/${DOC_LINK_VERSION}/index.html`,
gettingStarted: `${ELASTIC_WEBSITE_URL}guide/en/security/${DOC_LINK_VERSION}/install-siem.html`,
gettingStarted: `${ELASTIC_WEBSITE_URL}guide/en/security/${DOC_LINK_VERSION}/index.html`,
},
query: {
luceneQuerySyntax: `${ELASTICSEARCH_DOCS}query-dsl-query-string-query.html#query-string-syntax`,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ describe('core deprecations', () => {
const { messages } = applyCoreDeprecations();
expect(messages).toMatchInlineSnapshot(`
Array [
"Environment variable CONFIG_PATH is deprecated. It has been replaced with KIBANA_PATH_CONF pointing to a config folder",
"Environment variable CONFIG_PATH is deprecated. It has been replaced with KBN_PATH_CONF pointing to a config folder",
]
`);
});
Expand Down
2 changes: 1 addition & 1 deletion src/core/server/config/deprecation/core_deprecations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import { ConfigDeprecationProvider, ConfigDeprecation } from './types';
const configPathDeprecation: ConfigDeprecation = (settings, fromPath, log) => {
if (has(process.env, 'CONFIG_PATH')) {
log(
`Environment variable CONFIG_PATH is deprecated. It has been replaced with KIBANA_PATH_CONF pointing to a config folder`
`Environment variable CONFIG_PATH is deprecated. It has been replaced with KBN_PATH_CONF pointing to a config folder`
);
}
return settings;
Expand Down
Loading

0 comments on commit 67c030a

Please sign in to comment.