From 825d2dfcbbee08c37e621f12e98a42c075ea7735 Mon Sep 17 00:00:00 2001 From: SagarRajput-7 <162284829+SagarRajput-7@users.noreply.github.com> Date: Fri, 27 Dec 2024 12:06:18 +0530 Subject: [PATCH 1/2] fix: added handling for new key - duration_nano in traces (#6658) Co-authored-by: Srikanth Chekuri --- frontend/src/container/TimeSeriesView/index.tsx | 3 ++- frontend/src/container/Trace/TraceTable/util.ts | 2 +- frontend/src/container/TracesExplorer/ListView/utils.tsx | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/frontend/src/container/TimeSeriesView/index.tsx b/frontend/src/container/TimeSeriesView/index.tsx index b619e64b02..c285ab70b6 100644 --- a/frontend/src/container/TimeSeriesView/index.tsx +++ b/frontend/src/container/TimeSeriesView/index.tsx @@ -29,7 +29,8 @@ function TimeSeriesViewContainer({ currentQuery.builder.queryData.forEach( ({ aggregateAttribute, aggregateOperator }) => { const isExistDurationNanoAttribute = - aggregateAttribute.key === 'durationNano'; + aggregateAttribute.key === 'durationNano' || + aggregateAttribute.key === 'duration_nano'; const isCountOperator = aggregateOperator === 'count' || aggregateOperator === 'count_distinct'; diff --git a/frontend/src/container/Trace/TraceTable/util.ts b/frontend/src/container/Trace/TraceTable/util.ts index 08276636c1..4b2e8c7c13 100644 --- a/frontend/src/container/Trace/TraceTable/util.ts +++ b/frontend/src/container/Trace/TraceTable/util.ts @@ -1,5 +1,5 @@ export const getSpanOrderParam = (key: string): string => { - if (key === 'durationNano') { + if (key === 'durationNano' || key === 'duration_nano') { return 'duration'; } if (key === 'timestamp') { diff --git a/frontend/src/container/TracesExplorer/ListView/utils.tsx b/frontend/src/container/TracesExplorer/ListView/utils.tsx index 8dd20669a0..35c9f5aa8f 100644 --- a/frontend/src/container/TracesExplorer/ListView/utils.tsx +++ b/frontend/src/container/TracesExplorer/ListView/utils.tsx @@ -96,7 +96,7 @@ export const getListColumns = ( ); } - if (key === 'durationNano') { + if (key === 'durationNano' || key === 'duration_nano') { return ( {getMs(value)}ms From 7f6bad67d584dceed19b3770a0cac89fdfb0d0e5 Mon Sep 17 00:00:00 2001 From: SagarRajput-7 <162284829+SagarRajput-7@users.noreply.github.com> Date: Fri, 27 Dec 2024 12:22:32 +0530 Subject: [PATCH 2/2] chore: changed droprate view options values (#6693) --- .../DropRateView/EvaluationTimeSelector.tsx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/frontend/src/pages/MessagingQueues/MQDetails/DropRateView/EvaluationTimeSelector.tsx b/frontend/src/pages/MessagingQueues/MQDetails/DropRateView/EvaluationTimeSelector.tsx index 2ca2e9c301..fb41c12e99 100644 --- a/frontend/src/pages/MessagingQueues/MQDetails/DropRateView/EvaluationTimeSelector.tsx +++ b/frontend/src/pages/MessagingQueues/MQDetails/DropRateView/EvaluationTimeSelector.tsx @@ -41,7 +41,9 @@ function EvaluationTimeSelector({ setInterval: Dispatch>; }): JSX.Element { const [inputValue, setInputValue] = useState(''); - const [selectedInterval, setSelectedInterval] = useState('5ms'); + const [selectedInterval, setSelectedInterval] = useState( + '10ms', + ); const [dropdownOpen, setDropdownOpen] = useState(false); const handleInputChange = (e: React.ChangeEvent): void => { @@ -98,11 +100,13 @@ function EvaluationTimeSelector({ onDropdownVisibleChange={setDropdownOpen} dropdownRender={renderDropdown} > - - - - + + + + + + );