1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-10 12:24:50 -05:00

Load tests (#2946)

This commit is contained in:
Matt Bishop
2023-05-19 16:46:17 -04:00
committed by GitHub
parent 662ac7f059
commit a1fb847233
4 changed files with 291 additions and 0 deletions

29
perf/load/login.js Normal file
View File

@ -0,0 +1,29 @@
import { authenticate } from "./helpers/auth.js";
const IDENTITY_URL = __ENV.IDENTITY_URL;
const CLIENT_ID = __ENV.CLIENT_ID;
const AUTH_USERNAME = __ENV.AUTH_USER_EMAIL;
const AUTH_PASSWORD = __ENV.AUTH_USER_PASSWORD_HASH;
export const options = {
ext: {
loadimpact: {
projectID: 3639465,
name: "Login",
},
},
stages: [
{ duration: "30s", target: 10 },
{ duration: "1m", target: 20 },
{ duration: "2m", target: 25 },
{ duration: "30s", target: 0 },
],
thresholds: {
http_req_failed: ["rate<0.01"],
http_req_duration: ["p(95)<3000"],
},
};
export default function (data) {
authenticate(IDENTITY_URL, CLIENT_ID, AUTH_USERNAME, AUTH_PASSWORD);
}