Answered by:
WCF : in netTcpBinding do we need to use keepalive message

Question
-
Hi
If we use netTcpBinding in WCF, do we need keep alive message from server to client, to keep client connection for longer or not?
by just enabling reliable session and making request and response timeouts to large is enough?
i am sending message from server to client in callback method to keep client alive and avoiding fault channel.
Monday, December 1, 2014 7:06 AM
Answers
-
Hello,
HTH
Thanks
please Mark as the Answer, If this answers your question. If this post is helpful, please vote as helpful.
- Proposed as answer by Amy PengMicrosoft employee Wednesday, December 3, 2014 6:16 AM
- Marked as answer by Amy PengMicrosoft employee Monday, December 8, 2014 3:00 AM
Monday, December 1, 2014 7:27 AM -
Hi Prabhakar26,
Based on your description, I know that you want to keep your TCP connection live as long as clients need it, then we can use the reliable session, but it will time out just like any other session. so if you want your sessions to be endless, you need to crank up the timeouts on the session.
Besides, the following threads may give your some idea:
#Does WCF NetTcpBinding provide a persistent connection:
http://stackoverflow.com/questions/12982026/does-wcf-nettcpbinding-provide-a-persistent-connection .#TCP Keep Alive connection hosted in WCF:
http://stackoverflow.com/questions/9891711/tcp-keep-alive-connection-hosted-in-wcf .Best Regards,
Amy PengWe are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- Marked as answer by Amy PengMicrosoft employee Monday, December 8, 2014 3:00 AM
Wednesday, December 3, 2014 6:15 AM
All replies
-
Hello,
HTH
Thanks
please Mark as the Answer, If this answers your question. If this post is helpful, please vote as helpful.
- Proposed as answer by Amy PengMicrosoft employee Wednesday, December 3, 2014 6:16 AM
- Marked as answer by Amy PengMicrosoft employee Monday, December 8, 2014 3:00 AM
Monday, December 1, 2014 7:27 AM -
Hi Prabhakar26,
Based on your description, I know that you want to keep your TCP connection live as long as clients need it, then we can use the reliable session, but it will time out just like any other session. so if you want your sessions to be endless, you need to crank up the timeouts on the session.
Besides, the following threads may give your some idea:
#Does WCF NetTcpBinding provide a persistent connection:
http://stackoverflow.com/questions/12982026/does-wcf-nettcpbinding-provide-a-persistent-connection .#TCP Keep Alive connection hosted in WCF:
http://stackoverflow.com/questions/9891711/tcp-keep-alive-connection-hosted-in-wcf .Best Regards,
Amy PengWe are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- Marked as answer by Amy PengMicrosoft employee Monday, December 8, 2014 3:00 AM
Wednesday, December 3, 2014 6:15 AM -
Thanks
So don't need to provide a dummy method in server.
presently i am using dummy method in server and calling from client to keep connection alive.
Friday, January 9, 2015 9:35 AM