fixes error percentage key

This commit is contained in:
dhrubesh 2021-05-02 17:11:02 +05:30
parent 25803e660c
commit 63f0eadb61
2 changed files with 6 additions and 4 deletions

View File

@ -115,7 +115,7 @@ const _ServiceMetrics = (props: ServicesMetricsProps) => {
<ExternalApiGraph <ExternalApiGraph
title="External Call Error Percentage (%)" title="External Call Error Percentage (%)"
keyIdentifier="externalHttpUrl" keyIdentifier="externalHttpUrl"
dataIdentifier="numCalls" dataIdentifier="errorRate"
data={props.externalErrCodeMetrics} data={props.externalErrCodeMetrics}
/> />
</Card> </Card>

View File

@ -33,9 +33,9 @@ export interface externalMetricsAvgDurationItem {
} }
export interface externalErrCodeMetricsItem { export interface externalErrCodeMetricsItem {
callRate: number; errorRate: number;
externalHttpUrl: string; externalHttpUrl: string;
numCalls: number; numErrors: number;
timestamp: number; timestamp: number;
} }
export interface topEndpointListItem { export interface topEndpointListItem {
@ -131,7 +131,9 @@ export const getDbOverViewMetrics = (
"&end=" + "&end=" +
globalTime.maxTime + globalTime.maxTime +
"&step=60"; "&step=60";
const response = await api.get<dbOverviewMetricsItem[]>(apiV1 + request_string); const response = await api.get<dbOverviewMetricsItem[]>(
apiV1 + request_string,
);
dispatch<getDbOverViewMetricsAction>({ dispatch<getDbOverViewMetricsAction>({
type: ActionTypes.getDbOverviewMetrics, type: ActionTypes.getDbOverviewMetrics,
payload: response.data, payload: response.data,