Valentin Kulichenko created IGNITE-4255: -------------------------------------------
Summary: Improve IgniteCache.loadCache API Key: IGNITE-4255 URL: https://issues.apache.org/jira/browse/IGNITE-4255 Project: Ignite Issue Type: Bug Components: cache Affects Versions: 1.7 Reporter: Valentin Kulichenko This is based on this discussion on dev@ list: http://apache-ignite-developers.2346864.n4.nabble.com/IgniteCache-loadCache-improvement-proposal-td12177.html The proposal is to improve the cache loading API by adding the following methods: {code} public void loadCache(@Nullable IgniteBiPredicate<K, V> p, IgniteBiInClosure<K, V> clo, @Nullable Object... args) throws CacheException; public void localLoadCache(@Nullable IgniteBiPredicate<K, V> p, IgniteBiInClosure<K, V> clo, @Nullable Object... args) throws CacheException; {code} This will allow to customize the closure passed to {{CacheStore.loadCache(...)}} method, which currently always comes from the cache internals. This way user will have more control on data loading process, i.e. currently they control only persistence part of it, but after the change they will be also able to customize logic that actually saves loaded entries in the cache. For example, this will allow to use {{IgniteDataStreamer}} to load the data reusing the existing persistence logic implemented in some {{CacheStore}} implementation (e.g., our POJO store or Cassandra store). For this particular case we should provide the closure implementation out of the box. -- This message was sent by Atlassian JIRA (v6.3.4#6332)