CoreWCF is here! For those that don’t know, this was a community project which ported WCF (Windows Communications Foundation) to .NET Core and beyond. This release is very important because it means you can start to leverage CoreWCF in your existing .NET Framework projects to ease modernization of your applications and migrate to Core in the future.
CoreWCF is compatible with .NET Standard 2.0 which means it supports .NET Framework 4.6.2+, .NET Core 3.1 and .NET 5 and 6. Not all features made it over, however the CoreWCF team believes the most used features are in attendance. As explained by Sam Spencer Program Manager from the .NET Core team these include:
- Http & NetTCP transports
- NetTcpBinding – some WS-* features not supported
- WSHttpBinding – some WS-* features not supported
- NetTcpBinding supports Certificate and Windows authentication
- Http bindings require authentication to be configured in ASP.NET Core
- Transport With Message Credentials
- Username, Certificate and Windows Authentication are supported
- WS Federation
- WSDL generation
- Partial configuration support including services & endpoints
- Extensibility (IServiceBehavior and IEndpointBehavior) – most extensibility is available
Who should be using CoreWCF
CoreWCF is intended for projects already using WCF on .NET Framework and have been held back from upgrading to .NET Core or .NET 5 and 6 due to lack of WCF support. The team explains that while nothing is stopping you from using CoreWCF for a new project, their suggestion is to go with something like gRPC instead.
Getting Started and More
To get started with CoreWCF check out this great getting started guide in the official blog post form Microsoft. I’ve already followed the steps outlined in the post and they work like a charm. You can also check out this awesome video from James Montemagno to learn more:
As always let us know your thoughts on this, have you been dreading upgrading a project because you’d have to rebuild your WCF layer? Would this help you get the project modernized? Sound off in the comments below!