moebius#158: The Performance Resource Timing (added support for "workerStart")

https://github.com/MoonchildProductions/moebius/pull/158
This commit is contained in:
janekptacijarabaci 2018-04-29 11:49:50 +02:00 committed by Roy Tam
commit 6885700c5b
26 changed files with 746 additions and 70 deletions

View file

@ -130,7 +130,13 @@ HttpChannelParent::Init(const HttpChannelCreationArgs& aArgs)
a.initialRwin(), a.blockAuthPrompt(),
a.suspendAfterSynthesizeResponse(),
a.allowStaleCacheContent(), a.contentTypeHint(),
a.channelId(), a.contentWindowId(), a.preferredAlternativeType());
a.channelId(), a.contentWindowId(), a.preferredAlternativeType(),
a.launchServiceWorkerStart(),
a.launchServiceWorkerEnd(),
a.dispatchFetchEventStart(),
a.dispatchFetchEventEnd(),
a.handleFetchEventStart(),
a.handleFetchEventEnd());
}
case HttpChannelCreationArgs::THttpChannelConnectArgs:
{
@ -329,7 +335,13 @@ HttpChannelParent::DoAsyncOpen( const URIParams& aURI,
const nsCString& aContentTypeHint,
const nsCString& aChannelId,
const uint64_t& aContentWindowId,
const nsCString& aPreferredAlternativeType)
const nsCString& aPreferredAlternativeType,
const TimeStamp& aLaunchServiceWorkerStart,
const TimeStamp& aLaunchServiceWorkerEnd,
const TimeStamp& aDispatchFetchEventStart,
const TimeStamp& aDispatchFetchEventEnd,
const TimeStamp& aHandleFetchEventStart,
const TimeStamp& aHandleFetchEventEnd)
{
nsCOMPtr<nsIURI> uri = DeserializeURI(aURI);
if (!uri) {
@ -534,6 +546,13 @@ HttpChannelParent::DoAsyncOpen( const URIParams& aURI,
mChannel->SetInitialRwin(aInitialRwin);
mChannel->SetBlockAuthPrompt(aBlockAuthPrompt);
mChannel->SetLaunchServiceWorkerStart(aLaunchServiceWorkerStart);
mChannel->SetLaunchServiceWorkerEnd(aLaunchServiceWorkerEnd);
mChannel->SetDispatchFetchEventStart(aDispatchFetchEventStart);
mChannel->SetDispatchFetchEventEnd(aDispatchFetchEventEnd);
mChannel->SetHandleFetchEventStart(aHandleFetchEventStart);
mChannel->SetHandleFetchEventEnd(aHandleFetchEventEnd);
nsCOMPtr<nsIApplicationCacheChannel> appCacheChan =
do_QueryObject(mChannel);
nsCOMPtr<nsIApplicationCacheService> appCacheService =
@ -1159,7 +1178,7 @@ HttpChannelParent::OnStartRequest(nsIRequest *aRequest, nsISupports *aContext)
nsCString secInfoSerialization;
UpdateAndSerializeSecurityInfo(secInfoSerialization);
uint16_t redirectCount = 0;
uint8_t redirectCount = 0;
chan->GetRedirectCount(&redirectCount);
nsCOMPtr<nsISupports> cacheKey;