You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ratis.apache.org by "Shashikant Banerjee (JIRA)" <ji...@apache.org> on 2018/11/17 04:30:00 UTC
[jira] [Commented] (RATIS-365) Implement RaftServer.getGroupIds()
using the key set of ImplMap
[ https://issues.apache.org/jira/browse/RATIS-365?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16690372#comment-16690372 ]
Shashikant Banerjee commented on RATIS-365:
-------------------------------------------
Thanks [~szetszwo] for reporting and working on this. It looks good to me. +1
> Implement RaftServer.getGroupIds() using the key set of ImplMap
> ---------------------------------------------------------------
>
> Key: RATIS-365
> URL: https://issues.apache.org/jira/browse/RATIS-365
> Project: Ratis
> Issue Type: Improvement
> Components: server
> Reporter: Tsz Wo Nicholas Sze
> Assignee: Tsz Wo Nicholas Sze
> Priority: Major
> Attachments: r365_20181023.patch
>
>
> {code:java}
> //RaftServerProxy
> public Iterable<RaftGroupId> getGroupIds() throws IOException {
> return getImpls().stream().map(RaftServerImpl::getGroupId).collect(Collectors.toList());
> }
> {code}
> getGroupIds() above unnecessarily calls getImpls() and then map RaftServerImpl to RaftGroupId. We may get RaftGroupId(s) directly from ImplMap.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)