Skip to content

Commit b0eb798

Browse files
authored
Default duration to minutes, only show alerting on metrics explorer (#61058)
1 parent 427848c commit b0eb798

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

x-pack/plugins/infra/public/components/alerting/metrics/expression.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ export const Expressions: React.FC<Props> = props => {
7070
const { setAlertParams, alertParams, errors, alertsContext } = props;
7171
const { source, createDerivedIndexPattern } = useSource({ sourceId: 'default' });
7272
const [timeSize, setTimeSize] = useState<number | undefined>(1);
73-
const [timeUnit, setTimeUnit] = useState<TimeUnit>('s');
73+
const [timeUnit, setTimeUnit] = useState<TimeUnit>('m');
7474

7575
const derivedIndexPattern = useMemo(() => createDerivedIndexPattern('metrics'), [
7676
createDerivedIndexPattern,
@@ -93,7 +93,7 @@ export const Expressions: React.FC<Props> = props => {
9393
comparator: '>',
9494
threshold: [],
9595
timeSize: 1,
96-
timeUnit: 's',
96+
timeUnit: 'm',
9797
indexPattern: source?.configuration.metricAlias,
9898
}),
9999
[source]

x-pack/plugins/infra/public/pages/infrastructure/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export const InfrastructurePage = ({ match }: RouteComponentProps) => {
9191
/>
9292
</EuiFlexItem>
9393
<EuiFlexItem grow={false}>
94-
<AlertDropdown />
94+
<Route path={'/explorer'} component={AlertDropdown} />
9595
</EuiFlexItem>
9696
</EuiFlexGroup>
9797
</AppNavigation>

0 commit comments

Comments
 (0)