https://github.com/form3tech-oss/form3-toxies
custom Toxiproxy toxies
https://github.com/form3tech-oss/form3-toxies
Last synced: about 2 months ago
JSON representation
custom Toxiproxy toxies
- Host: GitHub
- URL: https://github.com/form3tech-oss/form3-toxies
- Owner: form3tech-oss
- License: apache-2.0
- Created: 2022-02-23T15:11:40.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-04-13T09:57:04.000Z (about 3 years ago)
- Last Synced: 2025-01-27T05:58:27.585Z (over 1 year ago)
- Language: Go
- Homepage:
- Size: 9.9 MB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# form3-toxies
A custom [Toxiproxy](https://github.com/Shopify/toxiproxy) binary containing a few additional [custom toxics](https://github.com/Shopify/toxiproxy/blob/master/CREATING_TOXICS.md) (described below).
## Usage
### Docker
A docker image is available on [Docker Hub](https://hub.docker.com/r/form3tech/form3-toxies).
```
$ docker pull docker pull form3tech/form3-toxies
$ docker run --rm -it form3tech/form3-toxies`
```
The default Toxiproxy http API port is 8474. This will need to be mapped in order to configure Toxiproxy via the API.
## Custom Toxics
See the [Toxiproxy README](https://github.com/Shopify/toxiproxy) for details on configuring toxics.
### psql
Inject failure into a postgres connection, the failure can be triggered after a predefined number of
SQL statements have been sent to the server.
Attributes:
* `failure_type` - set to `ConnectionFailure` or `SyntaxError`. `ConnectionFailure` will terminate the connection, possibly
causing retries depending on client implementation**. `SyntaxError` will inject a bad SQL statement into the connection
causing a soft failure.
* `search_text` - regular expression used to match SQL statements
* `fail_on` - number of statements matching `search_text` to trigger failure on
* `recover_after` - number of statements matching `search_text` to trigger recovery after
** The golang psql client implementation will automatically retry on this type of failure.