Skip to content

Commit

Permalink
[Bug] Trace Analytics bug fix for local cluster being rendered (opens…
Browse files Browse the repository at this point in the history
…earch-project#2006)

* traces and app analytics fix

Signed-off-by: sumukhswamy <[email protected]>

* reverted json file

Signed-off-by: sumukhswamy <[email protected]>

* updated snapshots

Signed-off-by: sumukhswamy <[email protected]>

---------

Signed-off-by: sumukhswamy <[email protected]>
  • Loading branch information
sumukhswamy committed Jul 29, 2024
1 parent e31ba87 commit c27b569
Show file tree
Hide file tree
Showing 10 changed files with 145 additions and 94 deletions.
43 changes: 21 additions & 22 deletions public/components/application_analytics/components/application.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,24 +18,14 @@ import {
EuiText,
EuiTitle,
} from '@elastic/eui';
import { VisualizationType } from 'common/types/custom_panels';
import DSLService from 'public/services/requests/dsl';
import PPLService from 'public/services/requests/ppl';
import SavedObjects from 'public/services/saved_objects/event_analytics/saved_objects';
import TimestampUtils from 'public/services/timestamp/timestamp';
import React, { ReactChild, useEffect, useState } from 'react';
import { useHistory } from 'react-router-dom';
import { useDispatch } from 'react-redux';
import { last } from 'lodash';
import { VisualizationType } from 'common/types/custom_panels';
import { TracesContent } from '../../../components/trace_analytics/components/traces/traces_content';
import { ServicesContent } from '../../trace_analytics/components/services/services_content';
import {
filtersToDsl,
PanelTitle,
} from '../../../../public/components/trace_analytics/components/common/helper_functions';
import { SpanDetailTable } from '../../../../public/components/trace_analytics/components/traces/span_detail_table';
import { Explorer } from '../../event_analytics/explorer/explorer';
import { Configuration } from './configuration';
import { useHistory } from 'react-router-dom';
import {
TAB_CONFIG_ID,
TAB_CONFIG_TITLE,
Expand All @@ -49,22 +39,30 @@ import {
TAB_TRACE_ID,
TAB_TRACE_TITLE,
} from '../../../../common/constants/application_analytics';
import { TAB_EVENT_ID, TAB_CHART_ID, NEW_TAB } from '../../../../common/constants/explorer';
import { IQueryTab } from '../../../../common/types/explorer';
import { NotificationsStart, Toast } from '../../../../../../src/core/public';
import { AppAnalyticsComponentDeps } from '../home';
import { CustomPanelView } from '../../../../public/components/custom_panels/custom_panel_view';
import { CUSTOM_PANELS_API_PREFIX } from '../../../../common/constants/custom_panels';
import { NEW_TAB, TAB_CHART_ID, TAB_EVENT_ID } from '../../../../common/constants/explorer';
import { QueryManager } from '../../../../common/query_manager/ppl_query_manager';
import {
ApplicationRequestType,
ApplicationType,
} from '../../../../common/types/application_analytics';
import { CUSTOM_PANELS_API_PREFIX } from '../../../../common/constants/custom_panels';
import { ServiceDetailFlyout } from './flyout_components/service_detail_flyout';
import { IQueryTab } from '../../../../common/types/explorer';
import { setNavBreadCrumbs } from '../../../../common/utils/set_nav_bread_crumbs';
import { CustomPanelView } from '../../../../public/components/custom_panels/custom_panel_view';
import {
filtersToDsl,
PanelTitle,
} from '../../../../public/components/trace_analytics/components/common/helper_functions';
import { SpanDetailFlyout } from '../../../../public/components/trace_analytics/components/traces/span_detail_flyout';
import { TraceDetailFlyout } from './flyout_components/trace_detail_flyout';
import { SpanDetailTable } from '../../../../public/components/trace_analytics/components/traces/span_detail_table';
import { TracesContent } from '../../../components/trace_analytics/components/traces/traces_content';
import { Explorer } from '../../event_analytics/explorer/explorer';
import { ServicesContent } from '../../trace_analytics/components/services/services_content';
import { fetchAppById, initializeTabData } from '../helpers/utils';
import { QueryManager } from '../../../../common/query_manager/ppl_query_manager';
import { setNavBreadCrumbs } from '../../../../common/utils/set_nav_bread_crumbs';
import { AppAnalyticsComponentDeps } from '../home';
import { Configuration } from './configuration';
import { ServiceDetailFlyout } from './flyout_components/service_detail_flyout';
import { TraceDetailFlyout } from './flyout_components/trace_detail_flyout';

const searchBarConfigs = {
[TAB_EVENT_ID]: {
Expand Down Expand Up @@ -303,6 +301,7 @@ export function Application(props: AppDetailProps) {
endTime={appEndTime}
setStartTime={setStartTimeForApp}
setEndTime={setEndTimeForApp}
dataSourceMDSId={[{ id: '', label: '' }]}
/>
</>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,7 @@ exports[`Explorer Search component renders basic component 1`] = `
},
]
}
compressed={false}
data-test-subj="pplSearchDatePicker"
dateFormat=""
end="now"
Expand Down Expand Up @@ -423,6 +424,7 @@ exports[`Explorer Search component renders basic component 1`] = `
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -718,7 +720,9 @@ exports[`Explorer Search component renders basic component 1`] = `
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1979,6 +1979,7 @@ exports[`Panels View Component renders panel view container with visualizations
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand All @@ -2005,6 +2006,7 @@ exports[`Panels View Component renders panel view container with visualizations
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -2302,7 +2304,9 @@ exports[`Panels View Component renders panel view container with visualizations
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand All @@ -2315,6 +2319,7 @@ exports[`Panels View Component renders panel view container with visualizations
className="euiFlexItem euiFlexItem--flexGrowZero"
>
<EuiSuperUpdateButton
compressed={false}
data-test-subj="superDatePickerApplyTimeButton"
isDisabled={false}
isLoading={false}
Expand Down Expand Up @@ -2342,6 +2347,7 @@ exports[`Panels View Component renders panel view container with visualizations
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand All @@ -2361,6 +2367,7 @@ exports[`Panels View Component renders panel view container with visualizations
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand Down Expand Up @@ -4230,6 +4237,7 @@ exports[`Panels View Component renders panel view container without visualizatio
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand All @@ -4256,6 +4264,7 @@ exports[`Panels View Component renders panel view container without visualizatio
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -4551,7 +4560,9 @@ exports[`Panels View Component renders panel view container without visualizatio
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand All @@ -4564,6 +4575,7 @@ exports[`Panels View Component renders panel view container without visualizatio
className="euiFlexItem euiFlexItem--flexGrowZero"
>
<EuiSuperUpdateButton
compressed={false}
data-test-subj="superDatePickerApplyTimeButton"
isDisabled={false}
isLoading={false}
Expand Down Expand Up @@ -4591,6 +4603,7 @@ exports[`Panels View Component renders panel view container without visualizatio
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand All @@ -4610,6 +4623,7 @@ exports[`Panels View Component renders panel view container without visualizatio
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,7 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand All @@ -368,6 +369,7 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -663,7 +665,9 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand All @@ -676,6 +680,7 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
className="euiFlexItem euiFlexItem--flexGrowZero"
>
<EuiSuperUpdateButton
compressed={false}
data-test-subj="superDatePickerApplyTimeButton"
isDisabled={false}
isLoading={false}
Expand Down Expand Up @@ -703,6 +708,7 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand All @@ -722,6 +728,7 @@ exports[`Metrics Top Menu Component renders Top Menu Component when enabled 1`]
onBlur={[Function]}
onClick={[Function]}
onFocus={[Function]}
size="m"
textProps={
Object {
"className": "euiSuperUpdateButton__text",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ exports[`Search bar components renders date picker 1`] = `
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand All @@ -72,6 +73,7 @@ exports[`Search bar components renders date picker 1`] = `
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -367,7 +369,9 @@ exports[`Search bar components renders date picker 1`] = `
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand Down Expand Up @@ -555,6 +559,7 @@ exports[`Search bar components renders search bar 1`] = `
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand All @@ -581,6 +586,7 @@ exports[`Search bar components renders search bar 1`] = `
>
<EuiFormControlLayout
className="euiSuperDatePicker"
compressed={false}
isDisabled={false}
prepend={
<EuiQuickSelectPopover
Expand Down Expand Up @@ -878,7 +884,9 @@ exports[`Search bar components renders search bar 1`] = `
</button>
</div>
</EuiDatePickerRange>
<EuiFormControlLayoutIcons />
<EuiFormControlLayoutIcons
compressed={false}
/>
</div>
</div>
</EuiFormControlLayout>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ exports[`Service view component renders service view 1`] = `
},
]
}
compressed={false}
dateFormat=""
end="now"
isAutoRefreshOnly={false}
Expand Down
Loading

0 comments on commit c27b569

Please sign in to comment.