NetTcp does not work with IIS using CoreWCF 1.4.0-preview1 and .NET Framework
- Dominant language
- C#
- Stars
- 1.8k
- Forks
- 320
- PR merge metrics
- No merged PRs in 30d
Description
Code Used:
https://github.com/jeanrp/CoreWCF-MRE-NetTcpBinding-With-IIS
IIS Site Config:

App Pool Advanced Settings:

Steps to reproduce:
- Publish the server in the repo above to IIS.
- Change the port in the client to match what is set in IIS since right now it is set to be the Server port, it has to be the same as the binding set be iis.
- Start IIS server
- Run the client in the repo above.
Error message:
Could not connect to net.tcp://localhost/Service.svc. The connection attempt lasted for a time span of 00:00:04.0846522. TCP error code 10061: No connection could be made because the target machine actively refused it [::1]:808.
Other things to take into account:
- It works fine with Kestrel.
- We also had a .NET 6 app running and it only worked when we had two endpoints, one HTTP and another NetTcp, and we had to wake up the server first with a http request, even though we're using AlwaysRunning in the App pool and Idle time out is set to zero in the app pool as well. But I think you mentioned that netTcp activation wasn't in in the release for 1.4.0.preview1 in the CoreWCF blog.
Contributor guide
Assessment
This issue has not been assessed yet.