While WebSocket is a standardized protocol which offers full-duplex communication and serves as a key to building efficient real-time web interactions, and supported by all the major browsers as well as Web servers. Azure Web PubSub will enable developers to use WebSockets and the publish-subscribe pattern to build real-time web applications, including live real-time location on maps, monitoring dashboards, cross-platform live chat, and many more.
How Azure Web PubSub will enable developers to use WebSockets and a publish-subscribe pattern?
The implementation of a WebSocket-based real-time experience demands that a developer would first have to set up infrastructure for handling client connections, and ensure the setup would be able to meet business SLA requirements by establishing mechanisms to scale it on demand. And this infrastructure management tasks leaves a developer no time to focus on end-user experiences, which Azure Web PubSub service wants to solve this infrastructure challenge issue.
Azure Web PubSub service offers built-in support for large-scale client connections with highly available architectures so that developers can focus on the application logic that delivers real-time connected experiences.
Additionally, the service supports a wide variety of programming languages such as C#, Python, and Java through WebSocket APIs, which gives developers the flexibility to build real-time cross-platform applications, and also to easily migrate their existing WebSocket-based applications. Besides the native WebSocket support, it also offers the json.webpubsub.azure.v1 subprotocol, which enables clients to do publish-subscribe effectively without routing data between service and backend server code.
How to Get Started with Azure Web PubSub?
The Azure Web PubSub service is currently available as a developer preview, therefore to get started with Azure Web PubSub, developers should go to docs.microsoft.com and to learn more about the service, visit the Azure Web PubSub service page, or check out the preview documentation.
However, you'll need a free Azure account and follow this Quickstart using the free tier or standard tier of Azure Web PubSub. The free tier is designed for dev/test so that you can easily get started with one unit and create applications with up to 20 connections per unit and 20,000 messages per unit per day. Also, check out some code samples here that showcases real-time apps you can build with the service.