Changeset 211304 in webkit
- Timestamp:
- Jan 27, 2017, 3:11:17 PM (10 years ago)
- Location:
- trunk/Source
- Files:
-
- 7 edited
-
WebCore/ChangeLog (modified) (1 diff)
-
WebCore/page/DiagnosticLoggingKeys.cpp (modified) (8 diffs)
-
WebCore/page/DiagnosticLoggingKeys.h (modified) (8 diffs)
-
WebKit2/ChangeLog (modified) (1 diff)
-
WebKit2/NetworkProcess/cache/NetworkCacheStatistics.cpp (modified) (4 diffs)
-
WebKit2/UIProcess/WebBackForwardList.cpp (modified) (1 diff)
-
WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r211303 r211304 1 2017-01-27 Chris Dumez <cdumez@apple.com> 2 3 Fix remaining bad uses of logDiagnosticMessageWithValue() 4 https://bugs.webkit.org/show_bug.cgi?id=167526 5 6 Reviewed by Alex Christensen. 7 8 Drop unused keys, add new ones. 9 10 * page/DiagnosticLoggingKeys.cpp: 11 (WebCore::DiagnosticLoggingKeys::networkCacheFailureReasonKey): 12 (WebCore::DiagnosticLoggingKeys::networkCacheUnusedReasonKey): 13 (WebCore::DiagnosticLoggingKeys::networkCacheReuseFailureKey): 14 (WebCore::DiagnosticLoggingKeys::backNavigationDeltaKey): 15 (WebCore::DiagnosticLoggingKeys::userZoomActionKey): 16 (WebCore::DiagnosticLoggingKeys::deltaKey): Deleted. 17 (WebCore::DiagnosticLoggingKeys::backNavigationKey): Deleted. 18 (WebCore::DiagnosticLoggingKeys::requestKey): Deleted. 19 (WebCore::DiagnosticLoggingKeys::unusableCachedEntryKey): Deleted. 20 (WebCore::DiagnosticLoggingKeys::userKey): Deleted. 21 (WebCore::DiagnosticLoggingKeys::zoomedKey): Deleted. 22 (WebCore::DiagnosticLoggingKeys::notInCacheKey): Deleted. 23 * page/DiagnosticLoggingKeys.h: 24 1 25 2017-01-27 Myles C. Maxfield <mmaxfield@apple.com> 2 26 -
trunk/Source/WebCore/page/DiagnosticLoggingKeys.cpp
r211301 r211304 154 154 } 155 155 156 String DiagnosticLoggingKeys::networkCacheFailureReasonKey() 157 { 158 return ASCIILiteral("networkCacheFailureReason"); 159 } 160 161 String DiagnosticLoggingKeys::networkCacheUnusedReasonKey() 162 { 163 return ASCIILiteral("networkCacheUnusedReason"); 164 } 165 166 String DiagnosticLoggingKeys::networkCacheReuseFailureKey() 167 { 168 return ASCIILiteral("networkCacheReuseFailure"); 169 } 170 156 171 String DiagnosticLoggingKeys::networkKey() 157 172 { … … 344 359 } 345 360 346 String DiagnosticLoggingKeys::deltaKey()347 {348 return ASCIILiteral("delta");349 }350 351 361 String DiagnosticLoggingKeys::activeInForegroundTabKey() 352 362 { … … 369 379 } 370 380 371 String DiagnosticLoggingKeys::backNavigation Key()372 { 373 return ASCIILiteral("backNavigation ");381 String DiagnosticLoggingKeys::backNavigationDeltaKey() 382 { 383 return ASCIILiteral("backNavigationDelta"); 374 384 } 375 385 … … 434 444 } 435 445 436 String DiagnosticLoggingKeys::requestKey()437 {438 return ASCIILiteral("request");439 }440 441 446 String DiagnosticLoggingKeys::retrievalRequestKey() 442 447 { … … 539 544 } 540 545 541 String DiagnosticLoggingKeys::unusableCachedEntryKey()542 {543 return ASCIILiteral("unusableCachedEntry");544 }545 546 546 String DiagnosticLoggingKeys::unusedKey() 547 547 { … … 589 589 } 590 590 591 String DiagnosticLoggingKeys::user Key()592 { 593 return ASCIILiteral("user ");591 String DiagnosticLoggingKeys::userZoomActionKey() 592 { 593 return ASCIILiteral("userZoomAction"); 594 594 } 595 595 … … 634 634 } 635 635 636 String DiagnosticLoggingKeys::zoomedKey()637 {638 return ASCIILiteral("zoomed");639 }640 641 636 String DiagnosticLoggingKeys::expiredKey() 642 637 { … … 677 672 { 678 673 return ASCIILiteral("notHTTPFamily"); 679 }680 681 String DiagnosticLoggingKeys::notInCacheKey()682 {683 return ASCIILiteral("notInCache");684 674 } 685 675 -
trunk/Source/WebCore/page/DiagnosticLoggingKeys.h
r211301 r211304 36 36 static String applicationCacheKey(); 37 37 static String audioKey(); 38 WEBCORE_EXPORT static String backNavigation Key();38 WEBCORE_EXPORT static String backNavigationDeltaKey(); 39 39 WEBCORE_EXPORT static String cacheControlNoStoreKey(); 40 40 static String cachedResourceRevalidationKey(); … … 44 44 WEBCORE_EXPORT static String cpuUsageKey(); 45 45 WEBCORE_EXPORT static String createSharedBufferFailedKey(); 46 WEBCORE_EXPORT static String deltaKey();47 46 static String deniedByClientKey(); 48 47 static String deviceMotionKey(); … … 84 83 WEBCORE_EXPORT static String needsRevalidationKey(); 85 84 WEBCORE_EXPORT static String networkCacheKey(); 85 WEBCORE_EXPORT static String networkCacheFailureReasonKey(); 86 WEBCORE_EXPORT static String networkCacheUnusedReasonKey(); 87 WEBCORE_EXPORT static String networkCacheReuseFailureKey(); 86 88 static String networkKey(); 87 89 WEBCORE_EXPORT static String networkProcessCrashedKey(); … … 95 97 WEBCORE_EXPORT static String nonVisibleStateKey(); 96 98 WEBCORE_EXPORT static String notHTTPFamilyKey(); 97 WEBCORE_EXPORT static String notInCacheKey();98 99 static String notInMemoryCacheKey(); 99 100 WEBCORE_EXPORT static String otherKey(); … … 123 124 static String reloadKey(); 124 125 static String replaceKey(); 125 WEBCORE_EXPORT static String requestKey();126 126 static String resourceLoadedKey(); 127 127 static String resourceResponseSourceKey(); … … 143 143 WEBCORE_EXPORT static String unsupportedHTTPMethodKey(); 144 144 static String unsuspendableDOMObjectKey(); 145 WEBCORE_EXPORT static String unusableCachedEntryKey();146 145 WEBCORE_EXPORT static String unusedKey(); 147 146 static String unusedReasonCredentialSettingsKey(); … … 153 152 static String unusedReasonTypeMismatchKey(); 154 153 static String usedKey(); 155 WEBCORE_EXPORT static String user Key();154 WEBCORE_EXPORT static String userZoomActionKey(); 156 155 WEBCORE_EXPORT static String varyingHeaderMismatchKey(); 157 156 static String videoKey(); … … 163 162 WEBCORE_EXPORT static String webViewKey(); 164 163 static String yesKey(); 165 WEBCORE_EXPORT static String zoomedKey();166 164 167 165 WEBCORE_EXPORT static String memoryUsageToDiagnosticLoggingKey(uint64_t memoryUsage); -
trunk/Source/WebKit2/ChangeLog
r211295 r211304 1 2017-01-27 Chris Dumez <cdumez@apple.com> 2 3 Fix remaining bad uses of logDiagnosticMessageWithValue() 4 https://bugs.webkit.org/show_bug.cgi?id=167526 5 6 Reviewed by Alex Christensen. 7 8 Fix remaining bad uses of logDiagnosticMessageWithValue(). It can only 9 be called with numeric values. 10 11 * NetworkProcess/cache/NetworkCacheStatistics.cpp: 12 (WebKit::NetworkCache::Statistics::recordNotUsingCacheForRequest): 13 (WebKit::NetworkCache::Statistics::recordRetrievalFailure): 14 (WebKit::NetworkCache::Statistics::recordRetrievedCachedEntry): 15 * UIProcess/WebBackForwardList.cpp: 16 (WebKit::WebBackForwardList::goToItem): 17 * WebProcess/WebPage/ios/WebPageIOS.mm: 18 (WebKit::WebPage::willStartUserTriggeredZooming): 19 1 20 2017-01-27 Chris Dumez <cdumez@apple.com> 2 21 -
trunk/Source/WebKit2/NetworkProcess/cache/NetworkCacheStatistics.cpp
r208985 r211304 221 221 String diagnosticKey = retrieveDecisionToDiagnosticKey(retrieveDecision); 222 222 LOG(NetworkCache, "(NetworkProcess) webPageID %" PRIu64 ": %s was previously requested but we are not using the cache, reason: %s", webPageID, requestURL.string().ascii().data(), diagnosticKey.utf8().data()); 223 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::unusedKey(), diagnosticKey, WebCore::ShouldSample::Yes);223 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheUnusedReasonKey(), diagnosticKey, WebCore::ShouldSample::Yes); 224 224 } else { 225 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::requestKey(), WebCore::DiagnosticLoggingKeys::neverSeenBeforeKey(), WebCore::ShouldSample::Yes);225 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheUnusedReasonKey(), WebCore::DiagnosticLoggingKeys::neverSeenBeforeKey(), WebCore::ShouldSample::Yes); 226 226 markAsRequested(hash); 227 227 } … … 261 261 String diagnosticKey = storeDecisionToDiagnosticKey(storeDecision.value()); 262 262 LOG(NetworkCache, "(NetworkProcess) webPageID %" PRIu64 ": %s was previously request but is not in the cache, reason: %s", webPageID, requestURL.string().ascii().data(), diagnosticKey.utf8().data()); 263 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::notInCacheKey(), diagnosticKey, WebCore::ShouldSample::Yes);263 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheFailureReasonKey(), diagnosticKey, WebCore::ShouldSample::Yes); 264 264 } else { 265 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::requestKey(), WebCore::DiagnosticLoggingKeys::neverSeenBeforeKey(), WebCore::ShouldSample::Yes);265 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheFailureReasonKey(), WebCore::DiagnosticLoggingKeys::neverSeenBeforeKey(), WebCore::ShouldSample::Yes); 266 266 markAsRequested(hash); 267 267 } … … 298 298 if (decision == UseDecision::Validate) { 299 299 LOG(NetworkCache, "(NetworkProcess) webPageID %" PRIu64 ": %s is in the cache but needs revalidation", webPageID, requestURL.string().ascii().data()); 300 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::retrievalKey(), WebCore::DiagnosticLoggingKeys::needsRevalidationKey(), WebCore::ShouldSample::Yes);300 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::needsRevalidationKey(), WebCore::ShouldSample::Yes); 301 301 return; 302 302 } … … 304 304 String diagnosticKey = cachedEntryReuseFailureToDiagnosticKey(decision); 305 305 LOG(NetworkCache, "(NetworkProcess) webPageID %" PRIu64 ": %s is in the cache but wasn't used, reason: %s", webPageID, requestURL.string().ascii().data(), diagnosticKey.utf8().data()); 306 NetworkProcess::singleton().logDiagnosticMessage WithValue(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheKey(), WebCore::DiagnosticLoggingKeys::unusableCachedEntryKey(), diagnosticKey, WebCore::ShouldSample::Yes);306 NetworkProcess::singleton().logDiagnosticMessage(webPageID, WebCore::DiagnosticLoggingKeys::networkCacheReuseFailureKey(), diagnosticKey, WebCore::ShouldSample::Yes); 307 307 } 308 308 -
trunk/Source/WebKit2/UIProcess/WebBackForwardList.cpp
r208985 r211304 180 180 unsigned delta = m_entries.size() - targetIndex - 1; 181 181 String deltaValue = delta > 10 ? ASCIILiteral("over10") : String::number(delta); 182 m_page->logDiagnosticMessage WithValue(WebCore::DiagnosticLoggingKeys::backNavigationKey(), WebCore::DiagnosticLoggingKeys::deltaKey(), deltaValue, false /* shouldSample */);182 m_page->logDiagnosticMessage(WebCore::DiagnosticLoggingKeys::backNavigationDeltaKey(), deltaValue, false /* shouldSample */); 183 183 } 184 184 -
trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm
r211199 r211304 3128 3128 void WebPage::willStartUserTriggeredZooming() 3129 3129 { 3130 m_page->diagnosticLoggingClient().logDiagnosticMessage WithValue(DiagnosticLoggingKeys::webViewKey(), DiagnosticLoggingKeys::userKey(), DiagnosticLoggingKeys::zoomedKey(), ShouldSample::No);3130 m_page->diagnosticLoggingClient().logDiagnosticMessage(DiagnosticLoggingKeys::webViewKey(), DiagnosticLoggingKeys::userZoomActionKey(), ShouldSample::No); 3131 3131 m_userHasChangedPageScaleFactor = true; 3132 3132 }
Note:
See TracChangeset
for help on using the changeset viewer.