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

Tsz Wo Nicholas Sze commented on RATIS-17:
------------------------------------------

Thanks Jing, some quick comments:
- CacheKey is created multiple times in RetryCache.  We should only create once 
at queryCache or getOrCreateEntry, and then keep passing it.
- The guava Cache is thread safe.  Do we need to synchronize queryCache and 
getOrCreateEntry?
- CacheEntry already has a replyFuture so that we should keep using it.  e.g. 
checkLeaderState(..) should not create CompletableFuture anymore.
- MAX_CAPACITY actually is MIN_CAPACITY. Otherwise, max = 16 is way to small. :)




> Add basic retry cache implementation for Raft Server
> ----------------------------------------------------
>
>                 Key: RATIS-17
>                 URL: https://issues.apache.org/jira/browse/RATIS-17
>             Project: Ratis
>          Issue Type: Sub-task
>            Reporter: Jing Zhao
>            Assignee: Jing Zhao
>         Attachments: RATIS-17.000.patch, RATIS-17.001.patch, 
> RATIS-17.002.patch
>
>
> This jira will add the basic data structure definition for the retry cache.



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

Reply via email to