Has the close() method on caches been changed at all? Last I know was that
invoking close() on a cache destroys it completely - which I do not think is the intention of this method, esp. in a distributed setting. Has that been clarified and a decision made? I noticed that the Ignite docs now state clearly that close() destroys a cache but in my opinion that is an issue.... From the jsr107 for close(): "Closing a Cache does not necessarily destroy the contents of a Cache. It simply signals to the owning CacheManager that the Cache is no longer required by the application and that future uses of a specific Cache instance should not be permitted. Depending on the implementation and Cache topology, e.g., a storage backed or distributed caches, the contents of a closed Cache may still be available and accessible by other applications or in fact via the Cache Manager that previously owned the Cache if an application calls getCache at some point in the future." There is also a specific destroyCache() method in the spec which, I think, does what its name implies. I would say we need to make close() non-destructive and different from destroyCache(). Thanks :-) Ognen |
Lets look at renaming it to free() or something
On Wed, Jun 17, 2015 at 10:03 AM, Ognen Duzlevski <[hidden email] > wrote: > Has the close() method on caches been changed at all? Last I know was that > invoking close() on a cache destroys it completely - which I do not think > is the intention of this method, esp. in a distributed setting. > > Has that been clarified and a decision made? I noticed that the Ignite docs > now state clearly that close() destroys a cache but in my opinion that is > an issue.... > > From the jsr107 for close(): > "Closing a Cache does not necessarily destroy the contents of a Cache. It > simply signals to the owning CacheManager that the Cache is no longer > required by the application and that future uses of a specific Cache > instance should not be permitted. Depending on the implementation and Cache > topology, e.g., a storage backed or distributed caches, the contents of a > closed Cache may still be available and accessible by other applications or > in fact via the Cache Manager that previously owned the Cache if an > application calls getCache at some point in the future." > > There is also a specific destroyCache() method in the spec which, I think, > does what its name implies. I would say we need to make close() > non-destructive and different from destroyCache(). > > Thanks :-) > Ognen > -- Regards, Atri *l'apprenant* |
On Wed, Jun 17, 2015 at 12:47 PM, Atri Sharma <[hidden email]> wrote:
> Lets look at renaming it to free() or something > I am not sure you can just rename it - it is an implementation of a spec :) |
No, what I meant is that if all that close should be doing is marking
cache as no longer being used instead of cleaning up resources as well, free () out to be a better name. On Wed, Jun 17, 2015 at 11:19 PM, Ognen Duzlevski <[hidden email] > wrote: > On Wed, Jun 17, 2015 at 12:47 PM, Atri Sharma <[hidden email]> wrote: > > > Lets look at renaming it to free() or something > > > > I am not sure you can just rename it - it is an implementation of a spec :) > -- Regards, Atri *l'apprenant* |
Atri,
JCache already has close and destroy methods, so adding "free()" method will be confusing at this point. D. On Wed, Jun 17, 2015 at 10:53 AM, Atri Sharma <[hidden email]> wrote: > No, what I meant is that if all that close should be doing is marking > cache as no longer being used instead of cleaning up resources as well, > free () out to be a better name. > > On Wed, Jun 17, 2015 at 11:19 PM, Ognen Duzlevski < > [hidden email] > > wrote: > > > On Wed, Jun 17, 2015 at 12:47 PM, Atri Sharma <[hidden email]> > wrote: > > > > > Lets look at renaming it to free() or something > > > > > > > I am not sure you can just rename it - it is an implementation of a spec > :) > > > > > > -- > Regards, > > Atri > *l'apprenant* > |
That clarifies it, thanks!
On Wed, Jun 17, 2015 at 11:32 PM, Dmitriy Setrakyan <[hidden email]> wrote: > Atri, > > JCache already has close and destroy methods, so adding "free()" method > will be confusing at this point. > > D. > > On Wed, Jun 17, 2015 at 10:53 AM, Atri Sharma <[hidden email]> wrote: > > > No, what I meant is that if all that close should be doing is marking > > cache as no longer being used instead of cleaning up resources as well, > > free () out to be a better name. > > > > On Wed, Jun 17, 2015 at 11:19 PM, Ognen Duzlevski < > > [hidden email] > > > wrote: > > > > > On Wed, Jun 17, 2015 at 12:47 PM, Atri Sharma <[hidden email]> > > wrote: > > > > > > > Lets look at renaming it to free() or something > > > > > > > > > > I am not sure you can just rename it - it is an implementation of a > spec > > :) > > > > > > > > > > > -- > > Regards, > > > > Atri > > *l'apprenant* > > > -- Regards, Atri *l'apprenant* |
Free forum by Nabble | Edit this page |