You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Yonik Seeley (JIRA)" <ji...@apache.org> on 2017/03/01 13:09:45 UTC

[jira] [Commented] (SOLR-10104) BlockDirectoryCache release hooks do not work with multiple directories

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

Yonik Seeley commented on SOLR-10104:
-------------------------------------

Related, doesn't this now mean that removal listeners (set by setOnRelease) will grow without bound for a non-global BlockCache?
Is it important to continue supporting a non-global BlockCache?

> BlockDirectoryCache release hooks do not work with multiple directories
> -----------------------------------------------------------------------
>
>                 Key: SOLR-10104
>                 URL: https://issues.apache.org/jira/browse/SOLR-10104
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: hdfs
>    Affects Versions: 6.4
>            Reporter: Mike Drob
>            Assignee: Mark Miller
>             Fix For: 6.5, master (7.0)
>
>
> https://github.com/apache/lucene-solr/blob/5738c293f0c3f346b3e3e52c937183060d59cba1/solr/core/src/java/org/apache/solr/store/blockcache/BlockDirectoryCache.java#L53
> {code}
>     if (releaseBlocks) {
>       keysToRelease = Collections.newSetFromMap(new ConcurrentHashMap<BlockCacheKey,Boolean>(1024, 0.75f, 512));
>       blockCache.setOnRelease(new OnRelease() {
>         
>         @Override
>         public void release(BlockCacheKey key) {
>           keysToRelease.remove(key);
>         }
>       });
>     }
> {code}
> If we're using the global block cache option and create multiple directories using the same factory, we will lose the release hook for the first directory. I think we can verify that by creating a server with multiple cores.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org