Skip to content

Commit

Permalink
feat: added load testing scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
jjmchew committed Aug 18, 2024
1 parent 0b63395 commit 311d4b8
Show file tree
Hide file tree
Showing 25 changed files with 19,305 additions and 0 deletions.
39 changes: 39 additions & 0 deletions artillery/asciiart.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
config:
# This is a test server run by team Artillery
# It's designed to be highly scalable
target: http://asciiart.artillery.io:8080
phases:
- duration: 60
arrivalRate: 1
rampTo: 5
name: Warm up phase
- duration: 60
arrivalRate: 5
rampTo: 10
name: Ramp up load
- duration: 30
arrivalRate: 11
rampTo: 30
name: Spike phase
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/dino'
- get:
url: '/pony'
- get:
url: '/armadillo'
count: 100
4 changes: 4 additions & 0 deletions artillery/cleanup
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash

docker logs artillery > $1
docker container rm artillery
47 changes: 47 additions & 0 deletions artillery/paisley1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
config:
# baseline testing for basic UI endpoints
target: http://3.84.61.211
phases:
- duration: 60
arrivalRate: 1
rampTo: 1
name: Warm up phase
- duration: 60
arrivalRate: 5
rampTo: 1
name: Ramp up load
- duration: 30
arrivalRate: 11
rampTo: 1
name: Spike phase
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
48 changes: 48 additions & 0 deletions artillery/paisley2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
config:
# load testing for API endpoints
# - will keep ramping up numbers until it breaks "more"
target: http://3.84.61.211
phases:
- duration: 60
arrivalRate: 1
rampTo: 55
name: Warm up phase
- duration: 60
arrivalRate: 5
rampTo: 100
name: Ramp up load
- duration: 30
arrivalRate: 11
rampTo: 1000
name: Spike phase
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
43 changes: 43 additions & 0 deletions artillery/paisley3-1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
phases:
- duration: 60
arrivalCount: 100
name: Warm up phase
- duration: 60
arrivalCount: 5000
maxVusers: 1000
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
43 changes: 43 additions & 0 deletions artillery/paisley3-2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
phases:
- duration: 60
arrivalCount: 100
name: Warm up phase
- duration: 60
arrivalCount: 50000
maxVusers: 50000
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
43 changes: 43 additions & 0 deletions artillery/paisley3-3.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
phases:
- duration: 60
arrivalCount: 100
name: Warm up phase
- duration: 60
arrivalCount: 20000
maxVusers: 20000
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
ensure: {}
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
ensure:
thresholds:
- http.response_time.p99: 100
- http.response_time.p95: 75
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
38 changes: 38 additions & 0 deletions artillery/paisley3-4.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
phases:
- duration: 60
arrivalCount: 100
name: Warm up phase
- duration: 60
arrivalCount: 15000
maxVusers: 15000
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
apdex: {}
metrics-by-endpoint: {}
apdex:
threshold: 100
scenarios:
- flow:
- loop:
- get:
url: '/'
- get:
url: '/knowledge-bases'
- get:
url: '/chatbots'
# - post:
# url: '/api/query'
# json:
# chatbot_id: '66bfdb451fc3e5a1372b19ad'
# query: 'tell me about llms'
- get:
url: '/history'
- get:
url: '/metrics'
count: 1
30 changes: 30 additions & 0 deletions artillery/paisley4-1.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
phases:
- duration: 60
arrivalCount: 1
name: Warm up phase
- duration: 60
arrivalCount: 1
maxVusers: 1
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
# apdex: {}
metrics-by-endpoint: {}
# apdex:
# threshold: 100
scenarios:
- flow:
- get:
url: '/'
- get:
url: '/chatbots'
- post:
url: '/api/query'
json:
chatbot_id: '66bfdb451fc3e5a1372b19ad'
query: 'tell me about llms'
32 changes: 32 additions & 0 deletions artillery/paisley4-2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
config:
# 2nd baseline attempt
# - hopefully clearer concurrent users
target: http://3.84.61.211
http:
timeout: 20
phases:
- duration: 60
arrivalCount: 1
name: Warm up phase
- duration: 60
arrivalCount: 1
maxVusers: 1
name: Ramp up load
# Load & configure a couple of useful plugins
# https://docs.art/reference/extensions
plugins:
# apdex: {}
metrics-by-endpoint: {}
# apdex:
# threshold: 100
scenarios:
- flow:
- get:
url: '/'
- get:
url: '/chatbots'
- post:
url: '/api/query'
json:
chatbot_id: '66bfdb451fc3e5a1372b19ad'
query: 'tell me about llms'
Loading

0 comments on commit 311d4b8

Please sign in to comment.