[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-10851-g50815da
commit-queue at webkit.org
commit-queue at webkit.org
Wed Dec 22 18:45:23 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 1eae3f25ebd979cd8b057741560840c234d26edc
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Dec 17 10:37:55 2010 +0000
2010-12-17 James Simonsen <simonjam at chromium.org>
Reviewed by Darin Fisher.
[Web Timing] Add sslHandshakeStart to interface
https://bugs.webkit.org/show_bug.cgi?id=50400
* fast/dom/Window/window-properties-performance-expected.txt: Added sslHandshakeStart.
* fast/dom/script-tests/webtiming.js: Ditto.
(checkTimingBeforeLoad):
(checkTimingWhileDeferred):
(checkWebTimingOnDOMContentLoaded):
(checkWebTimingWhileAsync):
(checkWebTimingOnLoad):
(checkWebTimingAfterLoad):
* fast/dom/webtiming-document-open-expected.txt: Ditto.
* fast/dom/webtiming-expected.txt: Ditto.
* fast/dom/webtiming-navigate-within-document-expected.txt: Ditto.
* http/tests/misc/resources/webtiming-ssl.html: Added.
* http/tests/misc/webtiming-ssl-expected.txt: Added.
* http/tests/misc/webtiming-ssl.php: Added.
* platform/gtk/Skipped: WebTiming disabled here.
* platform/mac/Skipped: Ditto.
* platform/win/Skipped: Ditto.
2010-12-17 James Simonsen <simonjam at chromium.org>
Reviewed by Darin Fisher.
[Web Timing] Add sslHandshakeStart to interface
https://bugs.webkit.org/show_bug.cgi?id=50400
Test: http/tests/misc/webtiming-ssl.php
* page/PerformanceTiming.cpp:
(WebCore::PerformanceTiming::connectStart): Update comment.
(WebCore::PerformanceTiming::connectEnd): Remove SSL time.
(WebCore::PerformanceTiming::sslHandshakeStart): Added.
* page/PerformanceTiming.h: Added sslHandshakeStart.
* page/PerformanceTiming.idl: Ditto.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@74242 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 26e07a9..1b1c280 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -2,6 +2,32 @@
Reviewed by Darin Fisher.
+ [Web Timing] Add sslHandshakeStart to interface
+
+ https://bugs.webkit.org/show_bug.cgi?id=50400
+
+ * fast/dom/Window/window-properties-performance-expected.txt: Added sslHandshakeStart.
+ * fast/dom/script-tests/webtiming.js: Ditto.
+ (checkTimingBeforeLoad):
+ (checkTimingWhileDeferred):
+ (checkWebTimingOnDOMContentLoaded):
+ (checkWebTimingWhileAsync):
+ (checkWebTimingOnLoad):
+ (checkWebTimingAfterLoad):
+ * fast/dom/webtiming-document-open-expected.txt: Ditto.
+ * fast/dom/webtiming-expected.txt: Ditto.
+ * fast/dom/webtiming-navigate-within-document-expected.txt: Ditto.
+ * http/tests/misc/resources/webtiming-ssl.html: Added.
+ * http/tests/misc/webtiming-ssl-expected.txt: Added.
+ * http/tests/misc/webtiming-ssl.php: Added.
+ * platform/gtk/Skipped: WebTiming disabled here.
+ * platform/mac/Skipped: Ditto.
+ * platform/win/Skipped: Ditto.
+
+2010-12-17 James Simonsen <simonjam at chromium.org>
+
+ Reviewed by Darin Fisher.
+
[Web Timing] Navigation type enums should begin with TYPE_
https://bugs.webkit.org/show_bug.cgi?id=51200
diff --git a/LayoutTests/fast/dom/Window/window-properties-performance-expected.txt b/LayoutTests/fast/dom/Window/window-properties-performance-expected.txt
index 1b608cb..7a71c4f 100644
--- a/LayoutTests/fast/dom/Window/window-properties-performance-expected.txt
+++ b/LayoutTests/fast/dom/Window/window-properties-performance-expected.txt
@@ -30,6 +30,7 @@ window.webkitPerformance.timing.redirectStart [number]
window.webkitPerformance.timing.requestStart [number]
window.webkitPerformance.timing.responseEnd [number]
window.webkitPerformance.timing.responseStart [number]
+window.webkitPerformance.timing.sslHandshakeStart [number]
window.webkitPerformance.timing.unloadEventEnd [number]
window.webkitPerformance.timing.unloadEventStart [number]
diff --git a/LayoutTests/fast/dom/script-tests/webtiming.js b/LayoutTests/fast/dom/script-tests/webtiming.js
index 29d60a5..16cb83d 100644
--- a/LayoutTests/fast/dom/script-tests/webtiming.js
+++ b/LayoutTests/fast/dom/script-tests/webtiming.js
@@ -34,6 +34,8 @@ function checkTimingBeforeLoad()
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
@@ -67,6 +69,8 @@ function checkTimingWhileDeferred()
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
@@ -101,8 +105,10 @@ function checkWebTimingOnDOMContentLoaded() {
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
-
+
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
shouldBeGreaterThanOrEqual("timing.domLoading", "timing.fetchStart");
@@ -141,6 +147,8 @@ function checkWebTimingWhileAsync()
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
@@ -176,6 +184,8 @@ function checkWebTimingOnLoad()
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
@@ -212,6 +222,8 @@ function checkWebTimingAfterLoad()
shouldBeGreaterThanOrEqual("timing.connectStart", "timing.domainLookupEnd");
shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.connectStart");
+ shouldBe("timing.sslHandshakeStart", "0");
+
shouldBeGreaterThanOrEqual("timing.requestStart", "timing.connectEnd");
shouldBeGreaterThanOrEqual("timing.responseStart", "timing.requestStart");
diff --git a/LayoutTests/fast/dom/webtiming-document-open-expected.txt b/LayoutTests/fast/dom/webtiming-document-open-expected.txt
index fcb12e6..f2d05d6 100644
--- a/LayoutTests/fast/dom/webtiming-document-open-expected.txt
+++ b/LayoutTests/fast/dom/webtiming-document-open-expected.txt
@@ -21,6 +21,7 @@ PASS timing.redirectStart is originalTiming.redirectStart
PASS timing.requestStart is originalTiming.requestStart
PASS timing.responseEnd is originalTiming.responseEnd
PASS timing.responseStart is originalTiming.responseStart
+PASS timing.sslHandshakeStart is originalTiming.sslHandshakeStart
PASS timing.unloadEventEnd is originalTiming.unloadEventEnd
PASS timing.unloadEventStart is originalTiming.unloadEventStart
PASS successfullyParsed is true
diff --git a/LayoutTests/fast/dom/webtiming-expected.txt b/LayoutTests/fast/dom/webtiming-expected.txt
index 67799a9..4d832ba 100644
--- a/LayoutTests/fast/dom/webtiming-expected.txt
+++ b/LayoutTests/fast/dom/webtiming-expected.txt
@@ -14,6 +14,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.domLoading is >= timing.fetchStart
@@ -34,6 +35,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.domLoading is >= timing.fetchStart
@@ -54,6 +56,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.domLoading is >= timing.fetchStart
@@ -74,6 +77,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.domLoading is >= timing.fetchStart
@@ -94,6 +98,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.responseEnd is >= timing.responseStart
@@ -115,6 +120,7 @@ PASS timing.domainLookupStart is >= timing.fetchStart
PASS timing.domainLookupEnd is >= timing.domainLookupStart
PASS timing.connectStart is >= timing.domainLookupEnd
PASS timing.connectEnd is >= timing.connectStart
+PASS timing.sslHandshakeStart is 0
PASS timing.requestStart is >= timing.connectEnd
PASS timing.responseStart is >= timing.requestStart
PASS timing.responseEnd is >= timing.responseStart
diff --git a/LayoutTests/fast/dom/webtiming-navigate-within-document-expected.txt b/LayoutTests/fast/dom/webtiming-navigate-within-document-expected.txt
index d49ea0f..7d61e43 100644
--- a/LayoutTests/fast/dom/webtiming-navigate-within-document-expected.txt
+++ b/LayoutTests/fast/dom/webtiming-navigate-within-document-expected.txt
@@ -21,6 +21,7 @@ PASS redirectStart is unchanged.
PASS requestStart is unchanged.
PASS responseEnd is unchanged.
PASS responseStart is unchanged.
+PASS sslHandshakeStart is unchanged.
PASS unloadEventEnd is unchanged.
PASS unloadEventStart is unchanged.
PASS successfullyParsed is true
diff --git a/LayoutTests/http/tests/misc/resources/webtiming-ssl.html b/LayoutTests/http/tests/misc/resources/webtiming-ssl.html
new file mode 100644
index 0000000..72dcc2c
--- /dev/null
+++ b/LayoutTests/http/tests/misc/resources/webtiming-ssl.html
@@ -0,0 +1,27 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<script>
+</script>
+<link rel="stylesheet" href="../../js-test-resources/js-test-style.css">
+<script src="../../js-test-resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script>
+description("This test checks that Web Timing reports sslHandshakeStart correctly and has reasonable values for connectStart and connectEnd. Note that DumpRenderTree doesn't set sslHandshakeStart.");
+
+var performance = window.webkitPerformance || {};
+var navigation = performance.navigation || {};
+var timing = performance.timing || {};
+
+shouldBeGreaterThanOrEqual("timing.connectStart", "timing.navigationStart");
+shouldBeGreaterThanOrEqual("timing.sslHandshakeStart", "timing.connectStart");
+shouldBeGreaterThanOrEqual("timing.connectEnd", "timing.sslHandshakeStart");
+
+var successfullyParsed = true;
+</script>
+<script src="../../js-test-resources/js-test-post.js"></script>
+</body>
+</html>
diff --git a/LayoutTests/http/tests/misc/webtiming-ssl-expected.txt b/LayoutTests/http/tests/misc/webtiming-ssl-expected.txt
new file mode 100644
index 0000000..213444e
--- /dev/null
+++ b/LayoutTests/http/tests/misc/webtiming-ssl-expected.txt
@@ -0,0 +1,11 @@
+This test checks that Web Timing reports sslHandshakeStart correctly and has reasonable values for connectStart and connectEnd. Note that DumpRenderTree doesn't set sslHandshakeStart.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS timing.connectStart is >= timing.navigationStart
+FAIL timing.sslHandshakeStart should be >= timing.connectStart. Was 0 (of type number).
+PASS timing.connectEnd is >= timing.sslHandshakeStart
+PASS successfullyParsed is true
+
+TEST COMPLETE
diff --git a/LayoutTests/http/tests/misc/webtiming-ssl.php b/LayoutTests/http/tests/misc/webtiming-ssl.php
new file mode 100644
index 0000000..0fe579d
--- /dev/null
+++ b/LayoutTests/http/tests/misc/webtiming-ssl.php
@@ -0,0 +1,4 @@
+<?php
+ header('Location: https://127.0.0.1:8443/misc/resources/webtiming-ssl.html');
+ header('HTTP/1.0 302 Found');
+?>
diff --git a/LayoutTests/platform/gtk/Skipped b/LayoutTests/platform/gtk/Skipped
index 2ffc74f..853dce6 100644
--- a/LayoutTests/platform/gtk/Skipped
+++ b/LayoutTests/platform/gtk/Skipped
@@ -5311,6 +5311,7 @@ fast/dom/webtiming.html
fast/dom/webtiming-navigate-within-document.html
fast/dom/webtiming-document-open.html
http/tests/misc/webtiming-one-redirect.php
+http/tests/misc/webtiming-ssl.php
http/tests/misc/webtiming-two-redirects.php
# Accuracy problems in the results
diff --git a/LayoutTests/platform/mac/Skipped b/LayoutTests/platform/mac/Skipped
index f8c6d37..861ceac 100644
--- a/LayoutTests/platform/mac/Skipped
+++ b/LayoutTests/platform/mac/Skipped
@@ -219,6 +219,7 @@ fast/dom/webtiming.html
fast/dom/webtiming-document-open.html
fast/dom/webtiming-navigate-within-document.html
http/tests/misc/webtiming-one-redirect.php
+http/tests/misc/webtiming-ssl.php
http/tests/misc/webtiming-two-redirects.php
# Still working out flakiness issues with the perf tests.
diff --git a/LayoutTests/platform/win/Skipped b/LayoutTests/platform/win/Skipped
index 876092a..b20bd9e 100644
--- a/LayoutTests/platform/win/Skipped
+++ b/LayoutTests/platform/win/Skipped
@@ -1038,6 +1038,7 @@ fast/dom/webtiming.html
fast/dom/webtiming-document-open.html
fast/dom/webtiming-navigate-within-document.html
http/tests/misc/webtiming-one-redirect.php
+http/tests/misc/webtiming-ssl.php
http/tests/misc/webtiming-two-redirects.php
# Still working out flakiness issues with the perf tests.
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index b6b771a..5c9d29f 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -2,6 +2,23 @@
Reviewed by Darin Fisher.
+ [Web Timing] Add sslHandshakeStart to interface
+
+ https://bugs.webkit.org/show_bug.cgi?id=50400
+
+ Test: http/tests/misc/webtiming-ssl.php
+
+ * page/PerformanceTiming.cpp:
+ (WebCore::PerformanceTiming::connectStart): Update comment.
+ (WebCore::PerformanceTiming::connectEnd): Remove SSL time.
+ (WebCore::PerformanceTiming::sslHandshakeStart): Added.
+ * page/PerformanceTiming.h: Added sslHandshakeStart.
+ * page/PerformanceTiming.idl: Ditto.
+
+2010-12-17 James Simonsen <simonjam at chromium.org>
+
+ Reviewed by Darin Fisher.
+
[Web Timing] Navigation type enums should begin with TYPE_
https://bugs.webkit.org/show_bug.cgi?id=51200
diff --git a/WebCore/page/PerformanceTiming.cpp b/WebCore/page/PerformanceTiming.cpp
index 82b7027..d9139a9 100644
--- a/WebCore/page/PerformanceTiming.cpp
+++ b/WebCore/page/PerformanceTiming.cpp
@@ -184,7 +184,7 @@ unsigned long long PerformanceTiming::connectStart() const
if (connectStart < 0 || loader->response().connectionReused())
return domainLookupEnd();
- // ResourceLoadTiming's connect phase includes DNS and SSL, however Web Timing's
+ // ResourceLoadTiming's connect phase includes DNS, however Navigation Timing's
// connect phase should not. So if there is DNS time, trim it from the start.
if (timing->dnsEnd >= 0 && timing->dnsEnd > connectStart)
connectStart = timing->dnsEnd;
@@ -208,14 +208,26 @@ unsigned long long PerformanceTiming::connectEnd() const
if (connectEnd < 0 || loader->response().connectionReused())
return connectStart();
- // ResourceLoadTiming's connect phase includes DNS and SSL, however Web Timing's
- // connect phase should not. So if there is SSL time, trim it from the end.
- if (timing->sslStart >= 0 && timing->sslStart < connectEnd)
- connectEnd = timing->sslStart;
-
return resourceLoadTimeRelativeToAbsolute(connectEnd);
}
+unsigned long long PerformanceTiming::sslHandshakeStart() const
+{
+ DocumentLoader* loader = documentLoader();
+ if (!loader)
+ return 0;
+
+ ResourceLoadTiming* timing = loader->response().resourceLoadTiming();
+ if (!timing)
+ return 0;
+
+ int sslStart = timing->sslStart;
+ if (sslStart < 0)
+ return 0;
+
+ return resourceLoadTimeRelativeToAbsolute(sslStart);
+}
+
unsigned long long PerformanceTiming::requestStart() const
{
ResourceLoadTiming* timing = resourceLoadTiming();
diff --git a/WebCore/page/PerformanceTiming.h b/WebCore/page/PerformanceTiming.h
index 3b5e8b4..28553f3 100644
--- a/WebCore/page/PerformanceTiming.h
+++ b/WebCore/page/PerformanceTiming.h
@@ -61,6 +61,7 @@ public:
unsigned long long domainLookupEnd() const;
unsigned long long connectStart() const;
unsigned long long connectEnd() const;
+ unsigned long long sslHandshakeStart() const;
unsigned long long requestStart() const;
unsigned long long responseStart() const;
unsigned long long responseEnd() const;
diff --git a/WebCore/page/PerformanceTiming.idl b/WebCore/page/PerformanceTiming.idl
index a13b8d7..b258e48 100644
--- a/WebCore/page/PerformanceTiming.idl
+++ b/WebCore/page/PerformanceTiming.idl
@@ -42,6 +42,7 @@ module window {
readonly attribute unsigned long long domainLookupEnd;
readonly attribute unsigned long long connectStart;
readonly attribute unsigned long long connectEnd;
+ readonly attribute unsigned long long sslHandshakeStart;
readonly attribute unsigned long long requestStart;
readonly attribute unsigned long long responseStart;
readonly attribute unsigned long long responseEnd;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list