Skip to content

Commit aa992cb

Browse files
committed
Merge branch 'master' into feature/refactor-context-initilization
2 parents 1eedfc0 + 748a753 commit aa992cb

File tree

607 files changed

+24831
-6419
lines changed

Some content is hidden

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

607 files changed

+24831
-6419
lines changed

.github/CODEOWNERS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,9 @@
132132
/x-pack/test/alerting_api_integration @elastic/kibana-alerting-services
133133
/x-pack/test/plugin_api_integration/plugins/task_manager @elastic/kibana-alerting-services
134134
/x-pack/test/plugin_api_integration/test_suites/task_manager @elastic/kibana-alerting-services
135+
/x-pack/legacy/plugins/triggers_actions_ui/ @elastic/kibana-alerting-services
136+
/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/ @elastic/kibana-alerting-services
137+
/x-pack/test/functional_with_es_ssl/fixtures/plugins/alerts/ @elastic/kibana-alerting-services
135138

136139
# Design
137140
**/*.scss @elastic/kibana-design

docs/development/core/server/kibana-plugin-server.basepath.get.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ returns `basePath` value, specific for an incoming request.
99
<b>Signature:</b>
1010

1111
```typescript
12-
get: (request: KibanaRequest<unknown, unknown, unknown, any> | LegacyRequest) => string;
12+
get: (request: LegacyRequest | KibanaRequest<unknown, unknown, unknown, any>) => string;
1313
```

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ The constructor for this class is marked as internal. Third-party code should no
2020

2121
| Property | Modifiers | Type | Description |
2222
| --- | --- | --- | --- |
23-
| [get](./kibana-plugin-server.basepath.get.md) | | <code>(request: KibanaRequest&lt;unknown, unknown, unknown, any&gt; &#124; LegacyRequest) =&gt; string</code> | returns <code>basePath</code> value, specific for an incoming request. |
23+
| [get](./kibana-plugin-server.basepath.get.md) | | <code>(request: LegacyRequest &#124; KibanaRequest&lt;unknown, unknown, unknown, any&gt;) =&gt; string</code> | returns <code>basePath</code> value, specific for an incoming request. |
2424
| [prepend](./kibana-plugin-server.basepath.prepend.md) | | <code>(path: string) =&gt; string</code> | Prepends <code>path</code> with the basePath. |
2525
| [remove](./kibana-plugin-server.basepath.remove.md) | | <code>(path: string) =&gt; string</code> | Removes the prepended basePath from the <code>path</code>. |
2626
| [serverBasePath](./kibana-plugin-server.basepath.serverbasepath.md) | | <code>string</code> | returns the server's basePath<!-- -->See [BasePath.get](./kibana-plugin-server.basepath.get.md) for getting the basePath value for a specific request |
27-
| [set](./kibana-plugin-server.basepath.set.md) | | <code>(request: KibanaRequest&lt;unknown, unknown, unknown, any&gt; &#124; LegacyRequest, requestSpecificBasePath: string) =&gt; void</code> | sets <code>basePath</code> value, specific for an incoming request. |
27+
| [set](./kibana-plugin-server.basepath.set.md) | | <code>(request: LegacyRequest &#124; KibanaRequest&lt;unknown, unknown, unknown, any&gt;, requestSpecificBasePath: string) =&gt; void</code> | sets <code>basePath</code> value, specific for an incoming request. |
2828

docs/development/core/server/kibana-plugin-server.basepath.set.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ sets `basePath` value, specific for an incoming request.
99
<b>Signature:</b>
1010

1111
```typescript
12-
set: (request: KibanaRequest<unknown, unknown, unknown, any> | LegacyRequest, requestSpecificBasePath: string) => void;
12+
set: (request: LegacyRequest | KibanaRequest<unknown, unknown, unknown, any>, requestSpecificBasePath: string) => void;
1313
```
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-server](./kibana-plugin-server.md) &gt; [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) &gt; [deprecation](./kibana-plugin-server.uisettingsparams.deprecation.md)
4+
5+
## UiSettingsParams.deprecation property
6+
7+
optional deprecation information. Used to generate a deprecation warning.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
deprecation?: DeprecationSettings;
13+
```

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,14 @@ export interface UiSettingsParams
1717
| Property | Type | Description |
1818
| --- | --- | --- |
1919
| [category](./kibana-plugin-server.uisettingsparams.category.md) | <code>string[]</code> | used to group the configured setting in the UI |
20+
| [deprecation](./kibana-plugin-server.uisettingsparams.deprecation.md) | <code>DeprecationSettings</code> | optional deprecation information. Used to generate a deprecation warning. |
2021
| [description](./kibana-plugin-server.uisettingsparams.description.md) | <code>string</code> | description provided to a user in UI |
2122
| [name](./kibana-plugin-server.uisettingsparams.name.md) | <code>string</code> | title in the UI |
2223
| [optionLabels](./kibana-plugin-server.uisettingsparams.optionlabels.md) | <code>Record&lt;string, string&gt;</code> | text labels for 'select' type UI element |
2324
| [options](./kibana-plugin-server.uisettingsparams.options.md) | <code>string[]</code> | array of permitted values for this setting |
2425
| [readonly](./kibana-plugin-server.uisettingsparams.readonly.md) | <code>boolean</code> | a flag indicating that value cannot be changed |
2526
| [requiresPageReload](./kibana-plugin-server.uisettingsparams.requirespagereload.md) | <code>boolean</code> | a flag indicating whether new value applying requires page reloading |
2627
| [type](./kibana-plugin-server.uisettingsparams.type.md) | <code>UiSettingsType</code> | defines a type of UI element [UiSettingsType](./kibana-plugin-server.uisettingstype.md) |
28+
| [validation](./kibana-plugin-server.uisettingsparams.validation.md) | <code>ImageValidation &#124; StringValidation</code> | |
2729
| [value](./kibana-plugin-server.uisettingsparams.value.md) | <code>SavedObjectAttribute</code> | default value to fall back to if a user doesn't provide any |
2830

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-server](./kibana-plugin-server.md) &gt; [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) &gt; [validation](./kibana-plugin-server.uisettingsparams.validation.md)
4+
5+
## UiSettingsParams.validation property
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
validation?: ImageValidation | StringValidation;
11+
```

docs/management/advanced-options.asciidoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,8 @@ Refresh the page to apply the changes.
187187
=== Search settings
188188

189189
[horizontal]
190-
`courier:batchSearches`:: When disabled, dashboard panels will load individually, and search requests will terminate when
190+
`courier:batchSearches`:: **Deprecated in 7.6. Starting in 8.0, this setting will be optimized internally.**
191+
When disabled, dashboard panels will load individually, and search requests will terminate when
191192
users navigate away or update the query. When enabled, dashboard panels will load together when all of the data is loaded,
192193
and searches will not terminate.
193194
`courier:customRequestPreference`:: {ref}/search-request-body.html#request-body-search-preference[Request preference]

docs/setup/production.asciidoc

Lines changed: 36 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
* <<configuring-kibana-shield>>
55
* <<csp-strict-mode>>
66
* <<enabling-ssl>>
7-
* <<load-balancing>>
7+
* <<load-balancing-es>>
8+
* <<load-balancing-kibana>>
89
* <<high-availability>>
910
* <<memory>>
1011

@@ -18,7 +19,7 @@ While Kibana isn't terribly resource intensive, we still recommend running Kiban
1819
separate from your Elasticsearch data or master nodes. To distribute Kibana
1920
traffic across the nodes in your Elasticsearch cluster, you can run Kibana
2021
and an Elasticsearch client node on the same machine. For more information, see
21-
<<load-balancing, Load Balancing Across Multiple Elasticsearch Nodes>>.
22+
<<load-balancing-es, Load balancing across multiple Elasticsearch nodes>>.
2223

2324
[float]
2425
[[configuring-kibana-shield]]
@@ -63,7 +64,7 @@ csp.strict: true
6364
See <<configuring-tls>>.
6465

6566
[float]
66-
[[load-balancing]]
67+
[[load-balancing-es]]
6768
=== Load Balancing Across Multiple Elasticsearch Nodes
6869
If you have multiple nodes in your Elasticsearch cluster, the easiest way to distribute Kibana requests
6970
across the nodes is to run an Elasticsearch _Coordinating only_ node on the same machine as Kibana.
@@ -110,9 +111,40 @@ transport.tcp.port: 9300 - 9400
110111
elasticsearch.hosts: ["http://localhost:9200"]
111112
--------
112113

114+
[float]
115+
[[load-balancing-kibana]]
116+
=== Load balancing across multiple Kibana instances
117+
To serve multiple Kibana installations behind a load balancer, you must change the configuration. See {kibana-ref}/settings.html[Configuring Kibana] for details on each setting.
118+
119+
Settings unique across each Kibana instance:
120+
--------
121+
server.uuid
122+
server.name
123+
--------
124+
125+
Settings unique across each host (for example, running multiple installations on the same virtual machine):
126+
--------
127+
logging.dest
128+
path.data
129+
pid.file
130+
server.port
131+
--------
132+
133+
Settings that must be the same:
134+
--------
135+
xpack.security.encryptionKey //decrypting session cookies
136+
xpack.reporting.encryptionKey //decrypting reports stored in Elasticsearch
137+
--------
138+
139+
Separate configuration files can be used from the command line by using the `-c` flag:
140+
--------
141+
bin/kibana -c config/instance1.yml
142+
bin/kibana -c config/instance2.yml
143+
--------
144+
113145
[float]
114146
[[high-availability]]
115-
=== High Availability Across Multiple Elasticsearch Nodes
147+
=== High availability across multiple Elasticsearch nodes
116148
Kibana can be configured to connect to multiple Elasticsearch nodes in the same cluster. In situations where a node becomes unavailable,
117149
Kibana will transparently connect to an available node and continue operating. Requests to available hosts will be routed in a round robin fashion.
118150

examples/state_containers_examples/public/todo.tsx

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ import {
4141
PureTransition,
4242
syncStates,
4343
getStateFromKbnUrl,
44+
BaseState,
4445
} from '../../../src/plugins/kibana_utils/public';
4546
import { useUrlTracker } from '../../../src/plugins/kibana_react/public';
4647
import {
@@ -79,7 +80,7 @@ const TodoApp: React.FC<TodoAppProps> = ({ filter }) => {
7980
const { setText } = GlobalStateHelpers.useTransitions();
8081
const { text } = GlobalStateHelpers.useState();
8182
const { edit: editTodo, delete: deleteTodo, add: addTodo } = useTransitions();
82-
const todos = useState();
83+
const todos = useState().todos;
8384
const filteredTodos = todos.filter(todo => {
8485
if (!filter) return true;
8586
if (filter === 'completed') return todo.completed;
@@ -306,22 +307,18 @@ export const TodoAppPage: React.FC<{
306307
);
307308
};
308309

309-
function withDefaultState<State>(
310+
function withDefaultState<State extends BaseState>(
310311
stateContainer: BaseStateContainer<State>,
311312
// eslint-disable-next-line no-shadow
312313
defaultState: State
313314
): INullableBaseStateContainer<State> {
314315
return {
315316
...stateContainer,
316317
set: (state: State | null) => {
317-
if (Array.isArray(defaultState)) {
318-
stateContainer.set(state || defaultState);
319-
} else {
320-
stateContainer.set({
321-
...defaultState,
322-
...state,
323-
});
324-
}
318+
stateContainer.set({
319+
...defaultState,
320+
...state,
321+
});
325322
},
326323
};
327324
}

0 commit comments

Comments
 (0)