[ https://issues.apache.org/jira/browse/HDDS-1312?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16797871#comment-16797871 ]
Jitendra Nath Pandey edited comment on HDDS-1312 at 3/21/19 6:02 PM: --------------------------------------------------------------------- I am yet to complete the review, however some comments. # {code:java} ioException = new IOException( "Unexpected Storage Container Exception: " + e.toString(), e); adjustBuffersOnException(); throw ioException;{code} What is the reason for this change? # {code:java} if (currentBufferIndex >= 0) { currentBufferIndex--; } {code} This doesn't look right, because it will hide a bug elsewhere. If releaseBuffer is called, a buffer must have been allocated somewhere. We should instead add a precondition check. # {code:java} public Throwable checkForException public ConcurrentHashMap<UUID, Long> getCommitInfoMap(){code} These should be annotated with {{VisibleForTesting}} # In {{testBufferCaching}}, some comments don't look right, e.g. after flush call, data is flushed, but may not be acked. was (Author: jnp): I am yet to complete the review, however some comments. # {code:java} ioException = new IOException( "Unexpected Storage Container Exception: " + e.toString(), e); adjustBuffersOnException(); throw ioException;{code} What is the reason for this change? # {code:java} if (currentBufferIndex >= 0) { currentBufferIndex--; } {code} This doesn't look right, because it will hide a bug elsewhere. If releaseBuffer is called, a buffer must have been allocated somewhere. We should instead add a precondition check. # {code:java} public Throwable checkForException public ConcurrentHashMap<UUID, Long> getCommitInfoMap(){code} These should be annotated with {{VisibleForTesting}} # In {{testBufferCaching}}, some comments don't look write, e.g. after flush call, data is flushed, but may not be acked. > Add more unit tests to verify BlockOutputStream functionalities > --------------------------------------------------------------- > > Key: HDDS-1312 > URL: https://issues.apache.org/jira/browse/HDDS-1312 > Project: Hadoop Distributed Data Store > Issue Type: Improvement > Affects Versions: 0.5.0 > Reporter: Shashikant Banerjee > Assignee: Shashikant Banerjee > Priority: Blocker > Attachments: HDDS-1312.000.patch > > > This jira aims to add more unit test coverage for BlockOutputStream > functionalities. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org