Skip to content

Commit

Permalink
Merge branch 'master' of github.com:elastic/kibana into top_terms_filter
Browse files Browse the repository at this point in the history
  • Loading branch information
nreese committed Apr 8, 2020
2 parents f856dae + 1af82c7 commit b4562dc
Show file tree
Hide file tree
Showing 610 changed files with 43,590 additions and 21,383 deletions.
51 changes: 5 additions & 46 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,26 +69,6 @@ module.exports = {
'jsx-a11y/no-onchange': 'off',
},
},
{
files: ['src/legacy/core_plugins/expressions/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: [
'src/legacy/core_plugins/vis_default_editor/public/components/controls/**/*.{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: {
Expand Down Expand Up @@ -552,29 +532,6 @@ module.exports = {
},
},

/**
* Graph overrides
*/
{
files: ['x-pack/legacy/plugins/graph/**/*.js'],
globals: {
angular: true,
$: true,
},
rules: {
'block-scoped-var': 'off',
camelcase: 'off',
eqeqeq: 'off',
'guard-for-in': 'off',
'new-cap': 'off',
'no-loop-func': 'off',
'no-redeclare': 'off',
'no-shadow': 'off',
'no-unused-vars': 'off',
'one-var': 'off',
},
},

/**
* ML overrides
*/
Expand Down Expand Up @@ -771,7 +728,7 @@ module.exports = {
* Lens overrides
*/
{
files: ['x-pack/legacy/plugins/lens/**/*.ts', 'x-pack/legacy/plugins/lens/**/*.tsx'],
files: ['x-pack/legacy/plugins/lens/**/*.{ts,tsx}', 'x-pack/plugins/lens/**/*.{ts,tsx}'],
rules: {
'@typescript-eslint/no-explicit-any': 'error',
},
Expand Down Expand Up @@ -885,8 +842,10 @@ module.exports = {
* TSVB overrides
*/
{
files: ['src/legacy/core_plugins/metrics/**/*.js'],
excludedFiles: 'src/legacy/core_plugins/metrics/index.js',
files: [
'src/plugins/vis_type_timeseries/**/*.{js,ts,tsx}',
'src/legacy/core_plugins/vis_type_timeseries/**/*.{js,ts,tsx}',
],
rules: {
'import/no-default-export': 'error',
},
Expand Down
2 changes: 1 addition & 1 deletion .i18nrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"tileMap": "src/legacy/core_plugins/tile_map",
"timelion": ["src/legacy/core_plugins/timelion", "src/legacy/core_plugins/vis_type_timelion", "src/plugins/timelion"],
"uiActions": "src/plugins/ui_actions",
"visDefaultEditor": "src/legacy/core_plugins/vis_default_editor",
"visDefaultEditor": "src/plugins/vis_default_editor",
"visTypeMarkdown": "src/legacy/core_plugins/vis_type_markdown",
"visTypeMetric": "src/legacy/core_plugins/vis_type_metric",
"visTypeTable": "src/legacy/core_plugins/vis_type_table",
Expand Down
Binary file added docs/apm/images/service-maps-java.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/service-maps.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
48 changes: 48 additions & 0 deletions docs/apm/service-maps.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
[[service-maps]]
=== Service maps

beta::[]

A service map is a real-time diagram of the interactions occurring in your application’s architecture.
It allows you to easily visualize data flow and high-level statistics, like average transaction duration,
requests per minute, errors per minute, and metrics, allowing you to quickly assess the status of your services.

Our beta offering creates two types of service maps:

* Global: All services and connections are shown.
* Service-specific: Selecting a specific service will highlight it's connections.

[role="screenshot"]
image::apm/images/service-maps.png[Example view of service maps in the APM app in Kibana]

[float]
[[visualize-your-architecture]]
=== Visualize your architecture

Select the **Service Map** tab to get started.
By default, all services and connections are shown.
Whether your onboarding a new engineer, or just trying to grasp the big picture,
click around, zoom in and out, and begin to visualize how your services are connected.

If there's a specific service that interests you, select that service to highlight its connections.
Clicking **Focus map** will refocus the map on that specific service and lock the connection highlighting.
From here, select **Service Details**, or click on the **Transaction** tab to jump to the Transaction overview.
You can also use the tabs at the top of the page to easily jump to the **Errors** or **Metrics** overview.

While it's not possible to query in service maps, it is possible to filter by environment.
This can be useful if you have two or more services, in separate environments, but with the same name.
Use the environment drop down to only see the data you're interested in, like `dev` or `production`.

[role="screenshot"]
image::apm/images/service-maps-java.png[Example view of service maps with Java highlighted in the APM app in Kibana]

[float]
[[service-maps-legend]]
=== Legend

Nodes appear on the map in one of two shapes:

* **Circle**: Instrumented services. Interior icons are based on the language of the agent used.
* **Diamond**: Databases, external, and messaging. Interior icons represent the generic type,
with specific icons for known entities, like Elasticsearch.
Type and subtype are based on `span.type`, and `span.subtype`.
4 changes: 1 addition & 3 deletions docs/apm/transactions.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,7 @@ The number of requests per bucket is displayed when hovering over the graph, and
[role="screenshot"]
image::apm/images/apm-transaction-duration-dist.png[Example view of transactions duration distribution graph]

Most of the requests fall into buckets on the left side of the graph,
with a long tail of smaller buckets to the right.
This is a typical distribution, and indicates most of our requests were served quickly - awesome!
This graph shows a typical distribution, and indicates most of our requests were served quickly - awesome!
It's the requests on the right, the ones taking longer than average, that we probably want to focus on.
When you select one of these buckets,
you're presented with up to ten trace samples.
Expand Down
2 changes: 2 additions & 0 deletions docs/apm/using-the-apm-ui.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ include::transactions.asciidoc[]

include::spans.asciidoc[]

include::service-maps.asciidoc[]

include::errors.asciidoc[]

include::metrics.asciidoc[]
Expand Down
4 changes: 3 additions & 1 deletion docs/canvas/canvas-elements.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@ To apply CSS overrides:

. Next to *Element style*, click *+*, then select *CSS*.

. Enter the *CSS*. For example, to center the Markdown element, enter:
. Enter the *CSS*.
+
For example, to center the Markdown element, enter:
+
[source,text]
--------------------------------------------------
Expand Down
4 changes: 2 additions & 2 deletions docs/canvas/canvas-present-workpad.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ When you are ready to present your workpad, use and enable the presentation opti
[[view-fullscreen-mode]]
==== View your workpad in fullscreen mode

In the upper left corner, click the *Enter fullscreen mode* icon.
Click the *Enter fullscreen mode* icon.

[role="screenshot"]
image::images/canvas-fullscreen.png[Fullscreen mode]
Expand All @@ -19,7 +19,7 @@ image::images/canvas-fullscreen.png[Fullscreen mode]

Automatically cycle through your workpads pages in fullscreen mode.

. In the upper left corner, click the *Control settings* icon.
. Click the *Control settings* icon.

. Under *Change cycling interval*, select the interval you want to use.
+
Expand Down
8 changes: 4 additions & 4 deletions docs/canvas/canvas-share-workpad.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ When you've finished your workpad, you can share it outside of {kib}.

Create a JSON file of your workpad that you can export outside of {kib}.

. From your workpad, click the *Share workpad* icon in the upper left corner.
. From your workpad, click the *Share workpad* icon.

. Select *Download as JSON*.
+
Expand All @@ -27,7 +27,7 @@ If you have a license that supports the {report-features}, you can create a PDF

For more information, refer to <<reporting-getting-started, Reporting from Kibana>>.

. From your workpad, click the *Share workpad* icon in the upper left corner, then select *PDF reports*.
. From your workpad, click the *Share workpad* icon, then select *PDF reports*.

. Click *Generate PDF*.
+
Expand All @@ -42,7 +42,7 @@ If you have a license that supports the {report-features}, you can create a POST

For more information, refer to <<automating-report-generation, Automating report generation>>.

. From your workpad, click the *Share workpad* icon in the upper left corner, then select *PDF reports*.
. From your workpad, click the *Share workpad* icon, then select *PDF reports*.

. Click *Copy POST URL*.
+
Expand All @@ -55,7 +55,7 @@ image::images/canvas-create-URL.gif[Create POST URL]

beta[] Canvas allows you to create _shareables_, which are workpads that you download and securely share on any website. To customize the behavior of the workpad on your website, you can choose to autoplay the pages or hide the workpad toolbar.

. From your workpad, click the *Share this workpad* icon in the upper left corner, then select *Share on a website*.
. From your workpad, click the *Share this workpad* icon, then select *Share on a website*.

. On the *Share on a website* pane, follow the instructions.

Expand Down
12 changes: 6 additions & 6 deletions docs/dev-tools/searchprofiler/getting-started.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
=== Getting Started

The {searchprofiler} is automatically enabled in {kib}. Go to *Dev Tools > Search Profiler*
to get started.
to get started.

{searchprofiler} displays the names of the indices searched, the shards in each index,
and how long it took for the query to complete. To try it out, replace the default `match_all` query
and how long it took for the query to complete. To try it out, replace the default `match_all` query
with the query you want to profile and click *Profile*.

The following example shows the results of profiling the `match_all` query.
Expand All @@ -29,8 +29,8 @@ While the Cumulative Time metric is useful for comparing the performance of your
indices and shards, it doesn't necessarily represent the actual physical query times.
====

You can select the name of the shard and then click *View details* to see more profiling information,
including details about the query component(s) that ran on the shard, as well as the timing
You can select the name of the shard and then click *View details* to see more profiling information,
including details about the query component(s) that ran on the shard, as well as the timing
breakdown of low-level Lucene methods. For more information, see {ref}/search-profile.html#profiling-queries[Profiling queries].

[float]
Expand All @@ -40,10 +40,10 @@ By default, all queries executed by the {searchprofiler} are sent
to `GET /_search`. It searches across your entire cluster (all indices, all types).

If you need to query a specific index or type (or several), you can use the Index
and Type filters at the top left.
and Type filters.

In the following example, the query is executed against the indices `test` and `kibana_1`
and the type `my_type`. This is equivalent making a request to `GET /test,kibana_1/my_type/_search`.

[role="screenshot"]
image::dev-tools/searchprofiler/images/filter.png["Filtering by index and type"]
image::dev-tools/searchprofiler/images/filter.png["Filtering by index and type"]
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,15 @@ Registering a feature consists of the following fields. For more information, co
|An array of applications this feature enables. Typically, all of your plugin's apps (from `uiExports`) will be included here.

|`privileges` (required)
|{repo}blob/{branch}/x-pack/plugins/features/server/feature.ts[`FeatureWithAllOrReadPrivileges`].
|{repo}blob/{branch}/x-pack/plugins/features/common/feature.ts[`FeatureConfig`].
|See <<example-1-canvas,Example 1>> and <<example-2-dev-tools,Example 2>>
|The set of privileges this feature requires to function.

|`subFeatures` (optional)
|{repo}blob/{branch}/x-pack/plugins/features/common/feature.ts[`FeatureConfig`].
|See <<example-3-discover,Example 3>>
|The set of subfeatures that enables finer access control than the `all` and `read` feature privileges. These options are only available in the Gold subscription level and higher.

|`icon`
|`string`
|"discoverApp"
Expand Down Expand Up @@ -192,3 +197,78 @@ server.route({
}
});
-----------

[[example-3-discover]]
==== Example 3: Discover

Discover takes advantage of subfeature privileges to allow fine-grained access control. In this example,
a single "Create Short URLs" subfeature privilege is defined, which allows users to grant access to this feature without having to grant the `all` privilege to Discover. In other words, you can grant `read` access to Discover, and also grant the ability to create short URLs.

["source","javascript"]
-----------
init(server) {
const xpackMainPlugin = server.plugins.xpack_main;
xpackMainPlugin.registerFeature({
{
id: 'discover',
name: i18n.translate('xpack.features.discoverFeatureName', {
defaultMessage: 'Discover',
}),
order: 100,
icon: 'discoverApp',
navLinkId: 'kibana:discover',
app: ['kibana'],
catalogue: ['discover'],
privileges: {
all: {
app: ['kibana'],
catalogue: ['discover'],
savedObject: {
all: ['search', 'query'],
read: ['index-pattern'],
},
ui: ['show', 'save', 'saveQuery'],
},
read: {
app: ['kibana'],
catalogue: ['discover'],
savedObject: {
all: [],
read: ['index-pattern', 'search', 'query'],
},
ui: ['show'],
},
},
subFeatures: [
{
name: i18n.translate('xpack.features.ossFeatures.discoverShortUrlSubFeatureName', {
defaultMessage: 'Short URLs',
}),
privilegeGroups: [
{
groupType: 'independent',
privileges: [
{
id: 'url_create',
name: i18n.translate(
'xpack.features.ossFeatures.discoverCreateShortUrlPrivilegeName',
{
defaultMessage: 'Create Short URLs',
}
),
includeIn: 'all',
savedObject: {
all: ['url'],
read: [],
},
ui: ['createShortUrl'],
},
],
},
],
},
],
}
});
}
-----------
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ search: {
intervalOptions: ({
display: string;
val: string;
enabled(agg: import("./search/aggs/buckets/_bucket_agg_type").IBucketAggConfig): boolean | "" | undefined;
enabled(agg: import("./search/aggs/buckets/bucket_agg_type").IBucketAggConfig): boolean | "" | undefined;
} | {
display: string;
val: string;
Expand Down
2 changes: 1 addition & 1 deletion docs/discover/document-data.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ and click image:images/sort-icon.png[].
The first click sorts by ascending order, the second click sorts by descending order, and the third
click removes the field from the sorted fields.

Move a field column:: Hover over the column header and click the move left (<<) or move right icon (>>).
Move a field column:: Hover over the column header and click the (<<) or (>>) icons.
Remove&nbsp;a&nbsp;field&nbsp;column&nbsp;:: Hover over the list of *Specified fields*
and then click *remove*.
Or, use the (x) control in the column header.
Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started/tutorial-visualizing.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -180,5 +180,5 @@ The map now looks like this:
image::images/tutorial-visualize-map-2.png[]

. Navigate the map by clicking and dragging. Use the controls
on the left to zoom the map and set filters.
to zoom the map and set filters.
. *Save* this map with the name `Map Example`.
8 changes: 0 additions & 8 deletions docs/infrastructure/view-metrics.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,3 @@ For complete control over the start and end times, click the start time or end t
=== Refresh the metrics

You can click *Refresh* to manually refresh the metrics.

[float]
[[infra-view-go-to-chart]]
=== Go to a specific chart

The charts available for this component are shown in a list on the left of the page. Click a chart in the list to quickly go to that chart.


Loading

0 comments on commit b4562dc

Please sign in to comment.