Leo Sutic wrote:
>>-----Original Message-----
>>From: Antti Koivunen [mailto:[EMAIL PROTECTED]]
>>
>>
>>Leo Sutic wrote:
>><skip/>
>>
>>>public class Token extends java.rmi.server.UID {}
>>>
>>new java.rmi.server.UID() is a very expensive operation, so it's not
>>really suitable for something like this.
>>
> 
> Only if it is more expensive than *all* the calls you intend to make
> through the obtained interface before you release it.

Right, as it's created once per component lifecycle. That example just 
first struck me as a method level transaction, but of course that's not 
the case.

> But I realized that it is enough to have:
> 
> public class Token {}
> 
> Since we can use object identity.
That'd be even better.

(: A ;)



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to