Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(141)

Unified Diff: net/proxy/proxy_resolver_v8_tracing.h

Issue 1797313003: Add a histogram (Net.PacResultForStrippedUrl) that estimates how often PAC scripts depend on the UR… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update some more comments per mpearson's feedback. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/proxy/proxy_resolver_v8_tracing.h
diff --git a/net/proxy/proxy_resolver_v8_tracing.h b/net/proxy/proxy_resolver_v8_tracing.h
index f5f66cf7486797d0c6282f7dab361b2942cfa283..4ca3c82aac6e87691523ba70579258f4015f00cf 100644
--- a/net/proxy/proxy_resolver_v8_tracing.h
+++ b/net/proxy/proxy_resolver_v8_tracing.h
@@ -89,6 +89,55 @@ class NET_EXPORT ProxyResolverV8TracingFactory {
DISALLOW_COPY_AND_ASSIGN(ProxyResolverV8TracingFactory);
};
+// This enum is used by an UMA histogram, so the values shouldn't be reordered
+// or renumbered.
+//
+// TODO(eroman): Remove when done gathering data for crbug.com/593759
+enum class PacResultForStrippedUrl {
+ // Did NOT measure the impact of running FindProxyForURL() with a modified
+ // URL path, because the original URL could not complete using the
+ // non-blocking DNS mode.
+ SKIPPED_FALLBACK_BLOCKING_DNS = 0,
+
+ // The result of running FindProxyForURL() with a modified URL path appears
+ // to be indistinguishable. (Although there may have been sideffects to the
+ // script state that won't manifest until later invocations).
+ SUCCESS = 1,
+
+ // Calling FindProxyForURL() with a modified URL path returned the same proxy
+ // list, but had measurable sideffects in calls to alert().
+ SUCCESS_DIFFERENT_ALERTS = 2,
+
+ // Calling FindProxyForURL() with a modified URL path returned the same proxy
+ // list, but invoked a different sequence of DNS resolutions. This would
+ // require a rather unusual script to trigger.
+ SUCCESS_DIFFERENT_NUM_DNS = 3,
+
+ // Calling FindProxyForURL() with a modified URL path resulted in a different
+ // set of DNS dependencies.
+ FAIL_ABANDONED = 4,
+
+ // Calling FindProxyForURL() with a modified URL path caused a different
+ // execution flow. Whereas with the original URL it succeeded with
+ // non-blocking DNS, this attempt requires fallback to blocking DNS (and was
+ // not attempted).
+ FAIL_FALLBACK_BLOCKING_DNS = 5,
+
+ // Calling FindProxyForURL() with a modified URL path caused a script error.
+ FAIL_ERROR = 6,
+
+ // Calling FindProxyForURL() with a modified URL path returned a different
+ // proxy list.
+ FAIL_DIFFERENT_PROXY_LIST = 7,
+
+ MAX_VALUE,
+};
+
+// TODO(eroman): Remove when done gathering data for crbug.com/593759
+//
+// This histogram name is exported only for the sake of unit-tests.
+extern NET_EXPORT_PRIVATE const char kHistogramPacResultForStrippedUrl[];
+
} // namespace net
#endif // NET_PROXY_PROXY_RESOLVER_V8_TRACING_H_
« no previous file with comments | « net/data/proxy_resolver_v8_tracing_unittest/return_url_as_proxy.js ('k') | net/proxy/proxy_resolver_v8_tracing.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698