You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/04/19 09:14:00 UTC

[jira] [Commented] (IGNITE-7319) Memory leak during creating/destroying local cache

    [ https://issues.apache.org/jira/browse/IGNITE-7319?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16443771#comment-16443771 ] 

ASF GitHub Bot commented on IGNITE-7319:
----------------------------------------

GitHub user aealeksandrov opened a pull request:

    https://github.com/apache/ignite/pull/3874

    IGNITE-7319: Cancelable future task for backup cleaner should be closed on CacheContinuousQueryManager stop

    When cache is created then new CONTINUOUS_QUERY task is created too. This task should work until it canceled but in Ignite code we don't store the CancelableTask somewhere. After destroying the cache this task continue its work.
    
    Now this issue is fixed.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/gridgain/apache-ignite ignite-7319

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/ignite/pull/3874.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #3874
    
----
commit e1826b023834872b8b09fbf820054f2c23a34b25
Author: Andrei Aleksandrov <ae...@...>
Date:   2018-04-19T09:09:12Z

    IGNITE-7319: Cancelable future task for backup cleaner should be closed on CacheContinuousQueryManager stop

----


> Memory leak during creating/destroying local cache
> --------------------------------------------------
>
>                 Key: IGNITE-7319
>                 URL: https://issues.apache.org/jira/browse/IGNITE-7319
>             Project: Ignite
>          Issue Type: Bug
>          Components: cache
>    Affects Versions: 2.3
>            Reporter: Mikhail Cherkasov
>            Assignee: Andrey Aleksandrov
>            Priority: Major
>             Fix For: 2.6
>
>         Attachments: Demo.java
>
>
> The following code creates local caches:
> {code}
> private IgniteCache<String, BinaryObject> createLocalCache(String name) { 
>         CacheConfiguration<String, BinaryObject> cCfg = new 
> CacheConfiguration<>(); 
>         cCfg.setName(name); 
>         cCfg.setGroupName("localCaches"); // without group leak is much 
> bigger! 
>         cCfg.setStoreKeepBinary(true); 
>         cCfg.setCacheMode(CacheMode.LOCAL); 
>         cCfg.setOnheapCacheEnabled(false); 
>         cCfg.setCopyOnRead(false); 
>         cCfg.setBackups(0); 
>         cCfg.setWriteBehindEnabled(false); 
>         cCfg.setReadThrough(false); 
>         cCfg.setReadFromBackup(false); 
>         cCfg.setQueryEntities(<some basic query here>); 
>         return ignite.createCache(cCfg).withKeepBinary(); 
>     } 
> {code}
> The caches are placed in the queue and are picked up by the worker thread which just destroys them after removing from the queue. 
> This setup seems to generate a memory leak of about 1GB per day. 
> When looking at heap dump, I see all space is occupied by instances of 
> java.util.concurrent.ConcurrentSkipListMap$Node.
> User list: http://apache-ignite-users.70518.x6.nabble.com/Memory-leak-in-GridCachePartitionExchangeManager-tt18995.html



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)