Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TSVB][Lens] Navigate to Lens with your current configuration #114794

Merged
merged 137 commits into from
Feb 14, 2022
Merged
Show file tree
Hide file tree
Changes from 100 commits
Commits
Show all changes
137 commits
Select commit Hold shift + click to select a range
76628e0
[Lens][TSVB] Convert to Lens
stratoula Oct 12, 2021
74f262a
Add logic for multiple series
stratoula Oct 13, 2021
065a9b1
Basic formula
stratoula Oct 13, 2021
6da7fac
Fix circular dependencies
stratoula Oct 13, 2021
b62ef23
Minor cleanup
stratoula Oct 13, 2021
502036f
Fix types
stratoula Oct 13, 2021
f132aad
fix jest tests
stratoula Oct 13, 2021
6e17315
Merge branch 'master' into convert-to-lens
kibanamachine Oct 13, 2021
8dd3b87
Fix test
stratoula Oct 13, 2021
e70ab64
Change the schema, add more styling options, fix bugs
stratoula Oct 14, 2021
089163d
Supports time shift and custom date interval
stratoula Oct 15, 2021
ff1cf81
Merge branch 'master' into convert-to-lens
kibanamachine Oct 15, 2021
5976aee
Merge branch 'master' into convert-to-lens
kibanamachine Oct 18, 2021
313871b
Merge branch 'master' into convert-to-lens
kibanamachine Oct 18, 2021
1a0959d
Merge branch 'master' into convert-to-lens
kibanamachine Oct 20, 2021
5ecaa0f
Merge with master and resolve conflicts
stratoula Oct 25, 2021
ea05e70
Fix types
stratoula Oct 25, 2021
40b8b36
Merge branch 'master' into convert-to-lens
kibanamachine Oct 25, 2021
99a4a70
Merge branch 'master' into convert-to-lens
kibanamachine Oct 26, 2021
5d67077
Merge branch 'master' into convert-to-lens
kibanamachine Oct 29, 2021
3e9b1c5
Merge branch 'main' into convert-to-lens
kibanamachine Nov 1, 2021
f7ca582
Merge branch 'main' into convert-to-lens
kibanamachine Nov 2, 2021
580ec72
Merge with main and resolve conflicts
stratoula Dec 6, 2021
fd38926
Fix some types
stratoula Dec 6, 2021
c784cbe
Move edit in lens button to top nav menu
stratoula Dec 6, 2021
5a0d721
Cleanup
stratoula Dec 6, 2021
b35a5b5
Further cleanup
stratoula Dec 6, 2021
0ce5f89
Add try it badge in menu, controlled by localStorage
stratoula Dec 7, 2021
d44bbea
Merge branch 'main' into convert-to-lens
kibanamachine Dec 7, 2021
0f1b990
Add go back to app button
stratoula Dec 7, 2021
ef6d4b5
Discard changes modal and go back to TSVB
stratoula Dec 8, 2021
da1e2c8
Update by value and by reference visualizations, delete existing by ref
stratoula Dec 8, 2021
73fcb51
Fix bug
stratoula Dec 8, 2021
528f05c
Apply some changes
stratoula Dec 8, 2021
9d86330
Merge branch 'main' into convert-to-lens
kibanamachine Dec 9, 2021
4272ef1
get title and description only if has context
stratoula Dec 13, 2021
956d942
Merge branch 'main' into convert-to-lens
kibanamachine Dec 13, 2021
31162dc
Pass originating app, title and description from the savedVis
stratoula Dec 13, 2021
a5e8a23
By ref TSVB to by ref Lens
stratoula Dec 13, 2021
62ee1a0
Merge branch 'main' into convert-to-lens
kibanamachine Dec 15, 2021
8794034
Match TSVB cardinality with Lens unique_count function
stratoula Dec 15, 2021
d4f7ccc
Support moving average
stratoula Dec 15, 2021
2716076
Fix test
stratoula Dec 16, 2021
9f6e116
Support derivative
stratoula Dec 16, 2021
9b3da9c
Support cumulative_sum
stratoula Dec 16, 2021
11932e5
Add overall functions
stratoula Dec 16, 2021
79df1fc
Merge branch 'main' into convert-to-lens
kibanamachine Dec 20, 2021
7ed8901
Support filter ratio
stratoula Dec 20, 2021
84ece5f
Refactor code for easier testing
stratoula Dec 20, 2021
0773170
Fix bug with auto interval
stratoula Dec 20, 2021
60f50d7
Fetch types from visualizations plugin
stratoula Dec 20, 2021
d1e3fb2
Pipeline aggs compatible with percentile
stratoula Dec 20, 2021
ad4c2fd
Add some bugs
stratoula Dec 20, 2021
7c74b98
Support nesred aggs
stratoula Dec 20, 2021
a581dd5
Merge branch 'main' into convert-to-lens
kibanamachine Dec 22, 2021
ba02a9f
Merge branch 'main' into convert-to-lens
kibanamachine Dec 23, 2021
6433b30
Mini refactor and support all aggregations to Math
stratoula Dec 23, 2021
e13b1c2
Transfer terms sorting options
stratoula Dec 24, 2021
7311e67
Transfer axis position
stratoula Dec 24, 2021
99d9211
Merge branch 'main' into convert-to-lens
kibanamachine Jan 4, 2022
e2024b7
Merge branch 'main' into convert-to-lens
kibanamachine Jan 10, 2022
51de080
Merge branch 'main' into convert-to-lens
kibanamachine Jan 12, 2022
03c4383
Merge with main and resolve conflicts
stratoula Jan 13, 2022
ae62c6c
Fix translations keys
stratoula Jan 13, 2022
3aa983c
Merge with main, resolve conflicts, use isLensEqual instead
stratoula Jan 14, 2022
26e842b
Revert
stratoula Jan 14, 2022
20b91ce
Fix redirectToOrigin buttion when the there is no embeddableId but co…
stratoula Jan 17, 2022
429ed12
Improve context identification
stratoula Jan 17, 2022
7040f38
Support yExtents
stratoula Jan 17, 2022
b039c0a
Merge branch 'main' into convert-to-lens
kibanamachine Jan 17, 2022
465f7db
Merge branch 'main' into convert-to-lens
stratoula Jan 18, 2022
331b965
Fix bug in formula caused by changes in the main branch
stratoula Jan 18, 2022
a3e57cb
Support formatters
stratoula Jan 18, 2022
467d4e0
Support custom label
stratoula Jan 18, 2022
8a1065e
Cleaning up
stratoula Jan 18, 2022
ede6341
Fix terms bugs
stratoula Jan 19, 2022
a6ce30d
Support filter breakdown by
stratoula Jan 19, 2022
185df2e
Merge branch 'main' into convert-to-lens
kibanamachine Jan 20, 2022
d870fb6
Fixes math bug and escapes filter ratio query
stratoula Jan 20, 2022
4202ff5
Merge branch 'main' into convert-to-lens
kibanamachine Jan 24, 2022
68c6274
Add some unit tests
stratoula Jan 24, 2022
d45e5ba
Testing triggerOptions payload
stratoula Jan 24, 2022
a7fc4fe
Fix console warning
stratoula Jan 25, 2022
943df02
Add more unit tests on TSVB function helpers
stratoula Jan 25, 2022
2d7cafc
Adds a unit test on the vis top nav menu testing the new menu item
stratoula Jan 25, 2022
3f50a21
Add unit tests
stratoula Jan 25, 2022
5126fc1
Merge branch 'main' into convert-to-lens
stratoula Jan 25, 2022
29c9a9f
Fix unsupported palette bug, clean up, add a unit test case
stratoula Jan 25, 2022
3c015da
Merge branch 'main' into convert-to-lens
kibanamachine Jan 26, 2022
3b3a25c
Add final unit tests
stratoula Jan 26, 2022
274b139
Support timeScale in derivative
stratoula Jan 26, 2022
5124288
Add functional tests
stratoula Jan 26, 2022
91bcecc
Cleanup
stratoula Jan 27, 2022
c210669
Fix jest test
stratoula Jan 27, 2022
f08fa3c
Merge branch 'main' into convert-to-lens
kibanamachine Jan 27, 2022
b655f4e
Fix some bugs
stratoula Jan 27, 2022
c49bc52
Fix some math agg bugs
stratoula Jan 27, 2022
3ff4105
Merge branch 'main' into convert-to-lens
stratoula Jan 27, 2022
1dd2d87
Fix more bugs
stratoula Jan 28, 2022
06f1ac1
Merge branch 'main' into convert-to-lens
kibanamachine Jan 31, 2022
27af228
Merge branch 'main' into convert-to-lens
kibanamachine Feb 2, 2022
25f6ced
Fixes jest test
stratoula Feb 2, 2022
4d65168
Fix the problem with the dashboard state
stratoula Feb 2, 2022
cde3576
Hides the badge and link instead of disabling it
stratoula Feb 2, 2022
208d1f5
Changes the text
stratoula Feb 2, 2022
0454f91
Merge with master and resolve conflicts
stratoula Feb 2, 2022
a8d8fa5
Merge branch 'main' into convert-to-lens
kibanamachine Feb 2, 2022
2f8a4e6
Merge branch 'main' into convert-to-lens
kibanamachine Feb 4, 2022
dc703f0
Merge branch 'main' into convert-to-lens
kibanamachine Feb 7, 2022
0e3644f
Adds menu item vertical separator
stratoula Feb 7, 2022
5afd257
Enhance the appLeace confirm modal to change the confirm button text …
stratoula Feb 7, 2022
879fd21
Fixes CI
stratoula Feb 7, 2022
b71296e
Adress code review comments
stratoula Feb 8, 2022
3f2d615
Address some of the comments
stratoula Feb 8, 2022
f2268b5
Fix more bugs
stratoula Feb 8, 2022
5f10a22
Fix more bugs
stratoula Feb 8, 2022
c01d3d7
Zero decimals for formatting
stratoula Feb 8, 2022
df9eaa0
fix tests
stratoula Feb 8, 2022
cce1e32
Merge branch 'main' into convert-to-lens
stratoula Feb 9, 2022
0f305b3
Navigate from dashboard to TSVB to Lens hides the appLeave modal
stratoula Feb 9, 2022
878c83f
Adds support for terms on a date field
stratoula Feb 9, 2022
2423d2b
Support filter by
stratoula Feb 9, 2022
7701b58
Move the trigger to the visualizations plugin
stratoula Feb 9, 2022
93f7449
Minor
stratoula Feb 9, 2022
fca4ebc
Fix CI
stratoula Feb 9, 2022
5d85886
Support percentage charts
stratoula Feb 10, 2022
70237f9
Merge with main and resolve conflicts
stratoula Feb 11, 2022
59d3183
Improve the vertical separator
stratoula Feb 11, 2022
c5f3124
Fixes on the appLeave logic
stratoula Feb 11, 2022
de999b5
Remove unecessary import
stratoula Feb 11, 2022
be11016
Add badge to the nav item level
stratoula Feb 11, 2022
8065703
Fix jest test
stratoula Feb 11, 2022
82deb26
Fi filter ratio and filter by bug
stratoula Feb 11, 2022
c47ffae
Merge branch 'main' into convert-to-lens
kibanamachine Feb 14, 2022
068b077
Replace all occurences of a variable
stratoula Feb 14, 2022
6047c9d
Nest badge into the button level
stratoula Feb 14, 2022
bd9340d
Design improvements
stratoula Feb 14, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,6 @@ export const buildDashboardContainer = async ({
gridData: originalPanelState.gridData,
type: incomingEmbeddable.type,
explicitInput: {
...originalPanelState.explicitInput,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ Not needed, allows a TSVB library panel to be replaced by a Lens by value panel

...incomingEmbeddable.input,
id: incomingEmbeddable.embeddableId,
},
Expand Down
4 changes: 4 additions & 0 deletions src/plugins/navigation/public/top_nav_menu/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,7 @@
.kbnTopNavMenu__badgeGroup {
margin-right: $euiSizeM;
}

.kbnTopNavMenu__betaBadgeGroup {
align-self: center;
}
23 changes: 19 additions & 4 deletions src/plugins/navigation/public/top_nav_menu/top_nav_menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,14 @@
*/

import React, { ReactElement } from 'react';
import { EuiBadge, EuiBadgeGroup, EuiBadgeProps, EuiHeaderLinks } from '@elastic/eui';
import {
EuiBadge,
EuiBadgeGroup,
EuiBadgeProps,
EuiHeaderLinks,
EuiBetaBadge,
EuiBetaBadgeProps,
} from '@elastic/eui';
import classNames from 'classnames';

import { MountPoint } from '../../../../core/public';
Expand All @@ -24,6 +31,7 @@ export type TopNavMenuProps = StatefulSearchBarProps &
Omit<SearchBarProps, 'kibana' | 'intl' | 'timeHistory'> & {
config?: TopNavMenuData[];
badges?: Array<EuiBadgeProps & { badgeText: string }>;
isBetaBadge?: boolean;
showSearchBar?: boolean;
showQueryBar?: boolean;
showQueryInput?: boolean;
Expand Down Expand Up @@ -62,7 +70,7 @@ export type TopNavMenuProps = StatefulSearchBarProps &
**/

export function TopNavMenu(props: TopNavMenuProps): ReactElement | null {
const { config, badges, showSearchBar, ...searchBarProps } = props;
const { config, badges, isBetaBadge, showSearchBar, ...searchBarProps } = props;

if ((!config || config.length === 0) && (!showSearchBar || !props.data)) {
return null;
Expand All @@ -71,10 +79,17 @@ export function TopNavMenu(props: TopNavMenuProps): ReactElement | null {
function renderBadges(): ReactElement | null {
if (!badges || badges.length === 0) return null;
return (
<EuiBadgeGroup className={'kbnTopNavMenu__badgeGroup'}>
<EuiBadgeGroup
className={
Boolean(isBetaBadge) ? 'kbnTopNavMenu__betaBadgeGroup' : 'kbnTopNavMenu__badgeGroup'
}
>
{badges.map((badge: EuiBadgeProps & { badgeText: string }, i: number) => {
const { badgeText, ...badgeProps } = badge;
return (
const badgeColor = badge.color as EuiBetaBadgeProps['color'];
return Boolean(isBetaBadge) ? (
<EuiBetaBadge label={badgeText} color={badgeColor ?? 'subdued'} size="s" />
) : (
<EuiBadge key={`nav-menu-badge-${i}`} {...badgeProps}>
{badgeText}
</EuiBadge>
Expand Down
3 changes: 3 additions & 0 deletions src/plugins/ui_actions/public/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ export type { Trigger, RowClickContext } from './triggers';
export {
VISUALIZE_FIELD_TRIGGER,
visualizeFieldTrigger,
VISUALIZE_EDITOR_TRIGGER,
visualizeEditorTrigger,
VISUALIZE_GEO_FIELD_TRIGGER,
visualizeGeoFieldTrigger,
ROW_CLICK_TRIGGER,
Expand All @@ -37,5 +39,6 @@ export {
ACTION_VISUALIZE_FIELD,
ACTION_VISUALIZE_GEO_FIELD,
ACTION_VISUALIZE_LENS_FIELD,
ACTION_CONVERT_TO_LENS,
} from './types';
export type { ActionExecutionContext, ActionExecutionMeta, ActionMenuItemProps } from './actions';
8 changes: 7 additions & 1 deletion src/plugins/ui_actions/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@
import { CoreStart, CoreSetup, Plugin, PluginInitializerContext } from 'src/core/public';
import { PublicMethodsOf } from '@kbn/utility-types';
import { UiActionsService } from './service';
import { rowClickTrigger, visualizeFieldTrigger, visualizeGeoFieldTrigger } from './triggers';
import {
rowClickTrigger,
visualizeFieldTrigger,
visualizeGeoFieldTrigger,
visualizeEditorTrigger,
} from './triggers';
import { setTheme } from './services';

export type UiActionsSetup = Pick<
Expand All @@ -33,6 +38,7 @@ export class UiActionsPlugin implements Plugin<UiActionsSetup, UiActionsStart> {
setTheme(core.theme);
this.service.registerTrigger(rowClickTrigger);
this.service.registerTrigger(visualizeFieldTrigger);
this.service.registerTrigger(visualizeEditorTrigger);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a reason this is not registered from visualize editor plugin ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ppisljar I added this here to be consistent with the this.service.registerTrigger(visualizeFieldTrigger); that navigates from Discover to Lens

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I moved it to the visualizations plugin :)

this.service.registerTrigger(visualizeGeoFieldTrigger);
return this.service;
}
Expand Down
1 change: 1 addition & 0 deletions src/plugins/ui_actions/public/triggers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ export * from './trigger_contract';
export * from './trigger_internal';
export * from './row_click_trigger';
export * from './visualize_field_trigger';
export * from './visualize_editor_trigger';
export * from './visualize_geo_field_trigger';
export * from './default_trigger';
16 changes: 16 additions & 0 deletions src/plugins/ui_actions/public/triggers/visualize_editor_trigger.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/

import { Trigger } from '.';

export const VISUALIZE_EDITOR_TRIGGER = 'VISUALIZE_EDITOR_TRIGGER';
export const visualizeEditorTrigger: Trigger = {
id: VISUALIZE_EDITOR_TRIGGER,
title: 'Convert legacy visualizations to Lens',
description: 'Triggered when user navigates from a legacy visualization to Lens.',
};
2 changes: 1 addition & 1 deletion src/plugins/ui_actions/public/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/

import { ActionInternal } from './actions/action_internal';
import { TriggerInternal } from './triggers/trigger_internal';

Expand All @@ -22,3 +21,4 @@ export interface VisualizeFieldContext {
export const ACTION_VISUALIZE_FIELD = 'ACTION_VISUALIZE_FIELD';
export const ACTION_VISUALIZE_GEO_FIELD = 'ACTION_VISUALIZE_GEO_FIELD';
export const ACTION_VISUALIZE_LENS_FIELD = 'ACTION_VISUALIZE_LENS_FIELD';
export const ACTION_CONVERT_TO_LENS = 'ACTION_CONVERT_TO_LENS';
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export interface Series {
chart_type: string;
color: string;
color_rules?: ColorRules[];
fill?: number;
fill?: string;
filter?: Query;
formatter: string;
hidden?: boolean;
Expand Down
7 changes: 7 additions & 0 deletions src/plugins/vis_types/timeseries/public/metrics_type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import {
} from '../../../visualizations/public';
import { getDataStart } from './services';
import type { TimeseriesVisDefaultParams, TimeseriesVisParams } from './types';
import { triggerTSVBtoLensConfiguration } from './trigger_action';
import type { IndexPatternValue, Panel } from '../common/types';
import { RequestAdapter } from '../../../inspector/public';

Expand Down Expand Up @@ -154,6 +155,12 @@ export const metricsVisDefinition: VisTypeDefinition<
}
return [];
},
navigateToLens: async (params?: VisParams) => {
const triggerConfiguration = params
? await triggerTSVBtoLensConfiguration(params as Panel)
: null;
return triggerConfiguration;
},
inspectorAdapters: () => ({
requests: new RequestAdapter(),
}),
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/
import type { DataView } from '../../../../data/common';
import { getDataSourceInfo } from './get_datasource_info';
const dataViewsMap: Record<string, DataView> = {
test1: { id: 'test1', title: 'test1', timeFieldName: 'timeField1' } as DataView,
test2: {
id: 'test2',
title: 'test2',
timeFieldName: 'timeField2',
} as DataView,
test3: { id: 'test3', title: 'test3', timeFieldName: 'timeField3' } as DataView,
};

const getDataview = (id: string): DataView | undefined => dataViewsMap[id];
jest.mock('../services', () => {
return {
getDataStart: jest.fn(() => {
return {
dataViews: {
getDefault: jest.fn(() => {
return { id: '12345', title: 'default', timeFieldName: '@timestamp' };
}),
get: getDataview,
},
};
}),
};
});

describe('getDataSourceInfo', () => {
test('should return the default dataview if model_indexpattern is string', async () => {
const { indexPatternId, timeField } = await getDataSourceInfo(
'test',
undefined,
false,
undefined
);
expect(indexPatternId).toBe('12345');
expect(timeField).toBe('@timestamp');
});

test('should return the correct dataview if model_indexpattern is object', async () => {
const { indexPatternId, timeField } = await getDataSourceInfo(
{ id: 'dataview-1-id' },
'timeField-1',
false,
undefined
);
expect(indexPatternId).toBe('dataview-1-id');
expect(timeField).toBe('timeField-1');
});

test('should fetch the correct data if overwritten dataview is provided', async () => {
const { indexPatternId, timeField } = await getDataSourceInfo(
{ id: 'dataview-1-id' },
'timeField-1',
true,
{ id: 'test2' }
);
expect(indexPatternId).toBe('test2');
expect(timeField).toBe('timeField2');
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/
import { fetchIndexPattern, isStringTypeIndexPattern } from '../../common/index_patterns_utils';
import type { IndexPatternValue } from '../../common/types';
import { getDataStart } from '../services';

export const getDataSourceInfo = async (
modelIndexPattern: IndexPatternValue,
modelTimeField: string | undefined,
isOverwritten: boolean,
overwrittenIndexPattern: IndexPatternValue | undefined
) => {
const { dataViews } = getDataStart();
let indexPatternId =
modelIndexPattern && !isStringTypeIndexPattern(modelIndexPattern) ? modelIndexPattern.id : '';

let timeField = modelTimeField;
// handle override index pattern
if (isOverwritten) {
const { indexPattern } = await fetchIndexPattern(overwrittenIndexPattern, dataViews);
if (indexPattern) {
indexPatternId = indexPattern.id ?? '';
timeField = indexPattern.timeFieldName;
}
}
if (!timeField) {
if (indexPatternId) {
const indexPattern = await dataViews.get(indexPatternId);
timeField = indexPattern.timeFieldName;
} else {
const defaultIndex = await dataViews.getDefault();
timeField = defaultIndex?.timeFieldName;
}
}
if (!indexPatternId) {
const defaultIndex = await dataViews.getDefault();
indexPatternId = defaultIndex?.id ?? '';
}
stratoula marked this conversation as resolved.
Show resolved Hide resolved

return {
indexPatternId,
timeField,
};
};
Loading