From 8683f97674ea305126cd85d24d195bf51a032217 Mon Sep 17 00:00:00 2001 From: Zalenski Egor <63463140+zalenskiSofteq@users.noreply.github.com> Date: Wed, 26 Apr 2023 23:02:14 +0800 Subject: [PATCH] #RI-4387 - Workbench command processing time in group mode is displayed as actual time * number of commands --- redisinsight/api/src/modules/workbench/workbench.service.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/redisinsight/api/src/modules/workbench/workbench.service.ts b/redisinsight/api/src/modules/workbench/workbench.service.ts index ccdb147e89..85a160d170 100644 --- a/redisinsight/api/src/modules/workbench/workbench.service.ts +++ b/redisinsight/api/src/modules/workbench/workbench.service.ts @@ -81,7 +81,6 @@ export class WorkbenchService { db, databaseId: clientMetadata.databaseId, }; - let executionTimeInNanoseconds = BigInt(0); const startCommandExecutionTime = process.hrtime.bigint(); @@ -96,11 +95,9 @@ export class WorkbenchService { }); } const result = await this.commandsExecutor.sendCommand(clientMetadata, { ...dto, command }); - const endCommandExecutionTime = process.hrtime.bigint(); - - executionTimeInNanoseconds += (endCommandExecutionTime - startCommandExecutionTime); return ({ ...result[0], command }); })); + const executionTimeInNanoseconds = process.hrtime.bigint() - startCommandExecutionTime; if (Number(executionTimeInNanoseconds) !== 0) { commandExecution.executionTime = Math.round(Number(executionTimeInNanoseconds) / 1000);