Bug 1672719 - Stop reporting confidence/replayed/not-replayed to Perfherder and remove all asociated code r=perftest-reviewers,AlexandruIonescu

Differential Revision: https://phabricator.services.mozilla.com/D103619
This commit is contained in:
Florin Strugariu 2021-02-02 14:18:57 +00:00
parent 1ea34c359f
commit efc1960325
5 changed files with 1 additions and 89 deletions

View File

@ -31,7 +31,3 @@ class Playback(object):
@abstractmethod @abstractmethod
def stop(self): def stop(self):
pass pass
@abstractmethod
def confidence(self):
pass

View File

@ -429,62 +429,3 @@ class Mitmproxy(Playback):
return True return True
except socket.error: except socket.error:
return False return False
def confidence(self):
"""Extract confidence metrics from the netlocs file
and convert them to perftest results
"""
if len(self.playback_files) == 0:
LOG.warning(
"Proxy service did not load a recording file. "
"Confidence metrics will nt be generated"
)
return
file_name = (
"mitm_netlocs_%s.json"
% os.path.splitext(os.path.basename(self.playback_files[0].recording_path))[
0
]
)
path = os.path.normpath(os.path.join(self.upload_dir, file_name))
if os.path.exists(path):
try:
LOG.info("Reading confidence values from: %s" % path)
with open(path, "r") as f:
data = json.load(f)
return {
"replay-confidence": {
"values": data["replay-confidence"],
"subtest-prefix-type": False,
"unit": "%",
"shouldAlert": False,
"lowerIsBetter": False,
},
"recording-proportion-used": {
"values": data["recording-proportion-used"],
"subtest-prefix-type": False,
"unit": "%",
"shouldAlert": False,
"lowerIsBetter": False,
},
"not-replayed": {
"values": data["not-replayed"],
"subtest-prefix-type": False,
"shouldAlert": False,
"unit": "a.u.",
},
"replayed": {
"values": data["replayed"],
"subtest-prefix-type": False,
"unit": "a.u.",
"shouldAlert": False,
"lowerIsBetter": False,
},
}
except Exception:
LOG.info("Can't read netlocs file!", exc_info=True)
return None
else:
LOG.info("Netlocs file is not available! Cant find %s" % path)
return None

View File

@ -34,7 +34,6 @@ class PerftestOutput(object):
self.summarized_supporting_data = [] self.summarized_supporting_data = []
self.summarized_screenshots = [] self.summarized_screenshots = []
self.subtest_alert_on = subtest_alert_on self.subtest_alert_on = subtest_alert_on
self.mozproxy_data = False
self.browser_name = None self.browser_name = None
self.browser_version = None self.browser_version = None
@ -97,10 +96,6 @@ class PerftestOutput(object):
data_type = data_set["type"] data_type = data_set["type"]
LOG.info("summarizing %s data" % data_type) LOG.info("summarizing %s data" % data_type)
if "mozproxy" in data_type:
self.mozproxy_data = True
LOG.info("data: {}".format(self.supporting_data))
if data_type not in support_data_by_type: if data_type not in support_data_by_type:
support_data_by_type[data_type] = { support_data_by_type[data_type] = {
"framework": {"name": "raptor"}, "framework": {"name": "raptor"},
@ -253,7 +248,7 @@ class PerftestOutput(object):
# dumped out. TODO: Bug 1515406 - Add option to output both supplementary # dumped out. TODO: Bug 1515406 - Add option to output both supplementary
# data (i.e. power) and the regular Raptor test result # data (i.e. power) and the regular Raptor test result
# Both are already available as separate PERFHERDER_DATA json blobs # Both are already available as separate PERFHERDER_DATA json blobs
if len(self.summarized_supporting_data) == 0 or self.mozproxy_data: if len(self.summarized_supporting_data) == 0:
LOG.info("PERFHERDER_DATA: %s" % json.dumps(self.summarized_results)) LOG.info("PERFHERDER_DATA: %s" % json.dumps(self.summarized_results))
total_perfdata = 1 total_perfdata = 1
else: else:

View File

@ -191,10 +191,6 @@ class PerftestResultsHandler(object):
expected_perfherder = 1 expected_perfherder = 1
if output.mozproxy_data:
# Check if we have mozproxy data available.
expected_perfherder += 1
if is_resource_test(): if is_resource_test():
# when resource tests are run, no perfherder data is output # when resource tests are run, no perfherder data is output
# for the regular raptor tests (i.e. speedometer) so we # for the regular raptor tests (i.e. speedometer) so we

View File

@ -143,22 +143,6 @@ class WebExtension(Perftest):
if self.playback is not None: if self.playback is not None:
self.playback.stop() self.playback.stop()
confidence_values = self.playback.confidence()
if confidence_values:
mozproxy_replay = {
u"summarize-values": False,
u"suite-suffix-type": False,
u"type": u"mozproxy",
u"test": test["name"],
u"unit": u"a.u.",
u"values": confidence_values,
u"shouldAlert": False, # Bug 1655841 temporary disable confidence metrics
}
self.control_server.submit_supporting_data(mozproxy_replay)
else:
LOG.info("Mozproxy replay confidence data not available!")
self.playback = None self.playback = None
self.remove_raptor_webext() self.remove_raptor_webext()