-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
121 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,26 @@ | ||
muck | ||
# Compiled Object files, Static and Dynamic libs (Shared Objects) | ||
bin | ||
pkg | ||
*.o | ||
*.a | ||
*.so | ||
|
||
# Folders | ||
_obj | ||
_test | ||
|
||
# Architecture specific extensions/prefixes | ||
*.[568vq] | ||
[568vq].out | ||
|
||
*.cgo1.go | ||
*.cgo2.c | ||
_cgo_defun.c | ||
_cgo_gotypes.go | ||
_cgo_export.* | ||
|
||
_testmain.go | ||
|
||
*.exe | ||
*.test | ||
*.prof |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2015 Matt Fellows | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Muxy | ||
|
||
Simulating real-world distributed system failures to improve resilience in your applications. | ||
|
||
## Introduction | ||
|
||
Muxy is a proxy that _mucks_ around with your system and application context, allowing you to simulate common failure scenarios from the perspective of an application under test - such as an API or a web application. | ||
|
||
If you are building a distributed system, Muxy can help you test your resilience and fault tolerance patterns | ||
|
||
## Installation | ||
|
||
Download a [release](https://github.com/mefellows/muxy/releases) for your platform | ||
and put it somewhere on the `PATH`. | ||
|
||
### On Mac OSX using Homebrew | ||
|
||
If you are using [Homebrew](http://brew.sh) you can follow these steps to install Muck: | ||
|
||
```bash | ||
brew install https://raw.githubusercontent.com/mefellows/muxy/master/scripts/muxy.rb | ||
``` | ||
|
||
### Using Go Get | ||
|
||
``` | ||
go get github.com/mefellows/muxy | ||
``` | ||
|
||
## Using Muxy | ||
|
||
1. Create an application | ||
2. Build in fault tolerence (e.g. using something like [Hystrix](https://github.com/Netflix/Hystrix)) | ||
3. Create integration tests | ||
1. Run Muxy configuring a *proxy* such as HTTP, and one or more *symptom*s such as network latency, partition or HTTP error | ||
2. Point your app at Muxy | ||
3. Run tests and check if system behaved as expected | ||
4. Profit! | ||
|
||
### Notes | ||
|
||
Muxy is a stateful system, and mucks with your low-level (system) networking interfaces and therefore cannot be run in parallel with other tests. | ||
It is also recommended to run within a container/virtual machine to avoid unintended consequences (like breaking Internet access from the host). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
box: tcnksm/gox | ||
build: | ||
steps: | ||
- setup-go-workspace | ||
- script: | ||
name: go get | ||
code: | | ||
go get -t ./... | ||
- script: | ||
name: go test | ||
code: | | ||
make test | ||
- script: | ||
name: Publish Coveralls | ||
code: goveralls -service="wercker.com" -coverprofile=profile.cov -repotoken $COVERALLS_TOKEN | ||
- script: | ||
name: gox build | ||
code: | | ||
XC_OS="linux darwin freebsd" XC_ARCH="386 amd64" make bin | ||
- tcnksm/zip: | ||
input: pkg | ||
output: $WERCKER_OUTPUT_DIR/dist | ||
deploy: | ||
steps: | ||
- tcnksm/ghr: | ||
token: $GITHUB_TOKEN | ||
version: $RELEASE_VERSION | ||
input: dist | ||
replace: true | ||
pre-release: $RELEASE_IS_DRAFT |