river-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tom Hobbs <tvho...@googlemail.com>
Subject Re: Overriding initialMemberGroups in "options" when starting reggie
Date Wed, 25 Jan 2012 17:12:01 GMT
I agree.  I'm making judicious use of an empty config file and the
overrides to be able to specify things easily in Java (with
accompanying convenience methods) and starting services is much more

I'm only working with reggie, outrigger and mahalo at the moment, but
I've found something curious.  Has anyone else experienced this and is
it a bug somewhere else or just a bug in my implementation?

If I specify something such as;

new NonActivatableServiceDescriptor(
			    new String[] { config,
net.jini.lookup.entry.ServiceInfo(\"transName\", \"manufacturer\",
\"vendor\", \"version\", \"model\", \"serialNumber\")",
			    		       "com.sun.jini.mahalo.initialLookupAttributes = new
net.jini.core.entry.Entry[] { serviceInfo }"})};

When I lookup the service via reggie, there are two ServiceInfos in
initialLookupAttributes, the standard one the service gives itself and
the new one that I provide.

Anyone seen that, or got any thoughts on it?

On Wed, Jan 25, 2012 at 2:28 PM, Gregg Wonderly <gergg@cox.net> wrote:
> This is an example of one of those things where "just java" is the answer in the configuration
file.  Constructing new objects, always works.  The subtle issues of what can and can't
happen all revolve around invoking methods and using their return values.  As Sim pointed
out, the new String[] { ... } syntax works fine.  I've always avoided using the command line
options to adjust configuration, just because it can seem difficult to get it right, especially
with quoting of quotes.
> Gregg Wonderly
> On Jan 25, 2012, at 4:33 AM, Tom Hobbs wrote:
>> Does anyone know the correct incantation required to override the
>> initialMemberGroups value when starting reggie.
>> I've tried various permutations along the themes such as;
>>                       new NonActivatableServiceDescriptor(
>>                           codebase,
>>                           policy,
>>                           classpath,
>>                           "com.sun.jini.reggie.TransientRegistrarImpl",
>>                           new String[] { config,
>> "com.sun.jini.reggie.initialMemberGroups=[\"Lester\", \"Jeff\"]" }) };
>> The above example gives a parse error on the '[' character.  I've
>> tried every variation I can think of, I've yet to hit the right one
>> though.
>> Does anyone have any ideas or can point me in the right direction?
>> Thanks,
>> Tom

View raw message