Title: [270140] trunk/Websites/perf.webkit.org
Revision
270140
Author
[email protected]
Date
2020-11-20 17:27:13 -0800 (Fri, 20 Nov 2020)

Log Message

'run-analysis' script should schedule retries for A/B tests even after chart analysis failure.
https://bugs.webkit.org/show_bug.cgi?id=219116

Reviewed by Ryosuke Niwa.

Anlyzing charts and schedule retries for A/B tests on run-analysis script are independent task.
It should not skip scheduling retries even when chart analysis part fails.

* tools/run-analysis.js:
(async analysisLoop): Change the logic so that chart analysis failure will not stop scheduling retries.
Fix a typo for 'notificationRemoteAPI'.

Modified Paths

Diff

Modified: trunk/Websites/perf.webkit.org/ChangeLog (270139 => 270140)


--- trunk/Websites/perf.webkit.org/ChangeLog	2020-11-21 01:11:20 UTC (rev 270139)
+++ trunk/Websites/perf.webkit.org/ChangeLog	2020-11-21 01:27:13 UTC (rev 270140)
@@ -1,3 +1,17 @@
+2020-11-20  Dewei Zhu  <[email protected]>
+
+        'run-analysis' script should schedule retries for A/B tests even after chart analysis failure.
+        https://bugs.webkit.org/show_bug.cgi?id=219116
+
+        Reviewed by Ryosuke Niwa.
+
+        Anlyzing charts and schedule retries for A/B tests on run-analysis script are independent task.
+        It should not skip scheduling retries even when chart analysis part fails.
+
+        * tools/run-analysis.js:
+        (async analysisLoop): Change the logic so that chart analysis failure will not stop scheduling retries.
+        Fix a typo for 'notificationRemoteAPI'.
+
 2020-11-18  Dewei Zhu  <[email protected]>
 
         Fix a bug that platform groups cannot be updated on 'admin/platform'.

Modified: trunk/Websites/perf.webkit.org/tools/run-analysis.js (270139 => 270140)


--- trunk/Websites/perf.webkit.org/tools/run-analysis.js	2020-11-21 01:11:20 UTC (rev 270139)
+++ trunk/Websites/perf.webkit.org/tools/run-analysis.js	2020-11-21 01:27:13 UTC (rev 270140)
@@ -28,13 +28,11 @@
 
 async function analysisLoop(options)
 {
-    let secondsToSleep;
+    const secondsToSleep = options['--seconds-to-sleep'];
     try {
         const serverConfig = JSON.parse(fs.readFileSync(options['--server-config-json'], 'utf-8'));
-        const notificationConfig = JSON.parse(fs.readFileSync(options['--notification-config-json'], 'utf-8'));
         const analysisRangeInDays = options['--analysis-range-in-days'];
-        const maximumRetryFactor = options['--max-retry-factor'];
-        secondsToSleep = options['--seconds-to-sleep'];
+
         global.RemoteAPI = new RemoteAPI(serverConfig.server);
         PrivilegedAPI.configure(serverConfig.slave.name, serverConfig.slave.password);
 
@@ -47,19 +45,25 @@
 
         console.log(`Start analyzing last ${analysisRangeInDays} days measurement sets.`);
         await analyzer.analyzeOnce();
+    } catch (error) {
+        console.error(`Failed to analyze measurement sets due to ${error}`);
+    }
 
+    try {
+        const notificationConfig = JSON.parse(fs.readFileSync(options['--notification-config-json'], 'utf-8'));
+        const maximumRetryFactor = options['--max-retry-factor'];
         const testGroupsMayNeedMoreRequests = await TestGroup.fetchAllThatMayNeedMoreRequests();
         await createAdditionalBuildRequestsForTestGroupsWithFailedRequests(testGroupsMayNeedMoreRequests, maximumRetryFactor);
 
         const testGroupsNeedNotification = await TestGroup.fetchAllWithNotificationReady();
-        const notificationRemoveAPI = new RemoteAPI(notificationConfig.notificationServerConfig);
+        const notificationRemoteAPI = new RemoteAPI(notificationConfig.notificationServerConfig);
         const notificationMessageConfig = notificationConfig.notificationMessageConfig;
         const notifier = new AnalysisResultsNotifier(notificationMessageConfig.messageTemplate, notificationMessageConfig.finalizeScript,
-            notificationMessageConfig.messageConstructionRules, notificationRemoveAPI, notificationConfig.notificationServerConfig.path, new Subprocess);
+            notificationMessageConfig.messageConstructionRules, notificationRemoteAPI, notificationConfig.notificationServerConfig.path, new Subprocess);
 
         await notifier.sendNotificationsForTestGroups(testGroupsNeedNotification);
-    } catch(error) {
-        console.error(`Failed analyze measurement sets due to ${error}`);
+    } catch (error) {
+        console.error(`Failed to retry test groups due to ${error}`);
     }
 
     console.log(`Sleeping for ${secondsToSleep} seconds.`);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to