Skip to content

Commit

Permalink
Merge branch 'master' of github.com:elastic/kibana into reporting/add…
Browse files Browse the repository at this point in the history
…-link-to-kibana-app

* 'master' of github.com:elastic/kibana: (30 commits)
  Fix potential error from undefined (elastic#115562)
  [App Search, Crawler] Fix validation step panel padding/whitespace (elastic#115542)
  [Cases][Connectors] ServiceNow ITOM: MVP (elastic#114125)
  Change default session idle timeout to 8 hours. (elastic#115565)
  Upgrade EUI to v39.1.1 (elastic#114732)
  [App Search] Wired up organic results on Curation Suggestions view (elastic#114717)
  [i18n] remove i18n html extractor (elastic#115004)
  [Logs/Metrics UI] Add deprecated field configuration to Deprecations API (elastic#115103)
  [Transform] Add alerting rules management to Transform UI (elastic#115363)
  Update UI links to Fleet and Agent docs (elastic#115295)
  [ML] Adding ability to change data view in advanced job wizard (elastic#115191)
  Change deleteByNamespace to include legacy URL aliases (elastic#115459)
  [Unified Integrations] Remove and cleanup add data views (elastic#115424)
  [Discover] Show ignored field values (elastic#115040)
  [ML] Stop reading the ml.max_open_jobs node attribute (elastic#115524)
  [Discover] Improve doc viewer code in Discover (elastic#114759)
  [Security Solutions] Adds security detection rule actions as importable and exportable (elastic#115243)
  [Security Solution] [Platform] Migrate legacy actions whenever user interacts with the rule (elastic#115101)
  [Fleet] Add telemetry for integration cards (elastic#115413)
  🐛 Fix single percentile case when ES is returning no buckets (elastic#115214)
  ...

# Conflicts:
#	x-pack/plugins/reporting/public/management/__snapshots__/report_listing.test.tsx.snap
  • Loading branch information
jloleysens committed Oct 19, 2021
2 parents 97b0e2a + 9d0bf40 commit 2781812
Show file tree
Hide file tree
Showing 375 changed files with 9,325 additions and 3,923 deletions.
9 changes: 9 additions & 0 deletions docs/dev-tools/console/console.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -129,3 +129,12 @@ image::dev-tools/console/images/console-settings.png["Console Settings", width=6

For a list of available keyboard
shortcuts, click *Help*.

[float]
[[console-settings]]
=== Disable Console

If you don’t want to use *Console*, you can disable it by setting `console.ui.enabled`
to `false` in your `kibana.yml` configuration file. Changing this setting
causes the server to regenerate assets on the next startup,
which might cause a delay before pages start being served.
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ readonly links: {
elasticAgent: string;
datastreams: string;
datastreamsNamingScheme: string;
installElasticAgent: string;
upgradeElasticAgent: string;
upgradeElasticAgent712lower: string;
learnMoreBlog: string;
Expand Down

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions docs/management/action-types.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ a| <<servicenow-sir-action-type, ServiceNow SecOps>>

| Create a security incident in ServiceNow.

a| <<servicenow-itom-action-type, ServiceNow ITOM>>

| Create an event in ServiceNow.

a| <<slack-action-type, Slack>>

| Send a message to a Slack channel or user.
Expand Down
90 changes: 90 additions & 0 deletions docs/management/connectors/action-types/servicenow-itom.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
[role="xpack"]
[[servicenow-itom-action-type]]
=== ServiceNow connector and action
++++
<titleabbrev>ServiceNow ITOM</titleabbrev>
++++

The ServiceNow ITOM connector uses the https://docs.servicenow.com/bundle/rome-it-operations-management/page/product/event-management/task/send-events-via-web-service.html[Event API] to create ServiceNow events.

[float]
[[servicenow-itom-connector-configuration]]
==== Connector configuration

ServiceNow ITOM connectors have the following configuration properties.

Name:: The name of the connector. The name is used to identify a connector in the **Stack Management** UI connector listing, and in the connector list when configuring an action.
URL:: ServiceNow instance URL.
Username:: Username for HTTP Basic authentication.
Password:: Password for HTTP Basic authentication.

The ServiceNow user requires at minimum read, create, and update access to the Event table and read access to the https://docs.servicenow.com/bundle/paris-platform-administration/page/administer/localization/reference/r_ChoicesTable.html[sys_choice]. If you don't provide access to sys_choice, then the choices will not render.

[float]
[[servicenow-itom-connector-networking-configuration]]
==== Connector networking configuration

Use the <<action-settings, Action configuration settings>> to customize connector networking configurations, such as proxies, certificates, or TLS settings. You can set configurations that apply to all your connectors or use `xpack.actions.customHostSettings` to set per-host configurations.

[float]
[[Preconfigured-servicenow-itom-configuration]]
==== Preconfigured connector type

[source,text]
--
my-servicenow-itom:
name: preconfigured-servicenow-connector-type
actionTypeId: .servicenow-itom
config:
apiUrl: https://example.service-now.com/
secrets:
username: testuser
password: passwordkeystorevalue
--

Config defines information for the connector type.

`apiUrl`:: An address that corresponds to *URL*.

Secrets defines sensitive information for the connector type.

`username`:: A string that corresponds to *Username*.
`password`:: A string that corresponds to *Password*. Should be stored in the <<creating-keystore, {kib} keystore>>.

[float]
[[define-servicenow-itom-ui]]
==== Define connector in Stack Management

Define ServiceNow ITOM connector properties.

[role="screenshot"]
image::management/connectors/images/servicenow-itom-connector.png[ServiceNow ITOM connector]

Test ServiceNow ITOM action parameters.

[role="screenshot"]
image::management/connectors/images/servicenow-itom-params-test.png[ServiceNow ITOM params test]

[float]
[[servicenow-itom-action-configuration]]
==== Action configuration

ServiceNow ITOM actions have the following configuration properties.

Source:: The name of the event source type.
Node:: The Host that the event was triggered for.
Type:: The type of event.
Resource:: The name of the resource.
Metric name:: Name of the metric.
Source instance (event_class):: Specific instance of the source.
Message key:: All actions sharing this key will be associated with the same ServiceNow alert. Default value: `<rule ID>:<alert instance ID>`.
Severity:: The severity of the event.
Description:: The details about the event.

Refer to https://docs.servicenow.com/bundle/rome-it-operations-management/page/product/event-management/task/send-events-via-web-service.html[ServiceNow documentation] for more information about the properties.

[float]
[[configuring-servicenow-itom]]
==== Configure ServiceNow ITOM

ServiceNow offers free https://developer.servicenow.com/dev.do#!/guides/madrid/now-platform/pdi-guide/obtaining-a-pdi[Personal Developer Instances], which you can use to test incidents.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Use the <<action-settings, Action configuration settings>> to customize connecto
name: preconfigured-servicenow-connector-type
actionTypeId: .servicenow-sir
config:
apiUrl: https://dev94428.service-now.com/
apiUrl: https://example.service-now.com/
secrets:
username: testuser
password: passwordkeystorevalue
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Use the <<action-settings, Action configuration settings>> to customize connecto
name: preconfigured-servicenow-connector-type
actionTypeId: .servicenow
config:
apiUrl: https://dev94428.service-now.com/
apiUrl: https://example.service-now.com/
secrets:
username: testuser
password: passwordkeystorevalue
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/management/connectors/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ include::action-types/pagerduty.asciidoc[]
include::action-types/server-log.asciidoc[]
include::action-types/servicenow.asciidoc[]
include::action-types/servicenow-sir.asciidoc[]
include::action-types/servicenow-itom.asciidoc[]
include::action-types/swimlane.asciidoc[]
include::action-types/slack.asciidoc[]
include::action-types/webhook.asciidoc[]
Expand Down
2 changes: 1 addition & 1 deletion docs/settings/security-settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ You can configure the following settings in the `kibana.yml` file.

|[[xpack-session-idleTimeout]] `xpack.security.session.idleTimeout` {ess-icon}
| Ensures that user sessions will expire after a period of inactivity. This and <<xpack-session-lifespan,`xpack.security.session.lifespan`>> are both
highly recommended. You can also specify this setting for <<xpack-security-provider-session-idleTimeout, every provider separately>>. If this is set to `0`, then sessions will never expire due to inactivity. By default, this value is 1 hour.
highly recommended. You can also specify this setting for <<xpack-security-provider-session-idleTimeout, every provider separately>>. If this is set to `0`, then sessions will never expire due to inactivity. By default, this value is 8 hours.

2+a|
[TIP]
Expand Down
34 changes: 34 additions & 0 deletions docs/setup/settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ configuration using `${MY_ENV_VAR}` syntax.
[cols="2*<"]
|===

| `console.ui.enabled:`
Toggling this causes the server to regenerate assets on the next startup,
which may cause a delay before pages start being served.
Set to `false` to disable Console. *Default: `true`*

| `csp.rules:`
| deprecated:[7.14.0,"In 8.0 and later, this setting will no longer be supported."]
A https://w3c.github.io/webappsec-csp/[Content Security Policy] template
Expand Down Expand Up @@ -681,6 +686,10 @@ out through *Advanced Settings*. *Default: `true`*
| Set this value to true to allow Vega to use any URL to access external data
sources and images. When false, Vega can only get data from {es}. *Default: `false`*

| `xpack.ccr.ui.enabled`
Set this value to false to disable the Cross-Cluster Replication UI.
*Default: `true`*

|[[settings-explore-data-in-context]] `xpack.discoverEnhanced.actions.`
`exploreDataInContextMenu.enabled`
| Enables the *Explore underlying data* option that allows you to open *Discover* from a dashboard panel and view the panel data. *Default: `false`*
Expand All @@ -689,6 +698,31 @@ sources and images. When false, Vega can only get data from {es}. *Default: `fal
`exploreDataInChart.enabled`
| Enables you to view the underlying documents in a data series from a dashboard panel. *Default: `false`*

| `xpack.ilm.ui.enabled`
Set this value to false to disable the Index Lifecycle Policies UI.
*Default: `true`*

| `xpack.index_management.ui.enabled`
Set this value to false to disable the Index Management UI.
*Default: `true`*

| `xpack.license_management.ui.enabled`
Set this value to false to disable the License Management UI.
*Default: `true`*

| `xpack.remote_clusters.ui.enabled`
Set this value to false to disable the Remote Clusters UI.
*Default: `true`*

| `xpack.rollup.ui.enabled:`
Set this value to false to disable the Rollup Jobs UI. *Default: true*

| `xpack.snapshot_restore.ui.enabled:`
Set this value to false to disable the Snapshot and Restore UI. *Default: true*

| `xpack.upgrade_assistant.ui.enabled:`
Set this value to false to disable the Upgrade Assistant UI. *Default: true*

| `i18n.locale` {ess-icon}
| Set this value to change the {kib} interface language.
Valid locales are: `en`, `zh-CN`, `ja-JP`. *Default: `en`*
Expand Down
2 changes: 1 addition & 1 deletion docs/user/security/session-management.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ To manage user sessions programmatically, {kib} exposes <<session-management-api
==== Session idle timeout

You can use `xpack.security.session.idleTimeout` to expire sessions after a period of inactivity. This and `xpack.security.session.lifespan` are both highly recommended.
By default, sessions expire after 1 hour of inactivity. To define another value for a sliding session expiration, set the property in the `kibana.yml` configuration file. The idle timeout is formatted as a duration of `<count>[ms|s|m|h|d|w|M|Y]` (e.g. '20m', '24h', '7d', '1w'). For example, set the idle timeout to expire sessions after 30 minutes of inactivity:
By default, sessions expire after 8 hours of inactivity. To define another value for a sliding session expiration, set the property in the `kibana.yml` configuration file. The idle timeout is formatted as a duration of `<count>[ms|s|m|h|d|w|M|Y]` (e.g. '20m', '24h', '7d', '1w'). For example, set the idle timeout to expire sessions after 30 minutes of inactivity:

--
[source,yaml]
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@
"@elastic/datemath": "link:bazel-bin/packages/elastic-datemath",
"@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@^8.0.0-canary.21",
"@elastic/ems-client": "7.16.0",
"@elastic/eui": "39.0.0",
"@elastic/eui": "39.1.1",
"@elastic/filesaver": "1.1.2",
"@elastic/maki": "6.3.0",
"@elastic/node-crypto": "1.2.1",
Expand Down
4 changes: 3 additions & 1 deletion src/core/public/doc_links/doc_links_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -477,9 +477,10 @@ export class DocLinksService {
settings: `${FLEET_DOCS}fleet-settings.html#fleet-server-hosts-setting`,
settingsFleetServerHostSettings: `${FLEET_DOCS}fleet-settings.html#fleet-server-hosts-setting`,
troubleshooting: `${FLEET_DOCS}fleet-troubleshooting.html`,
elasticAgent: `${FLEET_DOCS}elastic-agent-installation-configuration.html`,
elasticAgent: `${FLEET_DOCS}elastic-agent-installation.html`,
datastreams: `${FLEET_DOCS}data-streams.html`,
datastreamsNamingScheme: `${FLEET_DOCS}data-streams.html#data-streams-naming-scheme`,
installElasticAgent: `${FLEET_DOCS}install-fleet-managed-elastic-agent.html`,
upgradeElasticAgent: `${FLEET_DOCS}upgrade-elastic-agent.html`,
upgradeElasticAgent712lower: `${FLEET_DOCS}upgrade-elastic-agent.html#upgrade-7.12-lower`,
learnMoreBlog: `${ELASTIC_WEBSITE_URL}blog/elastic-agent-and-fleet-make-it-easier-to-integrate-your-systems-with-elastic`,
Expand Down Expand Up @@ -740,6 +741,7 @@ export interface DocLinksStart {
elasticAgent: string;
datastreams: string;
datastreamsNamingScheme: string;
installElasticAgent: string;
upgradeElasticAgent: string;
upgradeElasticAgent712lower: string;
learnMoreBlog: string;
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion src/core/public/i18n/i18n_eui_mapping.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export const getEuiContextMapping = (): EuiTokensObject => {
}),
'euiBasicTable.tablePagination': ({ tableCaption }: EuiValues) =>
i18n.translate('core.euiBasicTable.tablePagination', {
defaultMessage: 'Pagination for preceding table: {tableCaption}',
defaultMessage: 'Pagination for table: {tableCaption}',
values: { tableCaption },
description: 'Screen reader text to describe the pagination controls',
}),
Expand Down Expand Up @@ -861,6 +861,9 @@ export const getEuiContextMapping = (): EuiTokensObject => {
'euiRelativeTab.numberInputLabel': i18n.translate('core.euiRelativeTab.numberInputLabel', {
defaultMessage: 'Time span amount',
}),
'euiRelativeTab.dateInputError': i18n.translate('core.euiRelativeTab.dateInputError', {
defaultMessage: 'Must be a valid range',
}),
'euiResizableButton.horizontalResizerAriaLabel': i18n.translate(
'core.euiResizableButton.horizontalResizerAriaLabel',
{
Expand Down
1 change: 1 addition & 0 deletions src/core/public/public.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -706,6 +706,7 @@ export interface DocLinksStart {
elasticAgent: string;
datastreams: string;
datastreamsNamingScheme: string;
installElasticAgent: string;
upgradeElasticAgent: string;
upgradeElasticAgent712lower: string;
learnMoreBlog: string;
Expand Down
1 change: 1 addition & 0 deletions src/core/server/saved_objects/object_types/registration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ const legacyUrlAliasType: SavedObjectsType = {
properties: {
sourceId: { type: 'keyword' },
targetType: { type: 'keyword' },
targetNamespace: { type: 'keyword' },
resolveCounter: { type: 'long' },
disabled: { type: 'boolean' },
// other properties exist, but we aren't querying or aggregating on those, so we don't need to specify them (because we use `dynamic: false` above)
Expand Down
7 changes: 6 additions & 1 deletion src/core/server/saved_objects/service/lib/repository.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import { encodeHitVersion } from '../../version';
import { SavedObjectTypeRegistry } from '../../saved_objects_type_registry';
import { DocumentMigrator } from '../../migrations/core/document_migrator';
import { mockKibanaMigrator } from '../../migrations/kibana/kibana_migrator.mock';
import { LEGACY_URL_ALIAS_TYPE } from '../../object_types';
import { elasticsearchClientMock } from '../../../elasticsearch/client/mocks';
import * as esKuery from '@kbn/es-query';
import { errors as EsErrors } from '@elastic/elasticsearch';
Expand Down Expand Up @@ -2714,7 +2715,11 @@ describe('SavedObjectsRepository', () => {
const allTypes = registry.getAllTypes().map((type) => type.name);
expect(getSearchDslNS.getSearchDsl).toHaveBeenCalledWith(mappings, registry, {
namespaces: [namespace],
type: allTypes.filter((type) => !registry.isNamespaceAgnostic(type)),
type: [
...allTypes.filter((type) => !registry.isNamespaceAgnostic(type)),
LEGACY_URL_ALIAS_TYPE,
],
kueryNode: expect.anything(),
});
});
});
Expand Down
16 changes: 14 additions & 2 deletions src/core/server/saved_objects/service/lib/repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import { omit, isObject } from 'lodash';
import type { estypes } from '@elastic/elasticsearch';
import * as esKuery from '@kbn/es-query';
import type { ElasticsearchClient } from '../../../elasticsearch/';
import { isSupportedEsServer, isNotFoundFromUnsupportedServer } from '../../../elasticsearch';
import type { Logger } from '../../../logging';
Expand Down Expand Up @@ -55,6 +56,7 @@ import {
SavedObjectsBulkResolveObject,
SavedObjectsBulkResolveResponse,
} from '../saved_objects_client';
import { LEGACY_URL_ALIAS_TYPE } from '../../object_types';
import {
SavedObject,
SavedObjectsBaseOptions,
Expand Down Expand Up @@ -780,7 +782,16 @@ export class SavedObjectsRepository {
}

const allTypes = Object.keys(getRootPropertiesObjects(this._mappings));
const typesToUpdate = allTypes.filter((type) => !this._registry.isNamespaceAgnostic(type));
const typesToUpdate = [
...allTypes.filter((type) => !this._registry.isNamespaceAgnostic(type)),
LEGACY_URL_ALIAS_TYPE,
];

// Construct kueryNode to filter legacy URL aliases (these space-agnostic objects do not use root-level "namespace/s" fields)
const { buildNode } = esKuery.nodeTypes.function;
const match1 = buildNode('is', `${LEGACY_URL_ALIAS_TYPE}.targetNamespace`, namespace);
const match2 = buildNode('not', buildNode('is', 'type', LEGACY_URL_ALIAS_TYPE));
const kueryNode = buildNode('or', [match1, match2]);

const { body, statusCode, headers } = await this.client.updateByQuery(
{
Expand All @@ -803,8 +814,9 @@ export class SavedObjectsRepository {
},
conflicts: 'proceed',
...getSearchDsl(this._mappings, this._registry, {
namespaces: namespace ? [namespace] : undefined,
namespaces: [namespace],
type: typesToUpdate,
kueryNode,
}),
},
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
/* eslint-disable */

// Angular service
i18n('plugin_1.id_1', { defaultMessage: 'Message 1' });

// @kbn/i18n
i18n.translate('plugin_1.id_2', {
defaultMessage: 'Message 2',
i18n.translate('plugin_1.id_1', {
defaultMessage: 'Message 1',
description: 'Message description',
});

Expand All @@ -15,10 +12,10 @@ class Component extends PureComponent {
return (
<div>
<FormattedMessage
id="plugin_1.id_3"
defaultMessage="Message 3"
id="plugin_1.id_2"
defaultMessage="Message 2"
/>
{intl.formatMessage({ id: 'plugin_1.id_4', defaultMessage: 'Message 4' })}
{intl.formatMessage({ id: 'plugin_1.id_3', defaultMessage: 'Message 3' })}
</div>
);
}
Expand Down

This file was deleted.

This file was deleted.

Loading

0 comments on commit 2781812

Please sign in to comment.