Closed Bug 1494311 Opened 6 years ago Closed 5 years ago

Make mtransport API more IPC friendly

Categories

(Core :: WebRTC: Networking, enhancement, P2)

60 Branch
enhancement

Tracking

()

RESOLVED FIXED
mozilla67
Tracking Status
firefox67 --- fixed

People

(Reporter: bwc, Assigned: bwc)

References

Details

Attachments

(1 file, 1 obsolete file)

Once we have the mtransport API all in one place, and properly encapsulated, we should write webidl types for the parameters on this API. This will make the API a little cleaner, but more importantly, is a step toward exposing this API over IPC.
Blocks: 1494312
So webidl types are not inherently IPC-able, on further inspection. Still, there is some work we can do to make the mtransport API easier to surface via IPC.

* Use nsCString instead of std::string
* Use nsTArray instead of std::vector
* Use int instead of size_t?
Summary: Write webidl data types for mtransport API → Make mtransport API more IPC friendly
After fiddling with this a bit, RTCConfiguration does not look IPC-able, because RTCCertificate is not either. Probably should modify Init to take just the parts of RTCConfiguration it needs (which are IPC-able).
Also, ditching CandidateInfo in favor of longer param lists will avoid some work.
It seems that we have IPC support for std::string after all, but nobody has ever used it. No support for std::vector, however.
No longer blocks: 1494312
Blocks: socket-proc-webrtc
No longer blocks: socket-proc
As part of this, I'm also going to establish a base-class for both the STS-based and IPC-based implementations.
Attachment #9028423 - Attachment is obsolete: true

mt, while looking over the key serialization/deserialization stuff we talked about, let me know if you would prefer me to apply the various clang-format/clang-tidy fixes suggested by reviewbot; since we might be moving those functions to NSS, we might not want to mess with the formatting.

Flags: needinfo?(martin.thomson)

The requests that reviewbot makes are pretty easy to revert. I'd make it happy by preference. NSS runs a different formatter, so any changes will look different if the code moves.

Flags: needinfo?(martin.thomson)
Pushed by bcampen@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7ab42c7de77d
Making the mtransport API a little more IPC friendly, and establishing a proper base-class. r=mt,mjf
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla67
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: