Remoting - Retrieving a server pre-created object on the client
-
Hello experts, I'm using the
System.Runtime.Remoting.Channels.Ipc
namespace, and other remoting-related classes to communicate between instances of my app. I have registered a class using theRemotingConfiguration.RegisterWellKnownServiceType()
method, specifyingWellKnownObjectMode.Singleton
. AFAIK, normally, the server automatically creates an instance of the object when the first request for the object is made, and for any request which follows, only returns references to it. What I would like to do, is to be able to create the first instance myself, and have the clients requesting the object receive the reference to MY object. Is it possible? How? Hope I made myself clear enough... :) Thanks in advance, Shy. -
Hello experts, I'm using the
System.Runtime.Remoting.Channels.Ipc
namespace, and other remoting-related classes to communicate between instances of my app. I have registered a class using theRemotingConfiguration.RegisterWellKnownServiceType()
method, specifyingWellKnownObjectMode.Singleton
. AFAIK, normally, the server automatically creates an instance of the object when the first request for the object is made, and for any request which follows, only returns references to it. What I would like to do, is to be able to create the first instance myself, and have the clients requesting the object receive the reference to MY object. Is it possible? How? Hope I made myself clear enough... :) Thanks in advance, Shy. -
Hello experts, I'm using the
System.Runtime.Remoting.Channels.Ipc
namespace, and other remoting-related classes to communicate between instances of my app. I have registered a class using theRemotingConfiguration.RegisterWellKnownServiceType()
method, specifyingWellKnownObjectMode.Singleton
. AFAIK, normally, the server automatically creates an instance of the object when the first request for the object is made, and for any request which follows, only returns references to it. What I would like to do, is to be able to create the first instance myself, and have the clients requesting the object receive the reference to MY object. Is it possible? How? Hope I made myself clear enough... :) Thanks in advance, Shy.Hello! The
RemotingServices.Marshal()
method does exactly this - it publishes a given instance of an object as remoting server.Regards, mav -- Black holes are the places where God divided by 0...
-
Hello! The
RemotingServices.Marshal()
method does exactly this - it publishes a given instance of an object as remoting server.Regards, mav -- Black holes are the places where God divided by 0...
Thanks a bunch! Greatly appreciated! Wow... there are times I tell myself "Microsoft are really f***ed-up for not having an implementation for this and that in the .NET framework." But then there are times I think the .NET framework contains everything a programmer needs... :) Regards, Shy.