CoreWCF / CoreWCF/samples

NetTcp does not working

Aperta
#23 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
C#
Stelle
50
Fork
22
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

**Which sample is the bug for**
https://github.com/CoreWCF/samples/tree/main/Scenarios/Getting-Started-with-CoreWCF/NetCoreServer
https://github.com/CoreWCF/samples/tree/main/Scenarios/Getting-Started-with-CoreWCF/NetCoreClient

**Describe the bug**
When I tried to use NetTcpBindings I received an error:
**On the client side:**
There was no endpoint listening at net.tcp://localhost:8089/EchoService/netTcp that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
**On the server side:**
Now listening on: http://[::]:8088
Now listening on: https://[::]:8443
Now listening on: http://0.0.0.0:8089
Application started. Press Ctrl+C to shut down.
fail: Microsoft.AspNetCore.Server.Kestrel[0]
Unhandled exception while processing 0HMKKHCH4NHRG.
System.NullReferenceException: Object reference not set to an instance of an object.
at CoreWCF.Channels.Framing.FramingModeHandshakeMiddleware.OnConnectedCoreAsync(FramingConnection connection)
at CoreWCF.Channels.Framing.FramingModeHandshakeMiddleware.OnConnectedAsync(FramingConnection connection)
at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure.KestrelConnection.ExecuteAsync()

**To Reproduce**
Steps to reproduce the behavior:
1. Run NetCoreServer
2. Run NetCoreClient

**Expected behavior**
I should receive messages in consoles:
On the server side:
Received Hello World! from client!;
On the client site:
Hello World!

**Repo environment (please complete the following information):**
- OS: Windows 10 Pro 21H2
- Architecture x64
- .NET core 3.1
- Rider and Visual Studio

**Additional context**
Add any other context about the problem here.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia eseguendo gli esempi NetCoreServer e NetCoreClient collegati nell’issue nell’ambiente .NET Core 3.1 indicato. Poi esamina FramingModeHandshakeMiddleware.OnConnectedCoreAsync, dove si verifica la NullReferenceException lato server. Il lavoro è completato quando il client riceve “Hello World!” e il server registra “Received Hello World! from client!”.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
csharp
Ambito
networking
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.