Add better tags to InfluxDB for GPSI data. (#3429)

This commit is contained in:
Peter Hedenskog 2021-07-28 22:39:29 +02:00 committed by GitHub
parent 05531a1137
commit 1fac02f6ae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 0 deletions

View File

@ -207,6 +207,16 @@ class InfluxDBDataGenerator {
tags.experience = keyArray[0];
tags.formFactor = keyArray[1];
tags.metric = keyArray[2];
} else if (type === 'gpsi.pageSummary') {
if (key.indexOf('googleWebVitals') > -1) {
tags.testType = 'googleWebVitals';
} else if (key.indexOf('score') > -1) {
tags.testType = 'score';
} else if (key.indexOf('loadingExperience') > -1) {
tags.experience = keyArray[0];
tags.metric = keyArray[1];
tags.testType = 'crux';
}
} else {
// console.log('Missed added tags to ' + key + ' ' + type);
}