users@shoal.java.net

Re: [Shoal-Users] [RFE] accessing JXTA's System ADV information or equivalent

From: Shreedhar Ganapathy <Shreedhar.Ganapathy_at_Sun.COM>
Date: Tue, 19 Feb 2008 08:11:45 -0800

Hi Michael
Excellent suggestion! One that Mo and I have been talking about making
System Advertisement or an equivalent, a first class citizen of the GMS
client api.
Could you file an RFE for us on this in the Issue Tracker?
The SystemAdvertisement supports adding custom values at time of join
that tend to remain static through the lifetime of the member.

Cheers
Shreedhar :)

Michael Bien wrote:
> Hello,
>
> JXTA stores in the system advertisement a lot of useful and never
> changing information about the node's runtime environment. It would be
> great if Shoal would provide this kind of immutable "node info"
> additional to the mutable "node details" (DistributedStateCache).
>
> I use currently the DSC for this purpose:
>
> updateNodeDetail(NodeDetailKeys.CPU_COUNT,
> Runtime.getRuntime().availableProcessors());
> updateNodeDetail(NodeDetailKeys.OS_ARCH,
> System.getProperty("os.arch"));
> updateNodeDetail(NodeDetailKeys.MAX_MEMORY,
> Runtime.getRuntime().maxMemory() / 1000000);
> updateNodeDetail(NodeDetailKeys.JVM,
> System.getProperty("java.vm.name"));
> updateNodeDetail(NodeDetailKeys.JAVA_VERSION,
> System.getProperty("java.version"));
> updateNodeDetail(NodeDetailKeys.OS_NAME,
> System.getProperty("os.name"));
> updateNodeDetail(NodeDetailKeys.OS_VERSION,
> System.getProperty("os.version"));
> ...
>
> public void updateNodeDetail(Serializable key, Serializable value)
> throws GMSException {
> gms.updateMemberDetails(nodeName, key, value);
> }
>
> This works but feels a little bit redundant, leads to (probably)
> unnecessary communication and the values are not guaranteed to arrive
> at the same time (could cause problems).
>
> public API changes:
> -node info getter in the GMS
> -node info getter in Signal
>
> optional (but cool):
> allow custom values on node join (add properties with unknown keys to
> the node info?)
>
>
> (just a thought)
>
> best regards,
>
> michael
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_shoal.dev.java.net
> For additional commands, e-mail: users-help_at_shoal.dev.java.net
>