Skip to content

Commit

Permalink
Merge pull request #38405 from Expensify/vit-updateGraphiteString
Browse files Browse the repository at this point in the history
[NoQA] Update the format of the string sent for reassure test dashboard
  • Loading branch information
mountiny authored Mar 15, 2024
2 parents cdd93d1 + efb8958 commit f44c5f4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -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');

Expand Down
7 changes: 4 additions & 3 deletions .github/actions/javascript/getGraphiteString/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -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');

Expand Down

0 comments on commit f44c5f4

Please sign in to comment.