Ah ok broadcast method calls. I think you've got two options then, the first is the call in a loop option (although I reckon you could do something a little more groovy with the Java SE 7 Fork/Join framework. Note you'd have to deal with potentially non-responsive services.
The alternative would be to use a JavaSpace which can't dispatch method calls as such but could transfer a request object defining some method or operation to recipients who would then generate suitable responses and push them back to the originator. It'd look largely identical to the master/worker pattern.... On 24 November 2011 19:53, Vladimir Ghetau <[email protected]> wrote: > I would like to broadcast a query to all available services. > > The services will have a method let's say "callMe( )" which I can call (via > broadcast), and I should receive all the answers. > > Is this functionality possible, or should I just iterate through each > service and call it in a loop until the last service is contacted? > > Many thanks, > VG > > On Thu, Nov 24, 2011 at 7:28 PM, Dan Creswell <[email protected]>wrote: > >> It is certainly possible but not something for which you'll find any >> immediate API support within JINI (which I think is probably what >> you're interested in). >> >> It would help to understand a little more of what exactly you'd be >> doing with such a mechanism. With that information we could make more >> useful suggestions.... >> >> On 24 November 2011 17:37, Vladimir Ghetau <[email protected]> >> wrote: >> > Hello, >> > >> > Is it possible to use one of the JINI connected machines to broadcast a >> > message to all the other machines which are registered with the lookup >> > service? >> > >> > Many thanks, >> > Vladimir Ghetau >> > >> >
