Atri, I thought a little bit more about this. Calling "getOrCreateCache" is not a good idea when streamer is called from a client node because it will lead to creating a cache delegate on this node. But with current approach this is not necessary and client node doesn't spent memory on it.
Therefore, I think we should not implement this provided that workaround exists: user could call "Ignite.getOrCreateCache" manually before starting data streaming in case it is really needed. Vladimir. On Tue, Jun 30, 2015 at 7:20 PM, Atri Sharma <[email protected]> wrote: > I have created IGNITE -1066 for this. > > Please see and comment. > > On Tue, Jun 30, 2015 at 12:36 PM, Atri Sharma <[email protected]> wrote: > > > I think it is a good idea but I wonder if it makes sense to also notify > to > > the user somehow that a cache was created or not by this function. > > > > Why I feel that is necessary is because if we are creating caches most of > > the time in the function to the user opaquely, it may lead to user > > questioning the performance degradation (minor though it may be) since > > creating a cache will be a tad more expensive than just getting it. It > > would be worthwhile to atleast log so we can identify performance issues > > later on. > > > > If you are fine I can make ticket and assign it to myself. > > > > On Tue, Jun 30, 2015 at 12:01 PM, Vladimir Ozerov <[email protected]> > > wrote: > > > >> Igniters, > >> > >> Consider the following use case. > >> 1) User configured cache template, but has never accessed it explicitly > >> yet; > >> 2) User calls Ignite.dataStreamer([cacheName]) - exception is thrown > >> because cache is not started. > >> > >> I have a feeling that data streamer must have "getOrCreateCache" > semantics > >> so that user do not have to pre-start cache explicitly to start loading > >> data to it. > >> > >> Thoughts? > >> > >> Vladimir. > >> > > > > > > > > -- > > Regards, > > > > Atri > > *l'apprenant* > > > > > > -- > Regards, > > Atri > *l'apprenant* >
