From 6cfef3815857d23a951ab81845583d68215557d1 Mon Sep 17 00:00:00 2001 From: Vit Horacek Date: Fri, 15 Mar 2024 16:21:36 +0000 Subject: [PATCH 1/2] Pass the PR number differently for graphite --- .../javascript/getGraphiteString/getGraphiteString.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/actions/javascript/getGraphiteString/getGraphiteString.js b/.github/actions/javascript/getGraphiteString/getGraphiteString.js index 673bf4213707..d4504a79ef6f 100644 --- a/.github/actions/javascript/getGraphiteString/getGraphiteString.js +++ b/.github/actions/javascript/getGraphiteString/getGraphiteString.js @@ -35,10 +35,11 @@ const run = () => { // Graphite doesn't accept metrics name with space, we replace spaces with "-" const formattedName = current.name.split(' ').join('-'); - const renderDurationString = `${GRAPHITE_PATH}.PR-${prNumber}.${formattedName}.renderDuration ${current.meanDuration} ${timestamp}`; - const renderCountString = `${GRAPHITE_PATH}.PR-${prNumber}.${formattedName}.renderCount ${current.meanCount} ${timestamp}`; + const renderDurationString = `${GRAPHITE_PATH}.${formattedName}.renderDuration ${current.meanDuration} ${timestamp}`; + const renderCountString = `${GRAPHITE_PATH}.${formattedName}.renderCount ${current.meanCount} ${timestamp}`; + const renderPRNumberString = `${GRAPHITE_PATH}.${formattedName}.prNumber ${prNumber} ${timestamp}`; - return `${renderDurationString}\n${renderCountString}`; + return `${renderDurationString}\n${renderCountString}\n${renderPRNumberString}`; }) .join('\n'); From efb89582052a341d98f9bcb8841b0dfe46946031 Mon Sep 17 00:00:00 2001 From: Vit Horacek Date: Fri, 15 Mar 2024 16:23:19 +0000 Subject: [PATCH 2/2] Build the gh actions --- .github/actions/javascript/getGraphiteString/index.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/actions/javascript/getGraphiteString/index.js b/.github/actions/javascript/getGraphiteString/index.js index 6aae40c98ac0..f4bce400e413 100644 --- a/.github/actions/javascript/getGraphiteString/index.js +++ b/.github/actions/javascript/getGraphiteString/index.js @@ -44,10 +44,11 @@ const run = () => { // Graphite doesn't accept metrics name with space, we replace spaces with "-" const formattedName = current.name.split(' ').join('-'); - const renderDurationString = `${GRAPHITE_PATH}.PR-${prNumber}.${formattedName}.renderDuration ${current.meanDuration} ${timestamp}`; - const renderCountString = `${GRAPHITE_PATH}.PR-${prNumber}.${formattedName}.renderCount ${current.meanCount} ${timestamp}`; + const renderDurationString = `${GRAPHITE_PATH}.${formattedName}.renderDuration ${current.meanDuration} ${timestamp}`; + const renderCountString = `${GRAPHITE_PATH}.${formattedName}.renderCount ${current.meanCount} ${timestamp}`; + const renderPRNumberString = `${GRAPHITE_PATH}.${formattedName}.prNumber ${prNumber} ${timestamp}`; - return `${renderDurationString}\n${renderCountString}`; + return `${renderDurationString}\n${renderCountString}\n${renderPRNumberString}`; }) .join('\n');