"Henning P. Schmiedehausen" wrote:
>
> "Gareth Coltman" <[EMAIL PROTECTED]> writes:
>
> >> Hi,
> >>
> >> I needed to have non-expiring objects in the global cache. As far as I can
> >> see, you can do this with a RefreshableCachedObject which in turn
> >> will refresh itself forever. I added two constants to CachedObject to make
> >> this explicitly possible. Patch attached.
> >>
> >> Regards
> >> Henning
> >>
>
> >Why do you need to do this? As far as I am aware, calling the setTTL method
> >in RefreshableCachedObject with a negative value will create permanently
> >cached object. I have exactly the same requirement as you, but would prefer
> >not to patch....
>
> Hi,
>
> I don't _need_ this. I just consider a
>
> CachedObject co = new CachedObject(myObject, FOREVER);
>
> more easy to understand than
I agree, any time something is made more clear it's a
benefit.
>
> RefreshableCachedObject rco = new RefreshableCachedObject(myObject).setTTL(-1);
That at first glance doesn't mean anything to me. And having something
that says it's refreshable but is never refreshed is counter intuitive.
setTTL(int) is also a bad name while we're at it.
I don't have any problem with the patch.
+1
> You're correct, the latter does the same thing.
>
> Regards
> Henning
>
> --
> Dipl.-Inf. (Univ.) Henning P. Schmiedehausen -- Geschaeftsfuehrer
> INTERMETA - Gesellschaft fuer Mehrwertdienste mbH [EMAIL PROTECTED]
>
> Am Schwabachgrund 22 Fon.: 09131 / 50654-0 [EMAIL PROTECTED]
> D-91054 Buckenhof Fax.: 09131 / 50654-20
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
--
jvz.
Jason van Zyl
[EMAIL PROTECTED]
http://jakarta.apache.org/velocity
http://jakarta.apache.org/turbine
http://jakarta.apache.org/commons
http://tambora.zenplex.org
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]