CoreWCF / CoreWCF/CoreWCF

NetTcp does not work with IIS using CoreWCF 1.4.0-preview1 and .NET Framework

Open
#1,084 8 comments 0 reactions 0 assignees View on GitHub
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:
![image](https://user-images.githubusercontent.com/5658790/235777979-60e5bc9f-c2e5-4934-b43e-3574b1083c4e.png)

App Pool Advanced Settings:
![image](https://user-images.githubusercontent.com/5658790/235778172-32779002-7c40-49e8-a586-97ed2991c58a.png)

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

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.