Closed Bug 976692 Opened 7 years ago Closed 7 years ago

WebRTC IdP caching

Categories

(Core :: WebRTC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla31

People

(Reporter: mt, Assigned: mt)

References

Details

Attachments

(1 file, 1 obsolete file)

Attached patch 0001-Adding-IdP-caching.patch (obsolete) — Splinter Review
When we create an IdP proxy, we create a new one for validation and generation, even if the IdP is the same.  That's OK; we still rely on caching for the content and it isolates the state for the two.

What is bad is that we recreate the IdP proxy every time this process is triggered.  That is, if someone calls setIdentityProvider a second time, we create another proxy and discard the first.  That's wasteful, especially if the IdP is warmed up in the meantime.

Patch attached.
Attachment #8381587 - Flags: review?(ekr)
Assignee: nobody → martin.thomson
Unbitrotting, getting dependencies sorted out
Attachment #8381587 - Attachment is obsolete: true
Attachment #8381587 - Flags: review?(ekr)
Comment on attachment 8393834 [details] [diff] [review]
0001-Bug-976692-Adding-IdP-caching.patch

Review of attachment 8393834 [details] [diff] [review]:
-----------------------------------------------------------------

lgtm.

::: dom/media/IdpProxy.jsm
@@ +160,5 @@
>      this.pending = [];
>    },
>  
> +  isSame: function(domain, protocol) {
> +    return this.domain === domain && ((protocol || "default") === this.protocol);

== is preferred over ===.
Attachment #8393834 - Flags: review+
Depends on: 970606
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/e06949379961
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla31
You need to log in before you can comment on or make changes to this bug.