0

I was reading this article about WCF Websockets, and there is a nice example of a WebSocket service using Microsoft.ServiceModel.WebSockets.WebSocketService, that looks perfect for a thing I want to do, clean and simple.

First of all, I have found it in a NuGet package named Microsoft.WebSockets, but it is from 2012 and states:

This preview package provides functionality for writing WebSocket-enabled server applications on Windows 8 using ASP.NET and WCF. Requires .NET 4.5 RC and Windows 8 RC.

So it seems a little bit out of date. Is it deprecated/abandoned or anything?

Also, I would like to use it to create a standalone Windows service that handles the connections from browsers, but I cannot find how to host it. The example shows how to do it in IIS, but I cannot find information at all about how to host it in a Console or Windows service application.

Any idea about how to use it?

Cheers.

vtortola
  • 34,709
  • 29
  • 161
  • 263
  • I have posted answer to the similar topic: [WCF self-hosted WebSocket Service with Javascript client](http://stackoverflow.com/questions/24239953/wcf-self-hosted-websocket-service-with-javascript-client/26527058) Hope it will help. – Amid Oct 23 '14 at 12:03

1 Answers1

1

I believe WebSockets are included in .NET 4.5 in the System.Net.WebSockets namespace.

Hopefully this will point you in the right direction:

Using WebSockets in .NET 4.5 Part 3 (WCF)

Kasey Speakman
  • 4,511
  • 2
  • 32
  • 41