duplex-channel

WCF: How to diagnose faulted channels?

丶灬走出姿态 提交于 2019-12-10 17:00:55
问题 I'm working on shipping in a change for my lab that will hopefully help diagnose some weird channel-faulting weirdness we're seeing. There's a test application that uses DuplexChannelFactory to connect to a couple windows services, and for some reason the channels on this test application seem to be faulting quite a bit. I have plans to implement some retry logic in there, but it would be great to figure out why exactly they're faulting. I know that channel factories and proxy objects all

How do I correctly configure a WCF NetTcp Duplex Reliable Session?

只谈情不闲聊 提交于 2019-12-09 05:19:06
问题 Please excuse the Obvious Self-Q/A, but this information is widely misunderstood, and almost always incorrectly answered. So I Wanted to place this information here for people searching for a definitive answer to this problem. Even so, there's still some information I haven't been able to nail down. I will put this towards the end of the question (skip to that if you are not interested in the preamble). How do I correctly configure a WCF NetTcp Duplex Reliable Session? There are many

WCF Duplex Channel: Check if callback channel is still available

懵懂的女人 提交于 2019-12-08 00:52:07
问题 I have the following problem. I'm writing chat software. The client/server mechanism is based on DualHttpBinding of WCF. This means that if a user sends a message, all clients that are in the room where the message has been sent, are notified by the server. I want to ensure, that if a client's application crashes (whyever), the client object is removed from the rooms' lists. Is there a possibility to check the callback channel's state before calling a callback operation? The problem is, that

Duplex channel Faulted event does not rise on second connection attempt

血红的双手。 提交于 2019-12-06 11:39:22
问题 I have regular net.tcp WCF service client, and regular net.tcp duplex (i.e. with a callback) WCF service client. I have implemented some logic to constantly reinstantiate the connection in case a service has faulted. They are created in the exactly same way: FooServiceClient Create() { var client = new FooServiceClient(ChannelBinding); client.Faulted += this.FaultedHandler; client.Ping(); // An empty service function to make sure connection is OK return client; } BarServiceClient Create() {

WCF Duplex Channel: Check if callback channel is still available

此生再无相见时 提交于 2019-12-06 06:13:09
I have the following problem. I'm writing chat software. The client/server mechanism is based on DualHttpBinding of WCF. This means that if a user sends a message, all clients that are in the room where the message has been sent, are notified by the server. I want to ensure, that if a client's application crashes (whyever), the client object is removed from the rooms' lists. Is there a possibility to check the callback channel's state before calling a callback operation? The problem is, that if i call an operation on a client which is not anymore connected (because of an unexpected crash), the

Duplex channel Faulted event does not rise on second connection attempt

左心房为你撑大大i 提交于 2019-12-04 17:09:29
I have regular net.tcp WCF service client, and regular net.tcp duplex (i.e. with a callback) WCF service client. I have implemented some logic to constantly reinstantiate the connection in case a service has faulted. They are created in the exactly same way: FooServiceClient Create() { var client = new FooServiceClient(ChannelBinding); client.Faulted += this.FaultedHandler; client.Ping(); // An empty service function to make sure connection is OK return client; } BarServiceClient Create() { var duplexClient = new BarServiceClient(new InstanceContext(this.barServiceCallback)); duplexClient

How do I correctly configure a WCF NetTcp Duplex Reliable Session?

坚强是说给别人听的谎言 提交于 2019-12-03 05:42:25
Please excuse the Obvious Self-Q/A, but this information is widely misunderstood, and almost always incorrectly answered. So I Wanted to place this information here for people searching for a definitive answer to this problem. Even so, there's still some information I haven't been able to nail down. I will put this towards the end of the question (skip to that if you are not interested in the preamble). How do I correctly configure a WCF NetTcp Duplex Reliable Session? There are many questions and answers regarding this topic, and nearly all of them suggest setting inactivityTimeout="Infinite"