Vagata wrote about how working on the project with Firefox parent Mozilla enabled the social network to take advantage of HTML5 standards including WebSocket and Shared Worker in order to “architect our messaging stack from the ground up to be fast and efficient.” She added:
Historically, Web developers have worked around the limitations of Web standards by polling servers for updates via asynchronous requests. These asynchronous requests are somewhat expensive because the client-server has to perform some handshaking on each poll. HTML5 introduces a new application-programming interface, WebSocket, which addresses these issues by keeping a client-server connection alive and only requiring the hit of handshaking at the time of opening the connection.
In our first stand-alone chat product, Messenger for Desktop could rely on assumptions such as having at most one instance of the product open at any given time, and being able to create invisible windows which could perform data fetching without rendering until necessary. In Mozilla’s Social API, however, the notion of invisible windows was replaced with an implementation of the HTML5 Shared Worker. This worker provides a mechanism for communicating and synchronizing across the different content elements for the product.
Our ability to work with a small team and push code on a daily basis meant we could rapidly iterate on the API design and feature work to get this integration into the wild. It has been awesome getting to work with the latest and greatest HTML5 technologies, as well as the talented developers at Facebook and Mozilla.