Skip to content

Commit

Permalink
feat(slo): add partition by field in APM indicators (#165106)
Browse files Browse the repository at this point in the history
  • Loading branch information
kdelemme authored Aug 30, 2023
1 parent 3128c46 commit e56c0f6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ import { useFormContext } from 'react-hook-form';
import { CreateSLOForm } from '../../types';
import { FieldSelector } from '../apm_common/field_selector';
import { DataPreviewChart } from '../common/data_preview_chart';
import { GroupByFieldSelector } from '../common/group_by_field_selector';
import { QueryBuilder } from '../common/query_builder';

export function ApmAvailabilityIndicatorTypeForm() {
const { watch } = useFormContext<CreateSLOForm>();
const index = watch('indicator.params.index');

return (
<EuiFlexGroup direction="column" gutterSize="l">
Expand Down Expand Up @@ -119,6 +121,8 @@ export function ApmAvailabilityIndicatorTypeForm() {
</EuiFlexItem>
</EuiFlexGroup>

<GroupByFieldSelector index={index} />

<DataPreviewChart />
</EuiFlexGroup>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ import { Controller, useFormContext } from 'react-hook-form';
import { CreateSLOForm } from '../../types';
import { FieldSelector } from '../apm_common/field_selector';
import { DataPreviewChart } from '../common/data_preview_chart';
import { GroupByFieldSelector } from '../common/group_by_field_selector';
import { QueryBuilder } from '../common/query_builder';

export function ApmLatencyIndicatorTypeForm() {
const { control, watch, getFieldState } = useFormContext<CreateSLOForm>();
const index = watch('indicator.params.index');

return (
<EuiFlexGroup direction="column" gutterSize="l">
Expand Down Expand Up @@ -162,6 +164,8 @@ export function ApmLatencyIndicatorTypeForm() {
</EuiFlexItem>
</EuiFlexGroup>

<GroupByFieldSelector index={index} />

<DataPreviewChart />
</EuiFlexGroup>
);
Expand Down

0 comments on commit e56c0f6

Please sign in to comment.