-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(performance): Adjust thresholds (#1870)
<!--- Provide a general summary of your changes in the Title above --> ## Description Adjust smoketests thresholds for p95 and removed thresholds for p99. Use k8s k6 operator cluster instead of github runner ## Related Issue(s) - #1862 ## Verification - [ ] **Your** code builds clean without any errors or warnings - [ ] Manual testing done (required) - [ ] Relevant automated test added (if you find this hard, leave it and we'll help out) ## Documentation - [ ] Documentation is updated (either in `docs`-directory, Altinnpedia or a separate linked PR in [altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if applicable)
- Loading branch information
Showing
6 changed files
with
64 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 9 additions & 5 deletions
14
tests/k6/tests/serviceowner/performance/createDialogWithThresholds.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,18 @@ | ||
import { default as run } from "./create-dialog.js"; | ||
export { setup as setup } from '../../performancetest_common/readTestdata.js'; | ||
|
||
import { randomItem } from '../../../common/k6-utils.js'; | ||
import { createDialog } from '../../performancetest_common/createDialog.js'; | ||
import { serviceOwners, endUsers } from '../../performancetest_common/readTestdata.js'; | ||
export let options = { | ||
summaryTrendStats: ['avg', 'min', 'med', 'max', 'p(95)', 'p(99)', 'p(99.5)', 'p(99.9)', 'count'], | ||
vus: 1, | ||
duration: "30s", | ||
thresholds: { | ||
"http_req_duration{name:create dialog}": ["p(95)<300", "p(99)<500"], | ||
"http_req_duration{name:create dialog}": ["p(95)<200"], | ||
"http_reqs{name:create dialog}": [] | ||
} | ||
} | ||
|
||
export default function (data) { run(data); } | ||
const traceCalls = (__ENV.traceCalls ?? 'false') === 'true'; | ||
|
||
export default function () { | ||
createDialog(serviceOwners[0], randomItem(endUsers), traceCalls); | ||
} |
25 changes: 25 additions & 0 deletions
25
tests/k6/tests/serviceowner/performance/createTransmissionsWithThresholds.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { randomItem } from '../../../common/k6-utils.js'; | ||
import { createTransmissions } from '../../performancetest_common/createDialog.js'; | ||
import { serviceOwners, endUsers } from '../../performancetest_common/readTestdata.js'; | ||
|
||
export const options = { | ||
summaryTrendStats: ['avg', 'min', 'med', 'max', 'p(95)', 'p(99)', 'p(99.5)', 'p(99.9)', 'count'], | ||
vus: 1, | ||
duration: "30s", | ||
thresholds: { | ||
"http_req_duration{name:create dialog}": ["p(95)<200"], | ||
"http_reqs{name:create dialog}": [], | ||
"http_req_duration{name:create transmission}": ["p(95)<200"], | ||
"http_reqs{name:create transmission}": [] | ||
} | ||
}; | ||
|
||
const traceCalls = (__ENV.traceCalls ?? 'false') === 'true'; | ||
const numberOfTransmissions = (__ENV.numberOfTransmissions ?? '10'); | ||
const maxTransmissionsInThread = (__ENV.maxTransmissionsInThread ?? '100'); | ||
const testid = (__ENV.TESTID ?? 'createTransmissions'); | ||
|
||
export default function() { | ||
createTransmissions(serviceOwners[0], randomItem(endUsers), traceCalls, numberOfTransmissions, maxTransmissionsInThread, testid); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters