Why Remoting is so painful?
Yes, I know, 2003 called and asked to get its distribution technology back. Nevertheless, remoting is an extremely useful tool, if you can make several assumptions about the way that you are going to use it.
In my case, I am assuming inter process, local machine configuration, with high expectation of reliability from both ends. Considering that I also need low latency, it seems like an appropriate solution indeed. I was pretty happy about this, until all my integration tests start to break.
After a while, I managed to figure out that the root cause for that is this error: Because of security restrictions, the type XYZ cannot be accessed.
Now, it worked, and it worked for a long time. What the hell is going on?
After thinking about this for a while, I realized that the major thing that changed was that I am now signing my assemblies. And that caused all hell to break lose. I managed to find this post with the solution, but I am still not happy. I really dislike things that can just go and break on me.
Comments
Woa, in which case you dislike every single piece of...anything?
You'll have to stick to certain elementary particles. The electron is deemed quite stable and doesn't seem to have any motivation to just break.
Urgh! Why not WCF with named pipes or something?
Doesn't WCF have better support for remoting? Especially locally?
Frank: electrons have a catastrophic failure mode in the presence of positrons.
Chris, you're right, I forgot.
Sorry Ayende. Let's make this an...observation then: For every thing in our reality there is some other thing that will make the first thing break.
The implementation of code-level security in .Net is like black magic to me, and my brain is totally resistant to it. I don't know anyone using it for any purpose, even no one who can tell where it could be sensibly used. The only option - give your code all possible permissions and pray it works.
And .Net remoting - very nice at the beginning and ready to bite you when your application grows more complicated. Maybe WCF is better, but I'm afraid it's just a bit more painful than remoting
I would just use named pipes, assuming .NET 3.5 and the interaction was simple. Its worked well for me. blogs.msdn.com/.../...pipes-justin-van-patten.aspx
So... does that mean we can expect Rhino.Remoting soon? What interface would you use? Erlang-style message passing or RPC-style function calls.
I think next version of C# will look like javascript and we'll use JSON for remoting. Microsoft must only realize that they need to get rid of compiler, static typing, generics, WCF/WF and all that disturbing sh*t and concentrate on making the framework easy to use.
Comment preview