Re: Efficient hashmap serialization?
- From: "Chris Uppal" <chris.uppal@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Sun, 4 Sep 2005 11:35:17 +0100
Sn0tters@xxxxxxxxxxx wrote:
> I serialize this map to send it over RMI, but it seems quite slow.
I'm not sure how RMI interacts with serialisation, but I suspect that there may
be a problem here.
As jan V says, within any given serialised stream, objects are only represented
once, even if they are part of a complicated object network. However, this may
not be the case when you are using RMI, unless you are driving it in such a way
that RMI can "see" that it is getting several references to the same object in
different requests. As I say, I'm not clear on exactly how RMI manages such
things, so I could be completely wrong, but it sounds as if what may be
happening is that your entire object-network is being serialised on every
request. If that's the case then it should be easy enough to diagnose (fixing
it is different ;-) since each RMI request would generate network traffic
(easily visible with any handy network monitor) that is of the same order of
size as your datastructure when serialised out to disk.
Incidentally, even if I am guessing wrong here, I think that it would be a good
idea to try serialising your data to file before worrying about RMI. If that's
slow too, then RMI isn't the problem and can be ignored while you focus on the
serialisation alone.
-- chris
.
- Follow-Ups:
- Re: Efficient hashmap serialization?
- From: jan V
- Re: Efficient hashmap serialization?
- References:
- Efficient hashmap serialization?
- From: Sn0tters@xxxxxxxxxxx
- Efficient hashmap serialization?
- Prev by Date: Re: simple (?) question about having ";" in the password
- Next by Date: Re: Unicode Editor
- Previous by thread: Re: Efficient hashmap serialization?
- Next by thread: Re: Efficient hashmap serialization?
- Index(es):
Relevant Pages
|