Karunakaran,
When you create a ServiceItem, you can specify an array of Entry objects
which are nothing but service attributes
You can create a specific Entry type, say LoadInfo that implements Entry.
Include the load information in this attribute (something like no of clients
currently accessing the service) and register the service with this
attribute. This load info has to be updated every time the service registers
with the LUS. You can have a very low lease time of say 1min

Make the client check this load info in its DiscoveryListener.discovered
method and take the service proxy which has least load
If you always want the provider with load zero, you can mention the LoadInfo
attribute with the value zero set in your ServiceTemplate itself

You can see the Jini tutorial by Jan Newmarch at
http://jan.newmarch.name/java/jini/tutorial/Jini.xml for Entry objects and
more

Satish Vellanki
Isaac Asimov  - "I do not fear computers. I fear the lack of them."

On Fri, Mar 27, 2009 at 1:28 PM, Karunakaran R
<[email protected]>wrote:

>   Hi Satish Vellanki,
>
> Thanks for ur good idea.
> I'm struggling to code for it, could you please help me to perform this
> task
> via code in jini.
>
> Thanks& Regards,
> Karunakaran R
>  
>


[Non-text portions of this message have been removed]

Reply via email to