From 858ff5962812bb8c5daa58879085365460da952c Mon Sep 17 00:00:00 2001 From: mu <59917266+4eUeP@users.noreply.github.com> Date: Sun, 8 Oct 2023 11:29:06 +0800 Subject: [PATCH] Fix CI (#119) reduce write concurrency --- app/src/test/java/io/hstream/testing/PartitionTest.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/src/test/java/io/hstream/testing/PartitionTest.java b/app/src/test/java/io/hstream/testing/PartitionTest.java index 3a2b4ea..d30c2a1 100644 --- a/app/src/test/java/io/hstream/testing/PartitionTest.java +++ b/app/src/test/java/io/hstream/testing/PartitionTest.java @@ -245,13 +245,15 @@ void testLargeConsumerGroup() throws Exception { final String streamName = randStream(client, 20); final String subscription = randSubscription(client, streamName); io.hstream.Producer producer = client.newProducer().stream(streamName).build(); - int count = 2000; byte[] rRec = new byte[10]; var rids = new ArrayList(); var writes = new ArrayList>(); + // NOTE: parallel should not be too large, otherwise the store server will + // reject the request. Especially for github ci environment. + int count = 2000; for (int i = 0; i < count; i++) { - if (i % 50 == 0) { - Thread.sleep(10); + if (i % 20 == 0) { + Thread.sleep(500); } writes.add( producer.write(Record.newBuilder().rawRecord(rRec).partitionKey("k_" + i % 10).build()));