Skip to content

Commit be0df0e

Browse files
authored
Merge branch 'main' into retry-on-any-search-phase-execution-error
2 parents 02406f2 + e572bb8 commit be0df0e

176 files changed

Lines changed: 3983 additions & 2765 deletions

File tree

Some content is hidden

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

examples/workflows_extensions_example/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ The public configuration includes:
3232
- `description` - User-facing description
3333
- `icon` - icon image (preferably lazy loaded)
3434
- `documentation` - Documentation with summary, details, and examples
35+
- `actionsMenuCatalog` - (Optional) The catalog under which the step is displayed in the actions menu. Must be one of `StepMenuCatalog.elasticsearch`, `StepMenuCatalog.external`, `StepMenuCatalog.ai`, or `StepMenuCatalog.kibana`. Defaults to `StepMenuCatalog.kibana` if not provided.
3536

3637
## Usage Example
3738

Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
{
2+
"10.9.0": [
3+
{
4+
"title": "Saved search (KQL)",
5+
"description": "Fixture saved search used for modelVersion migration checks",
6+
"columns": ["@timestamp", "message"],
7+
"sort": [["@timestamp", "desc"]],
8+
"grid": {
9+
"columns": {
10+
"@timestamp": {
11+
"width": 190
12+
},
13+
"message": {
14+
"width": 420
15+
}
16+
}
17+
},
18+
"hideChart": false,
19+
"kibanaSavedObjectMeta": {
20+
"searchSourceJSON": "{\"query\":{\"language\":\"kuery\",\"query\":\"host.name : *\"},\"filter\":[]}"
21+
},
22+
"isTextBasedQuery": false,
23+
"usesAdHocDataView": false,
24+
"timeRestore": true,
25+
"timeRange": {
26+
"from": "now-15m",
27+
"to": "now"
28+
},
29+
"refreshInterval": {
30+
"pause": true,
31+
"value": 0
32+
},
33+
"viewMode": "documents",
34+
"hideAggregatedPreview": false,
35+
"hits": 0,
36+
"version": 1
37+
},
38+
{
39+
"title": "Saved search (ES|QL text-based)",
40+
"description": "",
41+
"columns": [],
42+
"sort": [],
43+
"grid": {},
44+
"hideChart": true,
45+
"kibanaSavedObjectMeta": {
46+
"searchSourceJSON": "{\"query\":{\"language\":\"esql\",\"query\":\"from logs-* | limit 10\"},\"filter\":[]}"
47+
},
48+
"isTextBasedQuery": true,
49+
"timeRestore": false
50+
}
51+
],
52+
"10.10.0": [
53+
{
54+
"title": "Saved search (KQL)",
55+
"description": "Fixture saved search used for modelVersion migration checks",
56+
"columns": ["@timestamp", "message"],
57+
"sort": [["@timestamp", "desc"]],
58+
"grid": {
59+
"columns": {
60+
"@timestamp": {
61+
"width": 190
62+
},
63+
"message": {
64+
"width": 420
65+
}
66+
}
67+
},
68+
"hideChart": false,
69+
"kibanaSavedObjectMeta": {
70+
"searchSourceJSON": "{\"query\":{\"language\":\"kuery\",\"query\":\"host.name : *\"},\"filter\":[]}"
71+
},
72+
"isTextBasedQuery": false,
73+
"usesAdHocDataView": false,
74+
"timeRestore": true,
75+
"timeRange": {
76+
"from": "now-15m",
77+
"to": "now"
78+
},
79+
"refreshInterval": {
80+
"pause": true,
81+
"value": 0
82+
},
83+
"viewMode": "documents",
84+
"hideAggregatedPreview": false,
85+
"hits": 0,
86+
"version": 1
87+
},
88+
{
89+
"title": "Saved search (ES|QL text-based)",
90+
"description": "",
91+
"columns": [],
92+
"sort": [],
93+
"grid": {},
94+
"hideChart": true,
95+
"kibanaSavedObjectMeta": {
96+
"searchSourceJSON": "{\"query\":{\"language\":\"esql\",\"query\":\"from logs-* | limit 10\"},\"filter\":[]}"
97+
},
98+
"isTextBasedQuery": true,
99+
"timeRestore": false
100+
}
101+
]
102+
}

src/core/server/integration_tests/ci_checks/saved_objects/check_registered_types.test.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
166166
"risk-engine-configuration": "9d54f733fb2bd08978c7059d71e77741574dc2616823745501742d34816a408c",
167167
"rules-settings": "436a36535b5d57ea1f7cbaaa37887ed5ddac8c3dea30c9fd98b3931ae87dfe1a",
168168
"sample-data-telemetry": "4c102e89bdcaee1ccc887d1709c7e176c05f25b4c5ac14c3d013b58fbfd806ac",
169-
"search": "431e34cbf3aadc050c4f5e23e2e13da977d1d37468f3651499d722c207723c4c",
169+
"search": "c85e16bcb3b1973b0592cade64b1440333fc9fc8802fe9d2c4c120cc6f153b81",
170170
"search-session": "95e62da1c06afde503c7d12efebc7df2102b9cb8bead1f50ca5c6ab8f4b67c26",
171171
"search-telemetry": "c152fc7e66d5ac7907e81c0926be9c219a15181e10b418b2fbb86bab2760627c",
172172
"search_playground": "97895cb5356dd7dad771b6d72b5c236c7c229c012545d56bf6e849984512c9b1",
@@ -1051,6 +1051,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
10511051
"search|global: ce649a79d99c5ff5eb68d544635428ef87946d84",
10521052
"search|mappings: 432d4dfdb5a33ce29d00ccdcfcda70d7c5f94b52",
10531053
"search|schemas: 8d6477e08dfdf20335752a69994646f9da90741f",
1054+
"search|10.10.0: 2267369c36edf6d7a2ebafe7028171610687672921e7d79b796acb287199897f",
10541055
"search|10.9.0: 557d8a40f3cd758fb4da9afba44e827a8c18b63ba140af871cf4a815f8e5e869",
10551056
"search|10.8.0: 76274f35cc139d5e208236bb92c859dd29e27ade181950a9f0bc3e95220c86dc",
10561057
"search|10.7.0: 03bcc899ac7be8e0a88520ae8fc091fc6ea37b231848dcbc0119b7425f36dd0e",
@@ -1399,7 +1400,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
13991400
"risk-engine-configuration": "10.4.0",
14001401
"rules-settings": "10.1.0",
14011402
"sample-data-telemetry": "10.0.0",
1402-
"search": "10.9.0",
1403+
"search": "10.10.0",
14031404
"search-session": "10.0.0",
14041405
"search-telemetry": "10.0.0",
14051406
"search_playground": "10.1.0",
@@ -1552,7 +1553,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
15521553
"risk-engine-configuration": "10.4.0",
15531554
"rules-settings": "10.1.0",
15541555
"sample-data-telemetry": "0.0.0",
1555-
"search": "10.9.0",
1556+
"search": "10.10.0",
15561557
"search-session": "8.6.0",
15571558
"search-telemetry": "7.12.0",
15581559
"search_playground": "10.1.0",

src/platform/packages/private/kbn-esql-editor/src/helpers.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -342,14 +342,6 @@ export const getEditorOverwrites = (theme: UseEuiTheme<{}>) => {
342342
white-space: normal !important;
343343
}
344344
345-
// Modifies the height of the signature popup to make it fit under the page header.
346-
// This is temprary until https://github.com/elastic/kibana/issues/245694 is resolved.
347-
// This solution is succeptible to errors if the editor height or the page header height changes.
348-
.parameter-hints-widget > .phwrapper {
349-
max-height: 90px !important;
350-
overflow: auto;
351-
}
352-
353345
.suggest-details .rendered-markdown h1 {
354346
display: block;
355347
margin-top: ${theme.euiTheme.size.m};

src/platform/packages/shared/kbn-discover-utils/src/__mocks__/metrics_context_service.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,7 @@ import { getMetricsContextService } from '../data_types';
1212

1313
export const createMetricsContextServiceMock = () => {
1414
const metricsExperienceClient: MetricsExperienceClient = {
15-
getDimensions: jest.fn().mockResolvedValue([]),
1615
getFields: jest.fn().mockResolvedValue([]),
17-
searchFields: jest.fn().mockResolvedValue([]),
1816
};
1917

2018
return getMetricsContextService({

src/platform/packages/shared/kbn-ebt-tools/src/performance_metric_events/schema.ts

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export interface PerformanceMetricEvent {
1818
*/
1919
eventName: string;
2020
/**
21-
* Searchable but not aggregateable metadata relevant to the tracked action.
21+
* Searchable but not aggregatable metadata relevant to the tracked action.
2222
*/
2323
meta?: Record<string, unknown>;
2424

@@ -29,92 +29,92 @@ export interface PerformanceMetricEvent {
2929
duration: number;
3030

3131
/**
32-
* @group Free fields for custom metrics (searchable and aggregateable)
32+
* @group Free fields for custom metrics (searchable and aggregatable)
3333
* Description label for the metric 1
3434
*/
3535
key1?: string;
3636
/**
37-
* @group Free fields for custom metrics (searchable and aggregateable)
37+
* @group Free fields for custom metrics (searchable and aggregatable)
3838
* Value for the metric 1
3939
*/
4040
value1?: number;
4141
/**
42-
* @group Free fields for custom metrics (searchable and aggregateable)
42+
* @group Free fields for custom metrics (searchable and aggregatable)
4343
* Description label for the metric 2
4444
*/
4545
key2?: string;
4646
/**
47-
* @group Free fields for custom metrics (searchable and aggregateable)
47+
* @group Free fields for custom metrics (searchable and aggregatable)
4848
* Value for the metric 2
4949
*/
5050
value2?: number;
5151
/**
52-
* @group Free fields for custom metrics (searchable and aggregateable)
52+
* @group Free fields for custom metrics (searchable and aggregatable)
5353
* Description label for the metric 3
5454
*/
5555
key3?: string;
5656
/**
57-
* @group Free fields for custom metrics (searchable and aggregateable)
57+
* @group Free fields for custom metrics (searchable and aggregatable)
5858
* Value for the metric 3
5959
*/
6060
value3?: number;
6161
/**
62-
* @group Free fields for custom metrics (searchable and aggregateable)
62+
* @group Free fields for custom metrics (searchable and aggregatable)
6363
* Description label for the metric 4
6464
*/
6565
key4?: string;
6666
/**
67-
* @group Free fields for custom metrics (searchable and aggregateable)
67+
* @group Free fields for custom metrics (searchable and aggregatable)
6868
* Value for the metric 4
6969
*/
7070
value4?: number;
7171
/**
72-
* @group Free fields for custom metrics (searchable and aggregateable)
72+
* @group Free fields for custom metrics (searchable and aggregatable)
7373
* Description label for the metric 5
7474
*/
7575
key5?: string;
7676
/**
77-
* @group Free fields for custom metrics (searchable and aggregateable)
77+
* @group Free fields for custom metrics (searchable and aggregatable)
7878
* Value for the metric 5
7979
*/
8080
value5?: number;
8181
/**
82-
* @group Free fields for custom metrics (searchable and aggregateable)
82+
* @group Free fields for custom metrics (searchable and aggregatable)
8383
* Description label for the metric 6
8484
*/
8585
key6?: string;
8686
/**
87-
* @group Free fields for custom metrics (searchable and aggregateable)
87+
* @group Free fields for custom metrics (searchable and aggregatable)
8888
* Value for the metric 6
8989
*/
9090
value6?: number;
9191
/**
92-
* @group Free fields for custom metrics (searchable and aggregateable)
92+
* @group Free fields for custom metrics (searchable and aggregatable)
9393
* Description label for the metric 7
9494
*/
9595
key7?: string;
9696
/**
97-
* @group Free fields for custom metrics (searchable and aggregateable)
97+
* @group Free fields for custom metrics (searchable and aggregatable)
9898
* Value for the metric 7
9999
*/
100100
value7?: number;
101101
/**
102-
* @group Free fields for custom metrics (searchable and aggregateable)
102+
* @group Free fields for custom metrics (searchable and aggregatable)
103103
* Description label for the metric 8
104104
*/
105105
key8?: string;
106106
/**
107-
* @group Free fields for custom metrics (searchable and aggregateable)
107+
* @group Free fields for custom metrics (searchable and aggregatable)
108108
* Value for the metric 8
109109
*/
110110
value8?: number;
111111
/**
112-
* @group Free fields for custom metrics (searchable and aggregateable)
112+
* @group Free fields for custom metrics (searchable and aggregatable)
113113
* Description label for the metric 9
114114
*/
115115
key9?: string;
116116
/**
117-
* @group Free fields for custom metrics (searchable and aggregateable)
117+
* @group Free fields for custom metrics (searchable and aggregatable)
118118
* Value for the metric 9
119119
*/
120120
value9?: number;

src/platform/packages/shared/kbn-scout/src/playwright/ui_components/monaco_editor.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,4 +107,10 @@ export class KibanaCodeEditorWrapper {
107107
const selector = `[data-test-subj="${testSubjId}"] .cdr.squiggly-error`;
108108
return this.page.locator(selector);
109109
}
110+
111+
public getCodeEditorSuggestWidget() {
112+
return this.page.locator(
113+
'[data-test-subj="kbnCodeEditorEditorOverflowWidgetsContainer"] .suggest-widget'
114+
);
115+
}
110116
}

src/platform/packages/shared/kbn-unified-metrics-grid/moon.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,18 @@ dependsOn:
3535
- '@kbn/ui-actions-plugin'
3636
- '@kbn/react-hooks'
3737
- '@kbn/data-grid-in-table-search'
38-
- '@kbn/es-query'
3938
- '@kbn/discover-utils'
4039
- '@kbn/fields-metadata-plugin'
4140
- '@kbn/shared-ux-button-toolbar'
4241
- '@kbn/apm-types'
4342
- '@kbn/esql-utils'
4443
- '@kbn/field-utils'
45-
- '@kbn/react-query'
4644
- '@kbn/restorable-state'
4745
- '@kbn/esql-types'
4846
- '@kbn/presentation-panel-plugin'
47+
- '@kbn/expressions-plugin'
48+
- '@kbn/ebt-tools'
49+
- '@kbn/es-query'
4950
tags:
5051
- shared-browser
5152
- package

src/platform/packages/shared/kbn-unified-metrics-grid/src/common/constants.ts

Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* License v3.0 only", or the "Server Side Public License, v 1".
88
*/
99

10-
export const FIELD_VALUE_SEPARATOR = String.fromCharCode(0x1d);
10+
import { ES_FIELD_TYPES } from '@kbn/field-types';
1111

1212
// Full screen classes
1313
export const METRICS_GRID_CLASS = 'metricsGrid';
@@ -17,14 +17,40 @@ export const METRICS_GRID_RESTRICT_BODY_CLASS = `${METRICS_GRID_CLASS}--restrict
1717

1818
// data-test-subj
1919
export const METRICS_BREAKDOWN_SELECTOR_DATA_TEST_SUBJ = 'metricsExperienceBreakdownSelector';
20-
export const METRICS_VALUES_SELECTOR_DATA_TEST_SUBJ = 'metricsExperienceValuesSelector';
2120

2221
// Selection limits
23-
export const MAX_VALUES_SELECTIONS = 10;
2422
export const MAX_DIMENSIONS_SELECTIONS = 1;
2523
export const PAGE_SIZE = 20;
2624

2725
// Lens extra actions
2826
export const ACTION_COPY_TO_DASHBOARD = 'ACTION_METRICS_EXPERIENCE_COPY_TO_DASHBOARD';
2927
export const ACTION_VIEW_DETAILS = 'ACTION_METRICS_EXPERIENCE_VIEW_DETAILS';
3028
export const ACTION_EXPLORE_IN_DISCOVER_TAB = 'ACTION_METRICS_EXPERIENCE_EXPLORE_IN_DISCOVER_TAB';
29+
/** Set of numeric field types used for metrics */
30+
export const NUMERIC_TYPES = [
31+
ES_FIELD_TYPES.LONG,
32+
ES_FIELD_TYPES.INTEGER,
33+
ES_FIELD_TYPES.SHORT,
34+
ES_FIELD_TYPES.BYTE,
35+
ES_FIELD_TYPES.DOUBLE,
36+
ES_FIELD_TYPES.FLOAT,
37+
ES_FIELD_TYPES.HALF_FLOAT,
38+
ES_FIELD_TYPES.SCALED_FLOAT,
39+
ES_FIELD_TYPES.UNSIGNED_LONG,
40+
ES_FIELD_TYPES.HISTOGRAM,
41+
ES_FIELD_TYPES.EXPONENTIAL_HISTOGRAM,
42+
ES_FIELD_TYPES.TDIGEST,
43+
];
44+
45+
// For the dimensions, the field MUST have `time_series_dimension` attribute set
46+
// in the mappings and it can only be the following types:
47+
export const DIMENSION_TYPES = [
48+
ES_FIELD_TYPES.KEYWORD,
49+
ES_FIELD_TYPES.IP,
50+
ES_FIELD_TYPES.BOOLEAN,
51+
ES_FIELD_TYPES.LONG,
52+
ES_FIELD_TYPES.INTEGER,
53+
ES_FIELD_TYPES.SHORT,
54+
ES_FIELD_TYPES.BYTE,
55+
ES_FIELD_TYPES.UNSIGNED_LONG,
56+
];

src/platform/packages/shared/kbn-unified-metrics-grid/src/common/utils/esql/create_aggregation.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import {
1515
type ESQLAstQueryExpression,
1616
} from '@kbn/esql-ast';
1717
import { replaceParameters } from '@kbn/esql-composer';
18-
import type { MetricField } from '@kbn/metrics-experience-plugin/common/types';
18+
import type { MetricField } from '../../../types';
1919

2020
type Params = Record<string, string | number | boolean | null>;
2121

0 commit comments

Comments
 (0)