summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordanielhanrahan <daniel.hanrahan@est.tech>2024-11-13 18:07:48 +0000
committerPriyank Maheshwari <priyank.maheshwari@est.tech>2024-11-15 17:03:13 +0000
commit37962e3faca4f2306546c4f70d480b0c323d2c68 (patch)
treedcb02c77afd1edb6f9e3c15cb4d1d01b77c03081
parent24e8c116056f57e14520f260e1dc5a2ae5266358 (diff)
[k6] Lower load for legacy async batch operation test
Legacy async batch operation test is failing and reporting zero as result due to timeouts in the test. - Lower total batch requests to 100 instead of 1000 - Limit the number of kafka messages per batch to 200 instead of 1000 to avoid timeout issues. Issue-ID: CPS-2274 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I06c04173ca1ed0f3580df6a73b5d647ab7ed0c71
-rw-r--r--k6-tests/ncmp/common/utils.js2
-rw-r--r--k6-tests/ncmp/ncmp-kpi.js3
2 files changed, 2 insertions, 3 deletions
diff --git a/k6-tests/ncmp/common/utils.js b/k6-tests/ncmp/common/utils.js
index 6ddcca5fbf..a2467edf6f 100644
--- a/k6-tests/ncmp/common/utils.js
+++ b/k6-tests/ncmp/common/utils.js
@@ -27,7 +27,7 @@ export const READ_DATA_FOR_CM_HANDLE_DELAY_MS = 300; // must have same value as
export const WRITE_DATA_FOR_CM_HANDLE_DELAY_MS = 670; // must have same value as in docker-compose.yml
export const CONTENT_TYPE_JSON_PARAM = {'Content-Type': 'application/json'};
export const LEGACY_BATCH_THROUGHPUT_TEST_BATCH_SIZE = 200;
-export const LEGACY_BATCH_THROUGHPUT_TEST_NUMBER_OF_REQUESTS = 1000;
+export const LEGACY_BATCH_THROUGHPUT_TEST_NUMBER_OF_REQUESTS = 100;
export const LEGACY_BATCH_TOPIC_NAME = 'legacy_batch_topic';
export const KAFKA_BOOTSTRAP_SERVERS = ['localhost:9092'];
export const MODULE_SET_TAGS = ['tagA', 'tagB', 'tagC', 'tagD', 'tagE'];
diff --git a/k6-tests/ncmp/ncmp-kpi.js b/k6-tests/ncmp/ncmp-kpi.js
index 53f7629cac..e46c547c30 100644
--- a/k6-tests/ncmp/ncmp-kpi.js
+++ b/k6-tests/ncmp/ncmp-kpi.js
@@ -345,8 +345,7 @@ export function legacyBatchConsumeScenario() {
let startTime = Date.now();
while (messagesConsumed < TOTAL_MESSAGES_TO_CONSUME) {
- let messages = legacyBatchEventReader.consume({ limit: 1000 });
-
+ let messages = legacyBatchEventReader.consume({ limit: LEGACY_BATCH_THROUGHPUT_TEST_BATCH_SIZE });
if (messages.length > 0) {
messagesConsumed += messages.length;
}