diff --git a/src/legacy/router.js b/src/legacy/router.js index afc8c1a797..72d9de359f 100644 --- a/src/legacy/router.js +++ b/src/legacy/router.js @@ -646,9 +646,6 @@ if (startDestTransformer) { ctx.status = ctxStatusCode; ctx.set('apiVersion', API_VERSION); - stats.timing('user_transform_request_latency', startTime, { - processSessions, - }); stats.timingSummary('user_transform_request_latency_summary', startTime, { processSessions, }); diff --git a/src/services/userTransform.ts b/src/services/userTransform.ts index db9facc152..3a0ea18212 100644 --- a/src/services/userTransform.ts +++ b/src/services/userTransform.ts @@ -169,16 +169,6 @@ export class UserTransformService { ...getTransformationMetadata(eventsToProcess[0]?.metadata), }); } finally { - stats.timing('user_transform_request_latency', userFuncStartTime, { - ...metaTags, - ...getTransformationMetadata(eventsToProcess[0]?.metadata), - }); - - stats.timing('user_transform_batch_size', requestSize, { - ...metaTags, - ...getTransformationMetadata(eventsToProcess[0]?.metadata), - }); - stats.timingSummary('user_transform_request_latency_summary', userFuncStartTime, { ...metaTags, ...getTransformationMetadata(eventsToProcess[0]?.metadata), diff --git a/src/util/customTransformer-v1.js b/src/util/customTransformer-v1.js index e9877a614d..13ee9f7c98 100644 --- a/src/util/customTransformer-v1.js +++ b/src/util/customTransformer-v1.js @@ -92,7 +92,6 @@ async function userTransformHandlerV1( ...(events.length && events[0].metadata ? getTransformationMetadata(events[0].metadata) : {}), }; stats.counter('user_transform_function_input_events', events.length, tags); - stats.timing('user_transform_function_latency', invokeTime, tags); stats.timingSummary('user_transform_function_latency_summary', invokeTime, tags); } diff --git a/src/util/customTransformer.js b/src/util/customTransformer.js index 37364ef5d0..1a547e58a7 100644 --- a/src/util/customTransformer.js +++ b/src/util/customTransformer.js @@ -259,7 +259,6 @@ async function runUserTransform( }; stats.counter('user_transform_function_input_events', events.length, tags); - stats.timing('user_transform_function_latency', invokeTime, tags); stats.timingSummary('user_transform_function_latency_summary', invokeTime, tags); } diff --git a/src/util/customTransforrmationsStore-v1.js b/src/util/customTransforrmationsStore-v1.js index 6e2d799f3a..ff3b0a7b99 100644 --- a/src/util/customTransforrmationsStore-v1.js +++ b/src/util/customTransforrmationsStore-v1.js @@ -30,7 +30,6 @@ async function getTransformationCodeV1(versionId) { responseStatusHandler(response.status, 'Transformation', versionId, url); stats.increment('get_transformation_code', { success: 'true', ...tags }); - stats.timing('get_transformation_code_time', startTime, tags); stats.timingSummary('get_transformation_code_time_summary', startTime, tags); const myJson = await response.json(); transformationCache[versionId] = myJson; @@ -56,7 +55,6 @@ async function getLibraryCodeV1(versionId) { responseStatusHandler(response.status, 'Transformation Library', versionId, url); stats.increment('get_libraries_code', { success: 'true', ...tags }); - stats.timing('get_libraries_code_time', startTime, tags); stats.timingSummary('get_libraries_code_time_summary', startTime, tags); const myJson = await response.json(); libraryCache[versionId] = myJson; @@ -84,7 +82,6 @@ async function getRudderLibByImportName(importName) { responseStatusHandler(response.status, 'Rudder Library', importName, url); stats.increment('get_libraries_code', { success: 'true', ...tags }); - stats.timing('get_libraries_code_time', startTime, tags); stats.timingSummary('get_libraries_code_time_summary', startTime, tags); const myJson = await response.json(); rudderLibraryCache[importName] = myJson; diff --git a/src/util/customTransforrmationsStore.js b/src/util/customTransforrmationsStore.js index 2c5a7b446d..d6342cfc72 100644 --- a/src/util/customTransforrmationsStore.js +++ b/src/util/customTransforrmationsStore.js @@ -23,7 +23,6 @@ async function getTransformationCode(versionId) { responseStatusHandler(response.status, 'Transformation', versionId, url); stats.increment('get_transformation_code', { versionId, success: 'true' }); - stats.timing('get_transformation_code_time', startTime, { versionId }); stats.timingSummary('get_transformation_code_time_summary', startTime, { versionId }); const myJson = await response.json(); myCache.set(versionId, myJson); diff --git a/src/util/openfaas/index.js b/src/util/openfaas/index.js index c0369deb81..ac072c4599 100644 --- a/src/util/openfaas/index.js +++ b/src/util/openfaas/index.js @@ -379,7 +379,6 @@ const executeFaasFunction = async ( }; stats.counter('user_transform_function_input_events', events.length, tags); - stats.timing('user_transform_function_latency', startTime, tags); stats.timingSummary('user_transform_function_latency_summary', startTime, tags); } }; diff --git a/src/util/prometheus.js b/src/util/prometheus.js index 99eca6a90e..3776951f59 100644 --- a/src/util/prometheus.js +++ b/src/util/prometheus.js @@ -737,18 +737,6 @@ class Prometheus { 'feature', ], }, - { - name: 'user_transform_request_latency', - help: 'user_transform_request_latency', - type: 'histogram', - labelNames: [ - 'workspaceId', - 'transformationId', - 'sourceType', - 'destinationType', - 'k8_namespace', - ], - }, { name: 'user_transform_request_latency_summary', help: 'user_transform_request_latency_summary', @@ -761,22 +749,6 @@ class Prometheus { 'k8_namespace', ], }, - { - name: 'user_transform_batch_size', - help: 'user_transform_batch_size', - type: 'histogram', - labelNames: [ - 'workspaceId', - 'transformationId', - 'sourceType', - 'destinationType', - 'k8_namespace', - ], - buckets: [ - 1024, 102400, 524288, 1048576, 10485760, 20971520, 52428800, 104857600, 209715200, - 524288000, - ], // 1KB, 100KB, 0.5MB, 1MB, 10MB, 20MB, 50MB, 100MB, 200MB, 500MB - }, { name: 'user_transform_batch_size_summary', help: 'user_transform_batch_size_summary', @@ -839,24 +811,12 @@ class Prometheus { type: 'histogram', labelNames: ['versionId'], }, - { - name: 'get_transformation_code_time', - help: 'get_transformation_code_time', - type: 'histogram', - labelNames: ['versionId', 'version'], - }, { name: 'get_transformation_code_time_summary', help: 'get_transformation_code_time_summary', type: 'summary', labelNames: ['versionId', 'version'], }, - { - name: 'get_libraries_code_time', - help: 'get_libraries_code_time', - type: 'histogram', - labelNames: ['libraryVersionId', 'versionId', 'type', 'version'], - }, { name: 'get_libraries_code_time_summary', help: 'get_libraries_code_time_summary', @@ -1098,22 +1058,6 @@ class Prometheus { 'workspaceId', ], }, - { - name: 'user_transform_function_latency', - help: 'user_transform_function_latency', - type: 'histogram', - labelNames: [ - 'identifier', - 'testMode', - 'sourceType', - 'destinationType', - 'k8_namespace', - 'errored', - 'statusCode', - 'transformationId', - 'workspaceId', - ], - }, { name: 'user_transform_function_latency_summary', help: 'user_transform_function_latency_summary',