32장. k6로 SLO를 실행 가능한 threshold로 만든다
k6 performance testing은 threshold와 scenario를 통해 성능 기준을 표현한다.
export const options = {
thresholds: {
http_req_failed: ['rate<0.01'],
http_req_duration: ['p(95)<500']
}
};
승인 없이 production load test를 하지 않는다. test data와 외부 결제 side effect를 격리한다. generator CPU/network 포화와 system 포화를 구분한다. 평균 대신 percentile과 오류·업무 성공을 본다.