[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.remoting

My object's remoting proxy is WAY huge on the client

0to60

9/18/2004 3:32:00 PM

I have an object A, who contains a bunch of maps of other objects B, C, D.
Some maps are internal, some are private. Object A inherits from
MarshalByRefObject, whereas B, C and D are all marked Serializable.

On client computers, I'll obtain a remoting proxy to object A (often proxies
to many A's as this is a peer to peer app). Trouble is, if object A's
interal maps of B, C and D are large, A's proxies on client computers get
large too. I'm assuming that somehow A's proxy contains A's internal maps.

I don't want that. All I really want is for A's proxy to have a few public
methods in it and NO data. Any suggestions? Is there a way I can customize
the proxy to only contain the stuff I want?


1 Answer

Ken Kolda

9/20/2004 3:39:00 PM

0

Just to verify, how to do you know that the proxy is getting large? Have you
serialized the contents of the ObjRef to disk and looked at it?

As you mentioned, if A is MarshalByRef and that's the only object you pass
around, then your large objects should not be crossing the remoting
boundary. Can you post a small code example to demonstrate the issue and how
you concluded the proxy is large?

Ken


"0to60" <holeshot60_nospam_@yahoo.com> wrote in message
news:JNadnYcsnNWfyNHcRVn-vw@comcast.com...
> I have an object A, who contains a bunch of maps of other objects B, C, D.
> Some maps are internal, some are private. Object A inherits from
> MarshalByRefObject, whereas B, C and D are all marked Serializable.
>
> On client computers, I'll obtain a remoting proxy to object A (often
proxies
> to many A's as this is a peer to peer app). Trouble is, if object A's
> interal maps of B, C and D are large, A's proxies on client computers get
> large too. I'm assuming that somehow A's proxy contains A's internal
maps.
>
> I don't want that. All I really want is for A's proxy to have a few
public
> methods in it and NO data. Any suggestions? Is there a way I can
customize
> the proxy to only contain the stuff I want?
>
>