OK, so I know that WCF is supposed to replace dotNET remoting, yet I seem to fail to really grasp if WCF is a full replacement with more options, or if .NET remoting offers some features that are missing from WCF?
As the title hints at, I do not need any of that Web* stuff. The use case is having a C# desktop application expose an RPC-ish interface to make it possible for other programs to communicate with / control the application. Number of possible clients is probably < 10 and communication is exclusively local network.
I found this question that asks for something similar开发者_如何学Python, but this other question seems to imply that .NET-remoting can in fact be used in ways that WCF does not offer.
There's no concept of "marshal by reference" in WCF, by design. Whether marshal-by-reference is ever a good idea is another matter, but regardless it's a major .NET Remoting feature that doesn't exist in WCF.
Use WCF with the self-hosted option (within the desktop application). Expose net.tcp binary endpoints assuming all other clients are .NET.
Check the sample "Form Host" on the iDesign downloads page: http://www.idesign.net/idesign/DesktopDefault.aspx?tabindex=5&tabid=11
WCF is full replacement for .net remoting. Your scenario is perfectly valid for WCF. You will easily complete it after reading few tutorials. All the mentioned use cases are controversial, I see no reason in using remoting nowadays.
精彩评论