"WebSocket is a web technology providing for bi-directional, full-duplex communications channels, over a single Transmission Control Protocol (TCP) socket." (Wikipedia, 2012) The WebSocket protocol has been standardized by the IETF as RFC 6455. (IETF, 2011)
Our WebSocket implementation process was started prior to RFC 6455 standardization. After it has announced, we finalized the implementation and started to test it under our systems. We are very happy to say that, we implemented very efficient solution for your large-scale problems.
Starting from the version 2.0, PokeIn supports Hybi00, Hybi10, Hybi17 and RFC 6455 WebSocket protocols and It doesn't require any special operating system edition or IIS, Apache version in order to run. This is really important because we don't force you to use some special version of a server software or any other 3rd party solution to make it work. We bring this feature under our current licensing system without any extra fee!
So, you just set the following properties in order to benefit from PokeIn's ASP.NET WebSocket feature;
This parameter's default value is -1 (Disabled) simply you need to give it a proper number. (like 3333) Please keep in mind that you should give an access right to this TCP port on your Firewall. (Inbound rules) In order to use port 80 for websocket connections you have two options (pick one); You can deploy your application onto IIS8 (using our PokeIn45 library) or Secondary ethernet interface on the same server (use its port 80). In case you use PokeIn45, only thing you need to define is 'CometSettings.ClientSocketURL' and proper PokeIn socket handler under web.config. Look below for details.
This parameter's default is "IPAddress.None" (Disabled) PokeIn WebSocket system, internally creates a powerful mirror server in order to manage the socket traffic. So, you just define a proper IP address for this server or just give the IP address of your web application. For example, to locally test your application, 127.0.0.1 will just work.
The value of this parameter by default "String.Empty" (No Origin Check) This is the security parameter to limit the callers. Lets say you have an application under http://domain.com and you don't want to receive a call from another domain or application. So, just assigning "domain.com" to this parameter will handle this task for you.
By default, client's websocket url is the same with server IP and defined port address. In case you have different scenarios, you may define another IP-Port combination like (http://IPADDRESS:Port) Please remember that the port must be available and accessible from firewall.
Comet Ajax & Sockets In Together!
You just set the above parameters and let PokeIn manages the connections for you. If a browser has WebSocket support, PokeIn uses it. Otherwise it manages the traffic over comet ajax. OR lets say there is a problem on browser's WebSocket support (buggy implementation) PokeIn handles it for you and it switches back to comet ajax automatically on that browser.
Cloud Compatible (Azure, EC2... )
Feel free to use PokeIn WebSocket with your cloud powered solutions.
Port 80 over PokeIn45
There are 2 simple changes you need to do on your project. The first one is to define socket handler's URL from CometSettings.ClientSocketURL and the second one is to define the socket handler under web.config.
Lets say we defined below handler under system.webServer/handlers (remember! the application pool must be configured to run under 'integradeMode')
<add name="PokeIn_Socket_Handler" verb="*" path="*.poke" type="PokeIn.Comet.PokeInWSHandler, PokeIn45" preCondition="integratedMode" requireAccess="Read" allowPathInfo="true"/>
CometSettings.ClientSocketURL must be something like 'yourdomain.com/socket.poke'
Notice, type is 'PokeIn45' instead 'PokeIn'
PokeIn supports all the 'standardized' security features by default. Moreover, it combines your ASP.NET session keys with the active socket connections and cross checks the identity of clients. Also, it prevents other applications to connect your web application's socket port.
Hope you like our WebSocket feature.