beehive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carlin Rogers" <carlin.rog...@gmail.com>
Subject Re: NameSevice and implementing Serializable (BEEHIVE-1112)
Date Mon, 22 May 2006 04:34:16 GMT
Yes, I'd thought of that and it will definitely allow NameService to be
Serializable. However, as far as the features using the NameService, I was
concerned that it might not be a good idea to make the map transient. For
example, when a TreeRootElement is added to the NameService (to support
XmlHttpRequest handling and running the tree on the client) and
serialization occurs, there's no way to get that back from the deserialized
NameService. Seems like that would be an issue in a clustered container env.

On 5/21/06, Thomas Cook <thomas.cook@gmail.com> wrote:
>
> Can _nameMap itself be transient, and if so would that solve this
> problem?  It seems like you might be able to get away with making a
> hash map full of weak references transient.
>
>
> On 5/20/06, Carlin Rogers <carlin.rogers@gmail.com> wrote:
> > NetUI devs,
> >
> > I was wondering if you had some thoughts about the NameService class
> > and support for serialization. See...
> >
> > http://issues.apache.org/jira/browse/BEEHIVE-1112
> >
> > I'm not sure that we can actually make NameService Serializable
> > because the _nameMap HashMap member variable is a map of
> > WeakReference. Unfortunately, I don't think reference objects are
> > Serializable. In general you would have the variable that refers to
> > the reference object be transient in a Serializable class. Otherwise
> > we'd just get an exception like "java.io.NotSerializableException:
> > java.lang.ref.WeakReference"
> >
> > So, any thoughts about how to support the use of NameService (in the
> > DivPanel and Tree XHR features) in a cluster environment?
> >
> > Thanks,
> > Carlin
> >
>
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message