aboutsummaryrefslogtreecommitdiffstats
path: root/k6-tests/ncmp/ncmp-kpi.js
diff options
context:
space:
mode:
Diffstat (limited to 'k6-tests/ncmp/ncmp-kpi.js')
-rw-r--r--k6-tests/ncmp/ncmp-kpi.js17
1 files changed, 16 insertions, 1 deletions
diff --git a/k6-tests/ncmp/ncmp-kpi.js b/k6-tests/ncmp/ncmp-kpi.js
index 8ff9ec50b4..d7e4405393 100644
--- a/k6-tests/ncmp/ncmp-kpi.js
+++ b/k6-tests/ncmp/ncmp-kpi.js
@@ -27,7 +27,7 @@ import {
} from './common/utils.js';
import { registerAllCmHandles, deregisterAllCmHandles } from './common/cmhandle-crud.js';
import { executeCmHandleSearch, executeCmHandleIdSearch } from './common/search-base.js';
-import { passthroughRead, passthroughWrite, batchRead } from './common/passthrough-crud.js';
+import { passthroughRead, passthroughReadWithAltId, passthroughWrite, batchRead } from './common/passthrough-crud.js';
import {
Reader,
} from 'k6/x/kafka';
@@ -35,6 +35,7 @@ import {
let cmHandlesCreatedPerSecondGauge = new Gauge('cmhandles_created_per_second');
let cmHandlesDeletedPerSecondGauge = new Gauge('cmhandles_deleted_per_second');
let passthroughReadNcmpOverheadTrend = new Trend('ncmp_overhead_passthrough_read');
+let passthroughReadNcmpOverheadTrendWithAlternateId = new Trend('ncmp_overhead_passthrough_read_alt_id');
let passthroughWriteNcmpOverheadTrend = new Trend('ncmp_overhead_passthrough_write');
let dataOperationsBatchReadCmHandlePerSecondTrend = new Trend('data_operations_batch_read_cmhandles_per_second');
@@ -55,6 +56,12 @@ export const options = {
vus: 10,
duration: DURATION,
},
+ passthrough_read_alt_id: {
+ executor: 'constant-vus',
+ exec: 'passthrough_read_alt_id',
+ vus: 1,
+ duration: DURATION,
+ },
passthrough_write: {
executor: 'constant-vus',
exec: 'passthrough_write',
@@ -96,6 +103,7 @@ export const options = {
'http_reqs{scenario:passthrough_write}': ['rate >= 13'],
'http_reqs{scenario:passthrough_read}': ['rate >= 25'],
'ncmp_overhead_passthrough_read': ['avg <= 100'],
+ 'ncmp_overhead_passthrough_read_alt_id': ['avg <= 100'],
'ncmp_overhead_passthrough_write': ['avg <= 100'],
'http_req_duration{scenario:id_search_module}': ['avg <= 625'],
'http_req_duration{scenario:cm_search_module}': ['avg <= 13000'],
@@ -126,6 +134,13 @@ export function passthrough_read() {
passthroughReadNcmpOverheadTrend.add(overhead);
}
+export function passthrough_read_alt_id() {
+ const response = passthroughReadWithAltId();
+ check(response, { 'passthrough read with alternate Id status equals 200': (r) => r.status === 200 });
+ const overhead = response.timings.duration - READ_DATA_FOR_CM_HANDLE_DELAY_MS;
+ passthroughReadNcmpOverheadTrendWithAlternateId.add(overhead);
+}
+
export function passthrough_write() {
const response = passthroughWrite();
check(response, { 'passthrough write status equals 201': (r) => r.status === 201 });