Commit 5a7c7bf9 authored by valenting's avatar valenting
Browse files

Bug 1640867 - Add new HTTP_CHANNEL_ONSTART_SUCCESS_TRR probe r=dragana,tdsmith,necko-reviewers

Differential Revision: https://phabricator.services.mozilla.com/D77127
parent 5570291e
......@@ -35,7 +35,7 @@ class TRRService : public TRRServiceBase,
TRRService();
nsresult Init();
nsresult Start();
bool Enabled(nsIRequest::TRRMode aMode);
bool Enabled(nsIRequest::TRRMode aMode = nsIRequest::TRR_FIRST_MODE);
bool IsConfirmed() { return mConfirmationState == CONFIRM_OK; }
bool AllowRFC1918() { return mRfc1918; }
......
......@@ -129,6 +129,7 @@
#include "mozilla/net/SocketProcessParent.h"
#include "js/Conversions.h"
#include "mozilla/dom/SecFetch.h"
#include "mozilla/net/TRRService.h"
#ifdef MOZ_TASK_TRACER
# include "GeckoTaskTracer.h"
......@@ -7465,6 +7466,11 @@ nsHttpChannel::OnStartRequest(nsIRequest* request) {
Telemetry::Accumulate(Telemetry::HTTP_CHANNEL_ONSTART_SUCCESS,
NS_SUCCEEDED(mStatus));
if (gTRRService && gTRRService->Enabled()) {
Telemetry::Accumulate(Telemetry::HTTP_CHANNEL_ONSTART_SUCCESS_TRR,
TRRService::AutoDetectedKey(), NS_SUCCEEDED(mStatus));
}
if (mRaceCacheWithNetwork) {
LOG(
(" racingNetAndCache - mFirstResponseSource:%d fromCache:%d "
......
......@@ -3122,6 +3122,17 @@
"releaseChannelCollection": "opt-out",
"alert_emails": ["necko@mozilla.com", "ddamjanovic@mozilla.com"]
},
"HTTP_CHANNEL_ONSTART_SUCCESS_TRR" : {
"record_in_processes": ["main"],
"products": ["firefox", "fennec", "geckoview"],
"expires_in_version": "never",
"kind": "boolean",
"keyed": true,
"description": "Successfully started HTTP channels when TRR is enabled; Keyed by TRR auto-detected",
"bug_numbers": [1640867],
"releaseChannelCollection": "opt-out",
"alert_emails": ["necko@mozilla.com", "vgosu@mozilla.com"]
},
"HTTP_CONNECTION_ENTRY_CACHE_HIT_1" : {
"record_in_processes": ["main", "content"],
"products": ["firefox", "fennec", "geckoview"],
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment