You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Pradeep Badiger <Pr...@fico.com> on 2016/10/08 20:00:20 UTC

Evicted entry appears in Write-behind cache

Hi,

I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?

Thanks,
Pradeep V.B.
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

Re: Evicted entry appears in Write-behind cache

Posted by Vladislav Pyatkov <vl...@gmail.com>.
Hi,

Is the issue[1] relevant for this thread?

[1]: https://issues.apache.org/jira/browse/IGNITE-2375

On Tue, Oct 11, 2016 at 4:13 AM, Denis Magda <dm...@gridgain.com> wrote:

> Hi,
>
> How do you see that the evicted entries are still in the cache? If you
> check this by calling cache get like operations then entries can be loaded
> back from the write-behind store or from your underlying store.
>
> —
> Denis
>
>
> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
> Hi,
>
> I am trying to evaluate Apache Ignite and trying to explore eviction
> policy and write behind features. I am seeing that whenever a cache is
> configured with eviction policy and write behind feature, the write behind
> cache always have all the changed entries including the ones that are
> evicted, before the write cache is flushed. But soon after it is flushed,
> the store loads again from DB. Is this the expected behavior? Is there a
> documentation on how the write behind cache works?
>
> Thanks,
> Pradeep V.B.
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>


-- 
Vladislav Pyatkov

RE: Evicted entry appears in Write-behind cache

Posted by Pradeep Badiger <Pr...@fico.com>.
Thanks Vladislav

From: Vladislav Pyatkov [mailto:vldpyatkov@gmail.com]
Sent: Wednesday, October 26, 2016 5:08 AM
To: user@ignite.apache.org
Subject: Re: Evicted entry appears in Write-behind cache

Hi,

Yes, write behind buffer gets locks on entries which stores between loading to CacheStore. So that this entries cannot be evicted.

If "get" invocation can not find value in cache, it will try to get value from CacheStore.

On Fri, Oct 14, 2016 at 6:55 PM, Pradeep Badiger <Pr...@fico.com>> wrote:
I have some log statements in the load() which gets called when there is no entry in the cache or write behind buffer. What I learnt is that there is a write behind buffer that holds on to the entries (even the evicted ones) and whenever there is a get() for an entry, ignite looks at both the cache and the write behind buffer and loads it. If it doesn’t find it in any of the two, it then uses the read through mechanism to load the entry from the store.

Thanks,
Pradeep V.B.

From: Vladislav Pyatkov [mailto:vpyatkov@gridgain.com<ma...@gridgain.com>]
Sent: Friday, October 14, 2016 4:25 AM

To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi Paradeep,

Why are you think, what the entry could not be read through your persistence storage:

.setReadThrough(stateQoS.isReadThroughEnabled())

When cache can not get data from in memory, it will try to get data from storage, which configured as "ReadThrough".

On Thu, Oct 13, 2016 at 6:41 PM, Pradeep Badiger <Pr...@fico.com>> wrote:
Hi Vladislav,

Please see the below cache configuration.

                                             LruEvictionPolicy evictionPolicy = new LruEvictionPolicy<>(getIntProperty(envConfig, CACHE_SIZE, 10000));
                                             cacheConfiguration
                                                            .setEvictionPolicy(evictionPolicy)
                                                            .setWriteBehindFlushSize(getIntProperty(envConfig, CACHE_WB_FLUSH_SIZE, 0))
                                                            .setWriteBehindBatchSize(getIntProperty(envConfig, CACHE_WB_BATCH_SIZE, 200))
                                                            .setWriteBehindEnabled(stateQoS.isWriteBehindEnabled())
                                                            .setWriteBehindFlushFrequency(getIntProperty(envConfig, CACHE_WB_FLUSH_FREQ_MS, 5000))
                                                            .setWriteBehindFlushThreadCount(getIntProperty(envConfig, CACHE_WB_FLUSH_THREADS, 10))
                                                            .setCacheStoreFactory(new StateCacheStoreFactory<K, V>(cacheName,
                                                                                          storageManager))
                                                            .setName(cacheName)
                                                            .setReadThrough(stateQoS.isReadThroughEnabled())
                                                            .setWriteThrough(stateQoS.isWriteThroughEnabled());

Thanks,
Pradeep V.B.

From: Vladislav Pyatkov [mailto:vldpyatkov@gmail.com<ma...@gmail.com>]
Sent: Wednesday, October 12, 2016 2:59 AM

To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi Pradeep,

Could you please provide cache configuration?

On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com>> wrote:
Looks like that my initial understanding was wrong. There is a related discussion
http://apache-ignite-users.70518.x6.nabble.com/Cache-read-through-with-expiry-policy-td2521.html

—
Denis

On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi Denis,

I did the get() on the evicted entry from the cache, it still returned me the value without calling the load() on the store. As you said, the entry would be cached in the write behind store even for the evicted entry. Is that true?

Thanks,
Pradeep V.B.
From: Denis Magda [mailto:dmagda@gridgain.com]
Sent: Monday, October 10, 2016 9:13 PM
To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi,

How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store.

—
Denis

On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi,

I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?

Thanks,
Pradeep V.B.
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.




--
Vladislav Pyatkov
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.



--
Vladislav Pyatkov
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

Re: Evicted entry appears in Write-behind cache

Posted by Vladislav Pyatkov <vl...@gmail.com>.
Hi,

Yes, write behind buffer gets locks on entries which stores between loading
to CacheStore. So that this entries cannot be evicted.

If "get" invocation can not find value in cache, it will try to get value
from CacheStore.

On Fri, Oct 14, 2016 at 6:55 PM, Pradeep Badiger <Pr...@fico.com>
wrote:

> I have some log statements in the load() which gets called when there is
> no entry in the cache or write behind buffer. What I learnt is that there
> is a write behind buffer that holds on to the entries (even the evicted
> ones) and whenever there is a get() for an entry, ignite looks at both the
> cache and the write behind buffer and loads it. If it doesn’t find it in
> any of the two, it then uses the read through mechanism to load the entry
> from the store.
>
>
>
> Thanks,
>
> Pradeep V.B.
>
>
>
> *From:* Vladislav Pyatkov [mailto:vpyatkov@gridgain.com]
> *Sent:* Friday, October 14, 2016 4:25 AM
>
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
>
>
> Hi Paradeep,
>
>
>
> Why are you think, what the entry could not be read through your
> persistence storage:
>
>
>
> *.setReadThrough(stateQoS.isReadThroughEnabled()) *
>
>
>
> When cache can not get data from in memory, it will try to get data from
> storage, which configured as "ReadThrough".
>
>
>
> On Thu, Oct 13, 2016 at 6:41 PM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
> Hi Vladislav,
>
>
>
> Please see the below cache configuration.
>
>
>
>                                              LruEvictionPolicy
> evictionPolicy = new LruEvictionPolicy<>(getIntProperty(envConfig,
> CACHE_SIZE, 10000));
>
>                                              cacheConfiguration
>
>
> .setEvictionPolicy(evictionPolicy)
>
>
> .setWriteBehindFlushSize(getIntProperty(envConfig, CACHE_WB_FLUSH_SIZE,
> 0))
>
>
> .setWriteBehindBatchSize(getIntProperty(envConfig, CACHE_WB_BATCH_SIZE,
> 200))
>
>
> .setWriteBehindEnabled(stateQoS.isWriteBehindEnabled())
>
>
> .setWriteBehindFlushFrequency(getIntProperty(envConfig,
> CACHE_WB_FLUSH_FREQ_MS, 5000))
>
>                                                             .
> setWriteBehindFlushThreadCount(getIntProperty(envConfig,
> CACHE_WB_FLUSH_THREADS, 10))
>
>
> .setCacheStoreFactory(new StateCacheStoreFactory<K, V>(cacheName,
>
>
> storageManager))
>
>
> .setName(cacheName)
>
>
> .setReadThrough(stateQoS.isReadThroughEnabled())
>
>
> .setWriteThrough(stateQoS.isWriteThroughEnabled());
>
>
>
> Thanks,
>
> Pradeep V.B.
>
>
>
> *From:* Vladislav Pyatkov [mailto:vldpyatkov@gmail.com]
> *Sent:* Wednesday, October 12, 2016 2:59 AM
>
>
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
>
>
> Hi Pradeep,
>
>
>
> Could you please provide cache configuration?
>
>
>
> On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com> wrote:
>
> Looks like that my initial understanding was wrong. There is a related
> discussion
>
> http://apache-ignite-users.70518.x6.nabble.com/Cache-
> read-through-with-expiry-policy-td2521.html
>
>
>
> —
>
> Denis
>
>
>
> On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
>
>
> Hi Denis,
>
>
>
> I did the get() on the evicted entry from the cache, it still returned me
> the value without calling the load() on the store. As you said, the entry
> would be cached in the write behind store even for the evicted entry. Is
> that true?
>
>
>
> Thanks,
>
> Pradeep V.B.
>
> *From:* Denis Magda [mailto:dmagda@gridgain.com <dm...@gridgain.com>]
> *Sent:* Monday, October 10, 2016 9:13 PM
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
>
>
> Hi,
>
>
>
> How do you see that the evicted entries are still in the cache? If you
> check this by calling cache get like operations then entries can be loaded
> back from the write-behind store or from your underlying store.
>
>
>
> —
>
> Denis
>
>
>
> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
>
>
> Hi,
>
>
>
> I am trying to evaluate Apache Ignite and trying to explore eviction
> policy and write behind features. I am seeing that whenever a cache is
> configured with eviction policy and write behind feature, the write behind
> cache always have all the changed entries including the ones that are
> evicted, before the write cache is flushed. But soon after it is flushed,
> the store loads again from DB. Is this the expected behavior? Is there a
> documentation on how the write behind cache works?
>
>
>
> Thanks,
>
> Pradeep V.B.
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>
>
>
>
>
> --
>
> Vladislav Pyatkov
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>



-- 
Vladislav Pyatkov

RE: Evicted entry appears in Write-behind cache

Posted by Pradeep Badiger <Pr...@fico.com>.
I have some log statements in the load() which gets called when there is no entry in the cache or write behind buffer. What I learnt is that there is a write behind buffer that holds on to the entries (even the evicted ones) and whenever there is a get() for an entry, ignite looks at both the cache and the write behind buffer and loads it. If it doesn’t find it in any of the two, it then uses the read through mechanism to load the entry from the store.

Thanks,
Pradeep V.B.

From: Vladislav Pyatkov [mailto:vpyatkov@gridgain.com]
Sent: Friday, October 14, 2016 4:25 AM
To: user@ignite.apache.org
Subject: Re: Evicted entry appears in Write-behind cache

Hi Paradeep,

Why are you think, what the entry could not be read through your persistence storage:

.setReadThrough(stateQoS.isReadThroughEnabled())

When cache can not get data from in memory, it will try to get data from storage, which configured as "ReadThrough".

On Thu, Oct 13, 2016 at 6:41 PM, Pradeep Badiger <Pr...@fico.com>> wrote:
Hi Vladislav,

Please see the below cache configuration.

                                             LruEvictionPolicy evictionPolicy = new LruEvictionPolicy<>(getIntProperty(envConfig, CACHE_SIZE, 10000));
                                             cacheConfiguration
                                                            .setEvictionPolicy(evictionPolicy)
                                                            .setWriteBehindFlushSize(getIntProperty(envConfig, CACHE_WB_FLUSH_SIZE, 0))
                                                            .setWriteBehindBatchSize(getIntProperty(envConfig, CACHE_WB_BATCH_SIZE, 200))
                                                            .setWriteBehindEnabled(stateQoS.isWriteBehindEnabled())
                                                            .setWriteBehindFlushFrequency(getIntProperty(envConfig, CACHE_WB_FLUSH_FREQ_MS, 5000))
                                                            .setWriteBehindFlushThreadCount(getIntProperty(envConfig, CACHE_WB_FLUSH_THREADS, 10))
                                                            .setCacheStoreFactory(new StateCacheStoreFactory<K, V>(cacheName,
                                                                                          storageManager))
                                                            .setName(cacheName)
                                                            .setReadThrough(stateQoS.isReadThroughEnabled())
                                                            .setWriteThrough(stateQoS.isWriteThroughEnabled());

Thanks,
Pradeep V.B.

From: Vladislav Pyatkov [mailto:vldpyatkov@gmail.com<ma...@gmail.com>]
Sent: Wednesday, October 12, 2016 2:59 AM

To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi Pradeep,

Could you please provide cache configuration?

On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com>> wrote:
Looks like that my initial understanding was wrong. There is a related discussion
http://apache-ignite-users.70518.x6.nabble.com/Cache-read-through-with-expiry-policy-td2521.html

—
Denis

On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi Denis,

I did the get() on the evicted entry from the cache, it still returned me the value without calling the load() on the store. As you said, the entry would be cached in the write behind store even for the evicted entry. Is that true?

Thanks,
Pradeep V.B.
From: Denis Magda [mailto:dmagda@gridgain.com]
Sent: Monday, October 10, 2016 9:13 PM
To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi,

How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store.

—
Denis

On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi,

I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?

Thanks,
Pradeep V.B.
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.




--
Vladislav Pyatkov
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

Re: Evicted entry appears in Write-behind cache

Posted by Vladislav Pyatkov <vp...@gridgain.com>.
Hi Paradeep,

Why are you think, what the entry could not be read through your
persistence storage:

*.setReadThrough(stateQoS.isReadThroughEnabled()) *

When cache can not get data from in memory, it will try to get data from
storage, which configured as "ReadThrough".

On Thu, Oct 13, 2016 at 6:41 PM, Pradeep Badiger <Pr...@fico.com>
wrote:

> Hi Vladislav,
>
>
>
> Please see the below cache configuration.
>
>
>
>                                              LruEvictionPolicy
> evictionPolicy = new LruEvictionPolicy<>(getIntProperty(envConfig,
> CACHE_SIZE, 10000));
>
>                                              cacheConfiguration
>
>
> .setEvictionPolicy(evictionPolicy)
>
>
> .setWriteBehindFlushSize(getIntProperty(envConfig, CACHE_WB_FLUSH_SIZE,
> 0))
>
>
> .setWriteBehindBatchSize(getIntProperty(envConfig, CACHE_WB_BATCH_SIZE,
> 200))
>
>
> .setWriteBehindEnabled(stateQoS.isWriteBehindEnabled())
>
>
> .setWriteBehindFlushFrequency(getIntProperty(envConfig,
> CACHE_WB_FLUSH_FREQ_MS, 5000))
>
>                                                             .
> setWriteBehindFlushThreadCount(getIntProperty(envConfig,
> CACHE_WB_FLUSH_THREADS, 10))
>
>
> .setCacheStoreFactory(new StateCacheStoreFactory<K, V>(cacheName,
>
>
> storageManager))
>
>
> .setName(cacheName)
>
>
> .setReadThrough(stateQoS.isReadThroughEnabled())
>
>
> .setWriteThrough(stateQoS.isWriteThroughEnabled());
>
>
>
> Thanks,
>
> Pradeep V.B.
>
>
>
> *From:* Vladislav Pyatkov [mailto:vldpyatkov@gmail.com]
> *Sent:* Wednesday, October 12, 2016 2:59 AM
>
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
>
>
> Hi Pradeep,
>
>
>
> Could you please provide cache configuration?
>
>
>
> On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com> wrote:
>
> Looks like that my initial understanding was wrong. There is a related
> discussion
>
> http://apache-ignite-users.70518.x6.nabble.com/Cache-
> read-through-with-expiry-policy-td2521.html
>
>
>
> —
>
> Denis
>
>
>
> On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
>
>
> Hi Denis,
>
>
>
> I did the get() on the evicted entry from the cache, it still returned me
> the value without calling the load() on the store. As you said, the entry
> would be cached in the write behind store even for the evicted entry. Is
> that true?
>
>
>
> Thanks,
>
> Pradeep V.B.
>
> *From:* Denis Magda [mailto:dmagda@gridgain.com <dm...@gridgain.com>]
> *Sent:* Monday, October 10, 2016 9:13 PM
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
>
>
> Hi,
>
>
>
> How do you see that the evicted entries are still in the cache? If you
> check this by calling cache get like operations then entries can be loaded
> back from the write-behind store or from your underlying store.
>
>
>
> —
>
> Denis
>
>
>
> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
>
>
> Hi,
>
>
>
> I am trying to evaluate Apache Ignite and trying to explore eviction
> policy and write behind features. I am seeing that whenever a cache is
> configured with eviction policy and write behind feature, the write behind
> cache always have all the changed entries including the ones that are
> evicted, before the write cache is flushed. But soon after it is flushed,
> the store loads again from DB. Is this the expected behavior? Is there a
> documentation on how the write behind cache works?
>
>
>
> Thanks,
>
> Pradeep V.B.
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>
>
>
>
>
> --
>
> Vladislav Pyatkov
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>

RE: Evicted entry appears in Write-behind cache

Posted by Pradeep Badiger <Pr...@fico.com>.
Hi Vladislav,

Please see the below cache configuration.

                                             LruEvictionPolicy evictionPolicy = new LruEvictionPolicy<>(getIntProperty(envConfig, CACHE_SIZE, 10000));
                                             cacheConfiguration
                                                            .setEvictionPolicy(evictionPolicy)
                                                            .setWriteBehindFlushSize(getIntProperty(envConfig, CACHE_WB_FLUSH_SIZE, 0))
                                                            .setWriteBehindBatchSize(getIntProperty(envConfig, CACHE_WB_BATCH_SIZE, 200))
                                                            .setWriteBehindEnabled(stateQoS.isWriteBehindEnabled())
                                                            .setWriteBehindFlushFrequency(getIntProperty(envConfig, CACHE_WB_FLUSH_FREQ_MS, 5000))
                                                            .setWriteBehindFlushThreadCount(getIntProperty(envConfig, CACHE_WB_FLUSH_THREADS, 10))
                                                            .setCacheStoreFactory(new StateCacheStoreFactory<K, V>(cacheName,
                                                                                          storageManager))
                                                            .setName(cacheName)
                                                            .setReadThrough(stateQoS.isReadThroughEnabled())
                                                            .setWriteThrough(stateQoS.isWriteThroughEnabled());

Thanks,
Pradeep V.B.

From: Vladislav Pyatkov [mailto:vldpyatkov@gmail.com]
Sent: Wednesday, October 12, 2016 2:59 AM
To: user@ignite.apache.org
Subject: Re: Evicted entry appears in Write-behind cache

Hi Pradeep,

Could you please provide cache configuration?

On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com>> wrote:
Looks like that my initial understanding was wrong. There is a related discussion
http://apache-ignite-users.70518.x6.nabble.com/Cache-read-through-with-expiry-policy-td2521.html

—
Denis

On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi Denis,

I did the get() on the evicted entry from the cache, it still returned me the value without calling the load() on the store. As you said, the entry would be cached in the write behind store even for the evicted entry. Is that true?

Thanks,
Pradeep V.B.
From: Denis Magda [mailto:dmagda@gridgain.com]
Sent: Monday, October 10, 2016 9:13 PM
To: user@ignite.apache.org<ma...@ignite.apache.org>
Subject: Re: Evicted entry appears in Write-behind cache

Hi,

How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store.

—
Denis

On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi,

I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?

Thanks,
Pradeep V.B.
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.




--
Vladislav Pyatkov
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

Re: Evicted entry appears in Write-behind cache

Posted by Vladislav Pyatkov <vl...@gmail.com>.
Hi Pradeep,

Could you please provide cache configuration?

On Tue, Oct 11, 2016 at 6:57 PM, Denis Magda <dm...@gridgain.com> wrote:

> Looks like that my initial understanding was wrong. There is a related
> discussion
> http://apache-ignite-users.70518.x6.nabble.com/Cache-
> read-through-with-expiry-policy-td2521.html
>
> —
> Denis
>
> On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
> Hi Denis,
>
> I did the get() on the evicted entry from the cache, it still returned me
> the value without calling the load() on the store. As you said, the entry
> would be cached in the write behind store even for the evicted entry. Is
> that true?
>
> Thanks,
> Pradeep V.B.
> *From:* Denis Magda [mailto:dmagda@gridgain.com <dm...@gridgain.com>]
> *Sent:* Monday, October 10, 2016 9:13 PM
> *To:* user@ignite.apache.org
> *Subject:* Re: Evicted entry appears in Write-behind cache
>
> Hi,
>
> How do you see that the evicted entries are still in the cache? If you
> check this by calling cache get like operations then entries can be loaded
> back from the write-behind store or from your underlying store.
>
> —
> Denis
>
>
> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>
> wrote:
>
> Hi,
>
> I am trying to evaluate Apache Ignite and trying to explore eviction
> policy and write behind features. I am seeing that whenever a cache is
> configured with eviction policy and write behind feature, the write behind
> cache always have all the changed entries including the ones that are
> evicted, before the write cache is flushed. But soon after it is flushed,
> the store loads again from DB. Is this the expected behavior? Is there a
> documentation on how the write behind cache works?
>
> Thanks,
> Pradeep V.B.
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>
>
>


-- 
Vladislav Pyatkov

Re: Evicted entry appears in Write-behind cache

Posted by Denis Magda <dm...@gridgain.com>.
Looks like that my initial understanding was wrong. There is a related discussion
http://apache-ignite-users.70518.x6.nabble.com/Cache-read-through-with-expiry-policy-td2521.html <http://apache-ignite-users.70518.x6.nabble.com/Cache-read-through-with-expiry-policy-td2521.html>

—
Denis

> On Oct 11, 2016, at 8:55 AM, Pradeep Badiger <Pr...@fico.com> wrote:
> 
> Hi Denis,
>  
> I did the get() on the evicted entry from the cache, it still returned me the value without calling the load() on the store. As you said, the entry would be cached in the write behind store even for the evicted entry. Is that true?
>  
> Thanks,
> Pradeep V.B.
> From: Denis Magda [mailto:dmagda@gridgain.com] 
> Sent: Monday, October 10, 2016 9:13 PM
> To: user@ignite.apache.org
> Subject: Re: Evicted entry appears in Write-behind cache
>  
> Hi,
>  
> How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store. 
>  
> —
> Denis
>  
> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <PradeepBadiger@fico.com <ma...@fico.com>> wrote:
>  
> Hi,
>  
> I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?
>  
> Thanks,
> Pradeep V.B.
> This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.
>  
> This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.


RE: Evicted entry appears in Write-behind cache

Posted by Pradeep Badiger <Pr...@fico.com>.
Hi Denis,

I did the get() on the evicted entry from the cache, it still returned me the value without calling the load() on the store. As you said, the entry would be cached in the write behind store even for the evicted entry. Is that true?

Thanks,
Pradeep V.B.
From: Denis Magda [mailto:dmagda@gridgain.com]
Sent: Monday, October 10, 2016 9:13 PM
To: user@ignite.apache.org
Subject: Re: Evicted entry appears in Write-behind cache

Hi,

How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store.

—
Denis

On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com>> wrote:

Hi,

I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?

Thanks,
Pradeep V.B.
This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.

Re: Evicted entry appears in Write-behind cache

Posted by Denis Magda <dm...@gridgain.com>.
Hi,

How do you see that the evicted entries are still in the cache? If you check this by calling cache get like operations then entries can be loaded back from the write-behind store or from your underlying store. 

—
Denis

> On Oct 8, 2016, at 1:00 PM, Pradeep Badiger <Pr...@fico.com> wrote:
> 
> Hi,
>  
> I am trying to evaluate Apache Ignite and trying to explore eviction policy and write behind features. I am seeing that whenever a cache is configured with eviction policy and write behind feature, the write behind cache always have all the changed entries including the ones that are evicted, before the write cache is flushed. But soon after it is flushed, the store loads again from DB. Is this the expected behavior? Is there a documentation on how the write behind cache works?
>  
> Thanks,
> Pradeep V.B.
> This email and any files transmitted with it are confidential, proprietary and intended solely for the individual or entity to whom they are addressed. If you have received this email in error please delete it immediately.


Re: Evicted entry appears in Write-behind cache

Posted by Vladislav Pyatkov <vl...@gmail.com>.
Hi,

"Write behind" is a feature of "write through", but when the feature was
used the entries will written asynchronously.
Hence If all entries hit into storage it is correct behavior.

Please provide reproduced example, If are you means another?

On Sat, Oct 8, 2016 at 11:00 PM, Pradeep Badiger <Pr...@fico.com>
wrote:

> Hi,
>
>
>
> I am trying to evaluate Apache Ignite and trying to explore eviction
> policy and write behind features. I am seeing that whenever a cache is
> configured with eviction policy and write behind feature, the write behind
> cache always have all the changed entries including the ones that are
> evicted, before the write cache is flushed. But soon after it is flushed,
> the store loads again from DB. Is this the expected behavior? Is there a
> documentation on how the write behind cache works?
>
>
>
> Thanks,
>
> Pradeep V.B.
> This email and any files transmitted with it are confidential, proprietary
> and intended solely for the individual or entity to whom they are
> addressed. If you have received this email in error please delete it
> immediately.
>



-- 
Vladislav Pyatkov