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

Side by Side Diff: chrome/renderer/page_load_histograms.cc

Issue 18601004: Add the UMA PLT.BeginToFinish{,Doc}_AfterPreconnectRequest (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: follow interface change Created 7 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/page_load_histograms.h" 5 #include "chrome/renderer/page_load_histograms.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 begin_to_finish_doc); 403 begin_to_finish_doc);
404 PLT_HISTOGRAM("PLT.BeginToFinish_ContentPrefetcher", 404 PLT_HISTOGRAM("PLT.BeginToFinish_ContentPrefetcher",
405 begin_to_finish_all_loads); 405 begin_to_finish_all_loads);
406 } 406 }
407 if (document_state->was_referred_by_prefetcher()) { 407 if (document_state->was_referred_by_prefetcher()) {
408 PLT_HISTOGRAM("PLT.BeginToFinishDoc_ContentPrefetcherReferrer", 408 PLT_HISTOGRAM("PLT.BeginToFinishDoc_ContentPrefetcherReferrer",
409 begin_to_finish_doc); 409 begin_to_finish_doc);
410 PLT_HISTOGRAM("PLT.BeginToFinish_ContentPrefetcherReferrer", 410 PLT_HISTOGRAM("PLT.BeginToFinish_ContentPrefetcherReferrer",
411 begin_to_finish_all_loads); 411 begin_to_finish_all_loads);
412 } 412 }
413 if (document_state->was_after_preconnect_request()) {
414 PLT_HISTOGRAM("PLT.BeginToFinishDoc_AfterPreconnectRequest",
415 begin_to_finish_doc);
416 PLT_HISTOGRAM("PLT.BeginToFinish_AfterPreconnectRequest",
417 begin_to_finish_all_loads);
418 }
413 419
414 // TODO(mpcomplete): remove the extension-related histograms after we collect 420 // TODO(mpcomplete): remove the extension-related histograms after we collect
415 // enough data. http://crbug.com/100411 421 // enough data. http://crbug.com/100411
416 const bool use_adblock_histogram = 422 const bool use_adblock_histogram =
417 chrome::ChromeContentRendererClient::IsAdblockInstalled(); 423 chrome::ChromeContentRendererClient::IsAdblockInstalled();
418 if (use_adblock_histogram) { 424 if (use_adblock_histogram) {
419 UMA_HISTOGRAM_ENUMERATION( 425 UMA_HISTOGRAM_ENUMERATION(
420 "PLT.Abandoned_ExtensionAdblock", 426 "PLT.Abandoned_ExtensionAdblock",
421 abandoned_page ? 1 : 0, 2); 427 abandoned_page ? 1 : 0, 2);
422 switch (load_type) { 428 switch (load_type) {
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
710 716
711 DCHECK(document_state); 717 DCHECK(document_state);
712 DCHECK(ds); 718 DCHECK(ds);
713 GURL url(ds->request().url()); 719 GURL url(ds->request().url());
714 Time start = document_state->start_load_time(); 720 Time start = document_state->start_load_time();
715 Time finish = document_state->finish_load_time(); 721 Time finish = document_state->finish_load_time();
716 // TODO(mbelshe): should we log more stats? 722 // TODO(mbelshe): should we log more stats?
717 VLOG(1) << "PLT: " << (finish - start).InMilliseconds() << "ms " 723 VLOG(1) << "PLT: " << (finish - start).InMilliseconds() << "ms "
718 << url.spec(); 724 << url.spec();
719 } 725 }
OLDNEW
« no previous file with comments | « no previous file | content/child/request_extra_data.h » ('j') | webkit/glue/weburlrequest_extradata_impl.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698