Generic deserialization

From: Lee Gillie (ANTISPAMIFICATION_lee_at_odp.com)
Date: 06/29/04


Date: Tue, 29 Jun 2004 16:07:29 -0700

Trying to create a "generic" notification facility. Basically I have a
number of services which currently use NT MAILSLOTS to broadcast their
in-progress status to desktops on the LAN. In the mailslot there is
usually complex delimited data as a string.

My .NET approach is to instead use a "message server service". Also
attempting to provide a component that will make either SOURCE or
CONSUMER objects. The SOURCE object has one simple "Send" method, and
accepts a parameter of type "Object". Am making a "Consumer" object
which posts an event, and again, a single parameter of type OBJECT. I
am attempting to hide all the infrastructure and remoting as much as
possible, from the caller of the component. The component is also
exposing a COM interface. The component makes either a source or
consumer conversation with the service via one single remoted
component, which can "broadcast" events to clients. All of this works
great when the notify parameter is a string. But falls flat when
trying to do this with an item of type OBJECT.

Here is my extreme lack of knowledge about serialization...

Via the remoting method, I was able to send from a SOURCE to the
server, and it makes it back to the CONSUMER in a separate process.
But the consumer is having trouble looking at the "object". I get
this:

Run-time exception thrown :
System.Runtime.Remoting.RemotingException - This remoting proxy has no
channel sink which means either the server has no registered server
channels that are listening, or this application has no suitable
client channel to talk to the server.

The "object" being sent through this system is a "class" using only
fundamental data types, such as string, integer, and so on. The class
is marked serializable, and I found a need to inherit from MarshaByRef
to get the send side to work.

My thought is that once I get this class instance serialized, it is
completely self contained. Yet the message seems to indciate the
CONSUMER is somehow trying to get back to some remoting host, or such.
Probably due to the MBR.

Any hints on preparing my generic "object" parameter to be fully
self-sufficient would be greatly appreciated. In my component I don't
have knowledge of my caller's classes. If I can, I would like to not
burden my caller to perform serialization and deserialization, if
possible.

Can what I am trying to do even be done?



Relevant Pages

  • Re: Generic deserialization
    ... When the consumer gets the reference ... The issue is that you indicated that you don't your message server service ... the SourceWrapper handles the serialization and the ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: Generic deserialization
    ... When the consumer gets the ... > The issue is that you indicated that you don't your message server ... > server service classes, ... the SourceWrapper handles the serialization and the ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: Any caching in remoting?
    ... > I have a question related to any caching mechanisms in remoting. ... > service provider are located in the same IIS server. ... > serialization process if an object was already serialized? ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: .NET Remoting slow, why?
    ... Then on his server I ... connecting to it very slowly. ... We have a tiered application and we are using remoting and the ... Cause if it was serialization slowness problem ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: synchronization control between the socket sender and socket r
    ... The server side need to be clear that data from which file should be sent. ... At the receiver side, it receives data and then wait for the consumer to use. ... Client Application: ...
    (microsoft.public.win32.programmer.networks)