sodonnel commented on code in PR #4636:
URL: https://github.com/apache/ozone/pull/4636#discussion_r1182979733
##########
hadoop-hdds/server-scm/src/test/java/org/apache/hadoop/hdds/scm/container/replication/TestUnderReplicatedProcessor.java:
##########
@@ -93,4 +96,40 @@ public void testMessageRequeuedOnException() throws
IOException {
assertEquals(1, queue.underReplicatedQueueSize());
assertSame(result, queue.dequeueUnderReplicatedContainer());
}
+
+ @Test
+ public void testMessageNotProcessedIfGlobalLimitReached() throws IOException
{
+ AtomicLong inFlightReplications = new AtomicLong(11);
Review Comment:
At line 64 in the diff, I have set the default case to be the "no limit", so
if existing tests are working, then they must be OK with that. Adding any more
would just be a duplicate of the existing "success" test which runs a container
through successfully.
```
Mockito.when(replicationManager.getReplicationInFlightLimit())
.thenReturn(0L);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]