WebSocket, introduced of as part of HTML5, defines a full-duplex single socket connection over which messages can be sent between client and server.
WebSocket is not just another enhancement to HTTP. The WebSocket standard simplifies much of the complexity around bi-directional web communication and connection management.
While the client side coding is fairly straight forward, implementing WebSockets on some development platforms involves writing a large amount of code just to provide basic functionality. A lot of the functionality could and should be provided by the framework, leaving you to focus on your application.
There are several WebSocket server implementations. Here are are few that may help meet your needs.
Microsoft has implemented WebSocket on different places in Windows 8 and .NET 4.5 Stack. These include an implementation for WCF and one for ASP.NET and another with SignalR.
Each has trade-offs.
In this post, you’ll get an overall understanding on how you can get started on several platforms. I’ll provide an overview where you can get started should you want to build your own framework in WCF and ASP.NET.
And I’ll implement the echo service that will work with the client in my previous post using Microsoft.WebSockets.
Continue reading “HTML5 Tutorial – WebSocket Server (on ASP.NET)”