You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ratis.apache.org by "Vladimir Rodionov (JIRA)" <ji...@apache.org> on 2019/01/11 21:39:00 UTC
[jira] [Commented] (RATIS-425) LogReader#readBulk should validate
that a positive number of records was provided
[ https://issues.apache.org/jira/browse/RATIS-425?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16740812#comment-16740812 ]
Vladimir Rodionov commented on RATIS-425:
-----------------------------------------
Small patch attached. cc: [~elserj]
> LogReader#readBulk should validate that a positive number of records was provided
> ---------------------------------------------------------------------------------
>
> Key: RATIS-425
> URL: https://issues.apache.org/jira/browse/RATIS-425
> Project: Ratis
> Issue Type: Improvement
> Components: LogService
> Reporter: Josh Elser
> Assignee: Vladimir Rodionov
> Priority: Trivial
> Labels: newbie
> Attachments: RATIS-425-v1.patch
>
>
> Presently, you can ask the LogReader for {{0}} records via the method {{#readBulk(int)}}. That's pretty silly.
> We should validate that the user is strictly asking for one or more records from the LogReader.
> Same goes for the {{LogReader#readBulk(List)}} variant -- we should require that the provided list be at least size one.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)