Skip to content

Latest commit

 

History

History
47 lines (34 loc) · 834 Bytes

actions.md

File metadata and controls

47 lines (34 loc) · 834 Bytes

Chaos Proxy Actions

Below is a list of the available actions you can use to configure Chaos Proxy. See the contrib docs for proxy actions for how to add more!

Sleep

Sleep for n seconds before continuing to process the request.

  • Action name: sleep
  • Params: seconds (int)

Example:

name: sleep
params:
  - seconds: 5

Random Sleep

Sleep for a random interval between n and m seconds before continuing to process the request.

  • Action name: sleeprand
  • Params: from (int); to (int)

Example:

name: sleeprand
params:
  - from: 1
  - to: 10

Error

Return an HTTP error with a custom message.

  • Action name: httperror
  • Params: code (int); status (str)

Example:

name: httperror
params:
  - code: 500
  - status: Internal Server Error