SYMBOL INDEX (401 symbols across 55 files) FILE: _examples/tests/db.go function setupDB (line 8) | func setupDB(addr, database string) (*pg.DB, error) { function createSchema (line 28) | func createSchema(db *pg.DB) error { function seed (line 45) | func seed(db *pg.DB) error { FILE: _examples/tests/db_test.go function DB (line 21) | func DB() *pg.DB { function connectDB (line 32) | func connectDB(addr string) *pg.DB { function init (line 40) | func init() { function populateProxies (line 47) | func populateProxies() { function runToxiproxyServer (line 69) | func runToxiproxyServer() { function TestSlowDBConnection (line 96) | func TestSlowDBConnection(t *testing.T) { function TestOutageResetPeer (line 111) | func TestOutageResetPeer(t *testing.T) { FILE: _examples/tests/main.go function main (line 11) | func main() { function run (line 19) | func run() error { function process (line 36) | func process(db *pg.DB) error { FILE: _examples/tests/models.go type User (line 5) | type User struct method String (line 11) | func (u User) String() string { type Story (line 15) | type Story struct method String (line 22) | func (s Story) String() string { FILE: _examples/toxics/debug_toxic.go type DebugToxic (line 20) | type DebugToxic struct method PrintHex (line 22) | func (t *DebugToxic) PrintHex(data []byte) { method Pipe (line 38) | func (t *DebugToxic) Pipe(stub *toxics.ToxicStub) { function main (line 59) | func main() { FILE: _examples/toxics/http_toxic.go type HttpToxic (line 21) | type HttpToxic struct method ModifyResponse (line 23) | func (t *HttpToxic) ModifyResponse(resp *http.Response) { method Pipe (line 27) | func (t *HttpToxic) Pipe(stub *toxics.ToxicStub) { function main (line 52) | func main() { FILE: api.go function stopBrowsersMiddleware (line 19) | func stopBrowsersMiddleware(next http.Handler) http.Handler { function timeoutMiddleware (line 29) | func timeoutMiddleware(next http.Handler) http.Handler { type ApiServer (line 33) | type ApiServer struct method Listen (line 53) | func (server *ApiServer) Listen(addr string) error { method Shutdown (line 75) | func (server *ApiServer) Shutdown() error { method Routes (line 91) | func (server *ApiServer) Routes() *mux.Router { method PopulateConfig (line 146) | func (server *ApiServer) PopulateConfig(filename string) { method ProxyIndex (line 162) | func (server *ApiServer) ProxyIndex(response http.ResponseWriter, requ... method ResetState (line 183) | func (server *ApiServer) ResetState(response http.ResponseWriter, requ... method ProxyCreate (line 204) | func (server *ApiServer) ProxyCreate(response http.ResponseWriter, req... method Populate (line 242) | func (server *ApiServer) Populate(response http.ResponseWriter, reques... method ProxyShow (line 276) | func (server *ApiServer) ProxyShow(response http.ResponseWriter, reque... method ProxyUpdate (line 296) | func (server *ApiServer) ProxyUpdate(response http.ResponseWriter, req... method ProxyDelete (line 333) | func (server *ApiServer) ProxyDelete(response http.ResponseWriter, req... method ToxicIndex (line 349) | func (server *ApiServer) ToxicIndex(response http.ResponseWriter, requ... method ToxicCreate (line 371) | func (server *ApiServer) ToxicCreate(response http.ResponseWriter, req... method ToxicShow (line 397) | func (server *ApiServer) ToxicShow(response http.ResponseWriter, reque... method ToxicUpdate (line 424) | func (server *ApiServer) ToxicUpdate(response http.ResponseWriter, req... method ToxicDelete (line 454) | func (server *ApiServer) ToxicDelete(response http.ResponseWriter, req... method Version (line 476) | func (server *ApiServer) Version(response http.ResponseWriter, request... method apiError (line 521) | func (server *ApiServer) apiError(resp http.ResponseWriter, err error)... constant wait_timeout (line 41) | wait_timeout = 30 * time.Second constant read_timeout (line 42) | read_timeout = 15 * time.Second function NewServer (line 45) | func NewServer(m *metricsContainer, logger zerolog.Logger) *ApiServer { type ApiError (line 487) | type ApiError struct method Error (line 492) | func (e *ApiError) Error() string { function newError (line 496) | func newError(msg string, status int) *ApiError { function joinError (line 500) | func joinError(err error, wrapper *ApiError) *ApiError { type proxyToxics (line 542) | type proxyToxics struct function proxyWithToxics (line 547) | func proxyWithToxics(proxy *Proxy) (result proxyToxics) { function proxiesWithToxics (line 553) | func proxiesWithToxics(proxies []*Proxy) (result []proxyToxics) { FILE: api_test.go function WithServer (line 23) | func WithServer(t *testing.T, f func(string)) { function TestRequestId (line 53) | func TestRequestId(t *testing.T) { function TestBrowserGets403 (line 72) | func TestBrowserGets403(t *testing.T) { function TestNonBrowserGets200 (line 95) | func TestNonBrowserGets200(t *testing.T) { function TestIndexWithNoProxies (line 114) | func TestIndexWithNoProxies(t *testing.T) { function TestCreateProxyBlankName (line 128) | func TestCreateProxyBlankName(t *testing.T) { function TestCreateProxyBlankUpstream (line 141) | func TestCreateProxyBlankUpstream(t *testing.T) { function TestPopulateProxy (line 152) | func TestPopulateProxy(t *testing.T) { function TestPopulateDefaultEnabled (line 187) | func TestPopulateDefaultEnabled(t *testing.T) { function TestPopulateDisabledProxy (line 219) | func TestPopulateDisabledProxy(t *testing.T) { function TestPopulateExistingProxy (line 253) | func TestPopulateExistingProxy(t *testing.T) { function TestPopulateWithBadName (line 319) | func TestPopulateWithBadName(t *testing.T) { function TestPopulateProxyWithBadDataShouldReturnError (line 357) | func TestPopulateProxyWithBadDataShouldReturnError(t *testing.T) { function TestPopulateAddToxic (line 413) | func TestPopulateAddToxic(t *testing.T) { function TestListingProxies (line 443) | func TestListingProxies(t *testing.T) { function TestCreateAndGetProxy (line 475) | func TestCreateAndGetProxy(t *testing.T) { function TestCreateProxyWithSave (line 503) | func TestCreateProxyWithSave(t *testing.T) { function TestCreateDisabledProxy (line 537) | func TestCreateDisabledProxy(t *testing.T) { function TestCreateDisabledProxyAndEnable (line 570) | func TestCreateDisabledProxyAndEnable(t *testing.T) { function TestDeleteProxy (line 619) | func TestDeleteProxy(t *testing.T) { function TestCreateProxyPortConflict (line 663) | func TestCreateProxyPortConflict(t *testing.T) { function TestCreateProxyNameConflict (line 689) | func TestCreateProxyNameConflict(t *testing.T) { function TestResetState (line 715) | func TestResetState(t *testing.T) { function TestListingToxics (line 763) | func TestListingToxics(t *testing.T) { function TestAddToxic (line 779) | func TestAddToxic(t *testing.T) { function TestAddMultipleToxics (line 810) | func TestAddMultipleToxics(t *testing.T) { function TestAddConflictingToxic (line 842) | func TestAddConflictingToxic(t *testing.T) { function TestAddConflictingToxicsMultistream (line 874) | func TestAddConflictingToxicsMultistream(t *testing.T) { function TestAddConflictingToxicsMultistreamDefaults (line 907) | func TestAddConflictingToxicsMultistreamDefaults(t *testing.T) { function TestAddToxicWithToxicity (line 941) | func TestAddToxicWithToxicity(t *testing.T) { function TestAddNoop (line 973) | func TestAddNoop(t *testing.T) { function TestUpdateToxics (line 1001) | func TestUpdateToxics(t *testing.T) { function TestRemoveToxic (line 1058) | func TestRemoveToxic(t *testing.T) { function TestVersionEndpointReturnsVersion (line 1094) | func TestVersionEndpointReturnsVersion(t *testing.T) { function TestInvalidStream (line 1113) | func TestInvalidStream(t *testing.T) { function AssertToxicExists (line 1127) | func AssertToxicExists( FILE: client/api_error.go type ApiError (line 12) | type ApiError struct method Error (line 17) | func (err *ApiError) Error() string { FILE: client/client.go type Client (line 18) | type Client struct method Version (line 45) | func (client *Client) Version() ([]byte, error) { method Proxies (line 50) | func (client *Client) Proxies() (map[string]*Proxy, error) { method NewProxy (line 72) | func (client *Client) NewProxy() *Proxy { method CreateProxy (line 80) | func (client *Client) CreateProxy(name, listen, upstream string) (*Pro... method Proxy (line 98) | func (client *Client) Proxy(name string) (*Proxy, error) { method Populate (line 119) | func (client *Client) Populate(config []Proxy) ([]*Proxy, error) { method AddToxic (line 146) | func (client *Client) AddToxic(options *ToxicOptions) (*Toxic, error) { method UpdateToxic (line 168) | func (client *Client) UpdateToxic(options *ToxicOptions) (*Toxic, erro... method RemoveToxic (line 192) | func (client *Client) RemoveToxic(options *ToxicOptions) error { method ResetState (line 210) | func (client *Client) ResetState() error { method get (line 215) | func (c *Client) get(path string) ([]byte, error) { method post (line 219) | func (c *Client) post(path string, body io.Reader) ([]byte, error) { method patch (line 223) | func (c *Client) patch(path string, body io.Reader) ([]byte, error) { method delete (line 227) | func (c *Client) delete(path string) error { method send (line 232) | func (c *Client) send(verb, path string, body io.Reader) ([]byte, erro... method validateResponse (line 260) | func (c *Client) validateResponse(resp *http.Response) error { function NewClient (line 27) | func NewClient(endpoint string) *Client { FILE: client/client_test.go function TestClient_Headers (line 11) | func TestClient_Headers(t *testing.T) { FILE: client/proxy.go type Proxy (line 13) | type Proxy struct method Save (line 28) | func (proxy *Proxy) Save() error { method Enable (line 58) | func (proxy *Proxy) Enable() error { method Disable (line 64) | func (proxy *Proxy) Disable() error { method Delete (line 72) | func (proxy *Proxy) Delete() error { method Toxics (line 81) | func (proxy *Proxy) Toxics() (Toxics, error) { method AddToxic (line 100) | func (proxy *Proxy) AddToxic( method UpdateToxic (line 134) | func (proxy *Proxy) UpdateToxic(name string, toxicity float32, attrs A... method RemoveToxic (line 164) | func (proxy *Proxy) RemoveToxic(name string) error { FILE: client/toxic.go type Attributes (line 7) | type Attributes type Toxic (line 9) | type Toxic struct type Toxics (line 17) | type Toxics type ToxicOptions (line 19) | type ToxicOptions struct FILE: cmd/cli/cli.go constant RED (line 19) | RED = "\x1b[31m" constant GREEN (line 20) | GREEN = "\x1b[32m" constant YELLOW (line 21) | YELLOW = "\x1b[33m" constant BLUE (line 22) | BLUE = "\x1b[34m" constant PURPLE (line 23) | PURPLE = "\x1b[35m" constant NONE (line 24) | NONE = "\x1b[0m" function color (line 27) | func color(color string) string { function main (line 81) | func main() { function cliCommands (line 107) | func cliCommands() []*cli.Command { function cliToxiSubCommands (line 163) | func cliToxiSubCommands() []*cli.Command { function cliToxiAddSubCommand (line 171) | func cliToxiAddSubCommand() *cli.Command { function cliToxiUpdateSubCommand (line 216) | func cliToxiUpdateSubCommand() *cli.Command { function cliToxiRemoveSubCommand (line 244) | func cliToxiRemoveSubCommand() *cli.Command { type toxiAction (line 261) | type toxiAction function withToxi (line 263) | func withToxi(f toxiAction) func(*cli.Context) error { function list (line 276) | func list(c *cli.Context, t *toxiproxy.Client) error { function inspectProxy (line 326) | func inspectProxy(c *cli.Context, t *toxiproxy.Client) error { function toggleProxy (line 376) | func toggleProxy(c *cli.Context, t *toxiproxy.Client) error { function createProxy (line 407) | func createProxy(c *cli.Context, t *toxiproxy.Client) error { function deleteProxy (line 429) | func deleteProxy(c *cli.Context, t *toxiproxy.Client) error { function parseToxicity (line 448) | func parseToxicity(c *cli.Context, defaultToxicity float32) (float32, er... function addToxic (line 461) | func addToxic(c *cli.Context, t *toxiproxy.Client) error { function updateToxic (line 483) | func updateToxic(c *cli.Context, t *toxiproxy.Client) error { function removeToxic (line 502) | func removeToxic(c *cli.Context, t *toxiproxy.Client) error { function parseToxicCommonParams (line 517) | func parseToxicCommonParams(context *cli.Context) (*toxiproxy.ToxicOptio... function parseUpdateToxicParams (line 532) | func parseUpdateToxicParams(c *cli.Context) (*toxiproxy.ToxicOptions, er... function parseAddToxicParams (line 548) | func parseAddToxicParams(c *cli.Context) (*toxiproxy.ToxicOptions, error) { function parseAttributes (line 581) | func parseAttributes(c *cli.Context, name string) toxiproxy.Attributes { function colorEnabled (line 599) | func colorEnabled(enabled bool) string { function enabledText (line 607) | func enabledText(enabled bool) string { type attribute (line 615) | type attribute struct type attributeList (line 620) | type attributeList function sortedAttributes (line 622) | func sortedAttributes(attrs toxiproxy.Attributes) attributeList { function listToxics (line 634) | func listToxics(toxics toxiproxy.Toxics, stream string) { function getArgOrFail (line 661) | func getArgOrFail(c *cli.Context, name string) (string, error) { function hint (line 670) | func hint(m string) { function errorf (line 676) | func errorf(m string, args ...interface{}) error { function printWidth (line 680) | func printWidth(col string, m string, numTabs int) { FILE: cmd/server/server.go type cliArguments (line 22) | type cliArguments struct function parseArguments (line 32) | func parseArguments() cliArguments { function main (line 53) | func main() { function run (line 62) | func run() error { function setupLogger (line 112) | func setupLogger() zerolog.Logger { FILE: collectors/common.go constant namespace (line 4) | namespace string = "toxiproxy" FILE: collectors/proxy.go type ProxyMetricCollectors (line 7) | type ProxyMetricCollectors struct method Collectors (line 15) | func (c *ProxyMetricCollectors) Collectors() []prometheus.Collector { function NewProxyMetricCollectors (line 19) | func NewProxyMetricCollectors() *ProxyMetricCollectors { FILE: collectors/runtime.go type RuntimeMetricCollectors (line 8) | type RuntimeMetricCollectors struct method Collectors (line 12) | func (c *RuntimeMetricCollectors) Collectors() []prometheus.Collector { function NewRuntimeMetricCollectors (line 16) | func NewRuntimeMetricCollectors() *RuntimeMetricCollectors { FILE: link.go type ToxicLink (line 24) | type ToxicLink struct method Start (line 70) | func (link *ToxicLink) Start( method read (line 116) | func (link *ToxicLink) read( method write (line 137) | func (link *ToxicLink) write( method AddToxic (line 171) | func (link *ToxicLink) AddToxic(toxic *toxics.ToxicWrapper) { method UpdateToxic (line 195) | func (link *ToxicLink) UpdateToxic(toxic *toxics.ToxicWrapper) { method RemoveToxic (line 202) | func (link *ToxicLink) RemoveToxic(ctx context.Context, toxic *toxics.... method Direction (line 281) | func (link *ToxicLink) Direction() string { function NewToxicLink (line 34) | func NewToxicLink( FILE: link_test.go function TestToxicsAreLoaded (line 19) | func TestToxicsAreLoaded(t *testing.T) { function TestStubInitializaation (line 25) | func TestStubInitializaation(t *testing.T) { function TestStubInitializaationWithToxics (line 45) | func TestStubInitializaationWithToxics(t *testing.T) { function TestAddRemoveStubs (line 86) | func TestAddRemoveStubs(t *testing.T) { function TestNoDataDropped (line 140) | func TestNoDataDropped(t *testing.T) { function TestToxicity (line 197) | func TestToxicity(t *testing.T) { function TestStateCreated (line 244) | func TestStateCreated(t *testing.T) { function TestRemoveToxicWithBrokenConnection (line 266) | func TestRemoveToxicWithBrokenConnection(t *testing.T) { FILE: metrics.go function NewMetricsContainer (line 12) | func NewMetricsContainer(registry *prometheus.Registry) *metricsContainer { type metricsContainer (line 21) | type metricsContainer struct method runtimeMetricsEnabled (line 28) | func (m *metricsContainer) runtimeMetricsEnabled() bool { method proxyMetricsEnabled (line 32) | func (m *metricsContainer) proxyMetricsEnabled() bool { method anyMetricsEnabled (line 37) | func (m *metricsContainer) anyMetricsEnabled() bool { method handler (line 43) | func (m *metricsContainer) handler() http.Handler { FILE: metrics_test.go function TestProxyMetricsReceivedSentBytes (line 20) | func TestProxyMetricsReceivedSentBytes(t *testing.T) { function TestRuntimeMetricsBuildInfo (line 57) | func TestRuntimeMetricsBuildInfo(t *testing.T) { type testWriteCloser (line 82) | type testWriteCloser struct method Close (line 86) | func (t *testWriteCloser) Close() error { function prometheusOutput (line 90) | func prometheusOutput(t *testing.T, apiServer *ApiServer, prefix string)... FILE: proxy.go type Proxy (line 19) | type Proxy struct method Start (line 73) | func (proxy *Proxy) Start() error { method Update (line 80) | func (proxy *Proxy) Update(input *Proxy) error { method Stop (line 104) | func (proxy *Proxy) Stop() { method listen (line 111) | func (proxy *Proxy) listen() error { method close (line 128) | func (proxy *Proxy) close() { method Differs (line 139) | func (proxy *Proxy) Differs(other *Proxy) (bool, error) { method freeBlocker (line 154) | func (proxy *Proxy) freeBlocker(acceptTomb *tomb.Tomb) { method server (line 169) | func (proxy *Proxy) server() { method RemoveConnection (line 226) | func (proxy *Proxy) RemoveConnection(name string) { type ConnectionList (line 37) | type ConnectionList struct method Lock (line 42) | func (c *ConnectionList) Lock() { method Unlock (line 46) | func (c *ConnectionList) Unlock() { function NewProxy (line 52) | func NewProxy(server *ApiServer, name, listen, upstream string) *Proxy { function start (line 233) | func start(proxy *Proxy) error { function stop (line 247) | func stop(proxy *Proxy) { FILE: proxy_collection.go type ProxyCollection (line 14) | type ProxyCollection struct method Add (line 26) | func (collection *ProxyCollection) Add(proxy *Proxy, start bool) error { method AddOrReplace (line 46) | func (collection *ProxyCollection) AddOrReplace(proxy *Proxy, start bo... method PopulateJson (line 74) | func (collection *ProxyCollection) PopulateJson( method Proxies (line 116) | func (collection *ProxyCollection) Proxies() map[string]*Proxy { method Get (line 128) | func (collection *ProxyCollection) Get(name string) (*Proxy, error) { method Remove (line 135) | func (collection *ProxyCollection) Remove(name string) error { method Clear (line 149) | func (collection *ProxyCollection) Clear() error { method getByName (line 164) | func (collection *ProxyCollection) getByName(name string) (*Proxy, err... function NewProxyCollection (line 20) | func NewProxyCollection() *ProxyCollection { FILE: proxy_collection_test.go function TestAddProxyToCollection (line 11) | func TestAddProxyToCollection(t *testing.T) { function TestAddTwoProxiesToCollection (line 29) | func TestAddTwoProxiesToCollection(t *testing.T) { function TestListProxies (line 44) | func TestListProxies(t *testing.T) { function TestAddProxyAndStart (line 62) | func TestAddProxyAndStart(t *testing.T) { function TestAddAndRemoveProxyFromCollection (line 80) | func TestAddAndRemoveProxyFromCollection(t *testing.T) { FILE: proxy_test.go function TestProxySimpleMessage (line 17) | func TestProxySimpleMessage(t *testing.T) { function TestProxyToDownUpstream (line 38) | func TestProxyToDownUpstream(t *testing.T) { function TestProxyBigMessage (line 53) | func TestProxyBigMessage(t *testing.T) { function TestProxyTwoPartMessage (line 76) | func TestProxyTwoPartMessage(t *testing.T) { function TestClosingProxyMultipleTimes (line 105) | func TestClosingProxyMultipleTimes(t *testing.T) { function TestStartTwoProxiesOnSameAddress (line 113) | func TestStartTwoProxiesOnSameAddress(t *testing.T) { function TestStopProxyBeforeStarting (line 123) | func TestStopProxyBeforeStarting(t *testing.T) { function TestProxyUpdate (line 145) | func TestProxyUpdate(t *testing.T) { function TestProxyUpdateWithHostname (line 182) | func TestProxyUpdateWithHostname(t *testing.T) { function TestRestartFailedToStartProxy (line 238) | func TestRestartFailedToStartProxy(t *testing.T) { function TestProxyDiffers (line 269) | func TestProxyDiffers(t *testing.T) { FILE: stream/direction.go type Direction (line 8) | type Direction method String (line 18) | func (d Direction) String() string { constant Upstream (line 13) | Upstream Direction = iota constant Downstream (line 14) | Downstream constant NumDirections (line 15) | NumDirections function ParseDirection (line 25) | func ParseDirection(value string) (Direction, error) { FILE: stream/direction_test.go function TestDirection_String (line 9) | func TestDirection_String(t *testing.T) { function TestParseDirection (line 36) | func TestParseDirection(t *testing.T) { FILE: stream/io_chan.go type StreamChunk (line 10) | type StreamChunk struct type ChanWriter (line 16) | type ChanWriter struct method Write (line 26) | func (c *ChanWriter) Write(buf []byte) (int, error) { method Close (line 34) | func (c *ChanWriter) Close() error { function NewChanWriter (line 20) | func NewChanWriter(output chan<- *StreamChunk) *ChanWriter { type ChanReader (line 40) | type ChanReader struct method SetInterrupt (line 53) | func (c *ChanReader) SetInterrupt(interrupt <-chan struct{}) { method Read (line 60) | func (c *ChanReader) Read(out []byte) (int, error) { function NewChanReader (line 48) | func NewChanReader(input <-chan *StreamChunk) *ChanReader { FILE: stream/io_chan_test.go function TestBasicReadWrite (line 10) | func TestBasicReadWrite(t *testing.T) { function TestReadMoreThanWrite (line 37) | func TestReadMoreThanWrite(t *testing.T) { function TestReadLessThanWrite (line 64) | func TestReadLessThanWrite(t *testing.T) { function TestMultiReadWrite (line 101) | func TestMultiReadWrite(t *testing.T) { function TestMultiWriteWithCopy (line 132) | func TestMultiWriteWithCopy(t *testing.T) { function TestStream_ReadCorrectness (line 156) | func TestStream_ReadCorrectness(t *testing.T) { function TestStream_ReadInterrupt (line 180) | func TestStream_ReadInterrupt(t *testing.T) { FILE: test/e2e/benchmark_test.go function BenchmarkDirect (line 34) | func BenchmarkDirect(b *testing.B) { function BenchmarkProxy (line 51) | func BenchmarkProxy(b *testing.B) { function BenchmarkDirectSmall (line 68) | func BenchmarkDirectSmall(b *testing.B) { function BenchmarkProxySmall (line 85) | func BenchmarkProxySmall(b *testing.B) { FILE: test/e2e/endpoint.go function handler1 (line 19) | func handler1(w http.ResponseWriter, r *http.Request) { function handler2 (line 29) | func handler2(w http.ResponseWriter, r *http.Request) { function main (line 39) | func main() { FILE: testhelper/tcp_server.go function NewTCPServer (line 9) | func NewTCPServer() (*TCPServer, error) { type TCPServer (line 21) | type TCPServer struct method Run (line 27) | func (server *TCPServer) Run() (err error) { method handle_connection (line 36) | func (server *TCPServer) handle_connection() (err error) { method Close (line 52) | func (server *TCPServer) Close() (err error) { function WithTCPServer (line 56) | func WithTCPServer(t *testing.T, block func(string, chan []byte)) { FILE: testhelper/tcp_server_test.go function TestSimpleServer (line 11) | func TestSimpleServer(t *testing.T) { FILE: testhelper/timeout_after.go function TimeoutAfter (line 8) | func TimeoutAfter(after time.Duration, f func()) error { FILE: testhelper/timeout_after_test.go function TestTimeoutAfter (line 10) | func TestTimeoutAfter(t *testing.T) { FILE: testhelper/upstream.go type Upstream (line 8) | type Upstream struct method listen (line 25) | func (u *Upstream) listen() { method accept (line 33) | func (u *Upstream) accept(ignoreData bool) { method Close (line 51) | func (u *Upstream) Close() { method Addr (line 55) | func (u *Upstream) Addr() string { function NewUpstream (line 14) | func NewUpstream(t testing.TB, ignoreData bool) *Upstream { FILE: toxic_collection.go type ToxicCollection (line 21) | type ToxicCollection struct method ResetToxics (line 47) | func (c *ToxicCollection) ResetToxics(ctx context.Context) { method GetToxic (line 59) | func (c *ToxicCollection) GetToxic(name string) *toxics.ToxicWrapper { method GetToxicArray (line 66) | func (c *ToxicCollection) GetToxicArray() []toxics.Toxic { method AddToxicJson (line 83) | func (c *ToxicCollection) AddToxicJson(data io.Reader) (*toxics.ToxicW... method UpdateToxicJson (line 134) | func (c *ToxicCollection) UpdateToxicJson( method RemoveToxic (line 162) | func (c *ToxicCollection) RemoveToxic(ctx context.Context, name string... method StartLink (line 186) | func (c *ToxicCollection) StartLink( method RemoveLink (line 208) | func (c *ToxicCollection) RemoveLink(name string) { method findToxicByName (line 215) | func (c *ToxicCollection) findToxicByName(name string) *toxics.ToxicWr... method chainAddToxic (line 227) | func (c *ToxicCollection) chainAddToxic(toxic *toxics.ToxicWrapper) { method chainUpdateToxic (line 246) | func (c *ToxicCollection) chainUpdateToxic(toxic *toxics.ToxicWrapper) { method chainRemoveToxic (line 263) | func (c *ToxicCollection) chainRemoveToxic(ctx context.Context, toxic ... function NewToxicCollection (line 30) | func NewToxicCollection(proxy *Proxy) *ToxicCollection { FILE: toxics/bandwidth.go type BandwidthToxic (line 13) | type BandwidthToxic struct method Pipe (line 18) | func (t *BandwidthToxic) Pipe(stub *ToxicStub) { function init (line 80) | func init() { FILE: toxics/bandwidth_test.go function TestBandwidthToxic (line 15) | func TestBandwidthToxic(t *testing.T) { function BenchmarkBandwidthToxic100MB (line 61) | func BenchmarkBandwidthToxic100MB(b *testing.B) { FILE: toxics/latency.go type LatencyToxic (line 9) | type LatencyToxic struct method GetBufferSize (line 15) | func (t *LatencyToxic) GetBufferSize() int { method delay (line 19) | func (t *LatencyToxic) delay() time.Duration { method Pipe (line 30) | func (t *LatencyToxic) Pipe(stub *ToxicStub) { function init (line 54) | func init() { FILE: toxics/latency_test.go function AssertDeltaTime (line 19) | func AssertDeltaTime(t *testing.T, message string, actual, expected, del... function DoLatencyTest (line 37) | func DoLatencyTest(t *testing.T, upLatency, downLatency *toxics.LatencyT... function TestUpstreamLatency (line 118) | func TestUpstreamLatency(t *testing.T) { function TestDownstreamLatency (line 122) | func TestDownstreamLatency(t *testing.T) { function TestFullstreamLatencyEven (line 126) | func TestFullstreamLatencyEven(t *testing.T) { function TestFullstreamLatencyBiasUp (line 130) | func TestFullstreamLatencyBiasUp(t *testing.T) { function TestFullstreamLatencyBiasDown (line 134) | func TestFullstreamLatencyBiasDown(t *testing.T) { function TestZeroLatency (line 138) | func TestZeroLatency(t *testing.T) { function TestLatencyToxicCloseRace (line 142) | func TestLatencyToxicCloseRace(t *testing.T) { function TestTwoLatencyToxics (line 178) | func TestTwoLatencyToxics(t *testing.T) { function TestLatencyToxicBandwidth (line 221) | func TestLatencyToxicBandwidth(t *testing.T) { FILE: toxics/limit_data.go type LimitDataToxic (line 6) | type LimitDataToxic struct method Pipe (line 14) | func (t *LimitDataToxic) Pipe(stub *ToxicStub) { method NewState (line 54) | func (t *LimitDataToxic) NewState() interface{} { type LimitDataToxicState (line 10) | type LimitDataToxicState struct function init (line 58) | func init() { FILE: toxics/limit_data_test.go function buffer (line 12) | func buffer(size int) []byte { function checkOutgoingChunk (line 20) | func checkOutgoingChunk(t *testing.T, output chan *stream.StreamChunk, e... function checkRemainingChunks (line 27) | func checkRemainingChunks(t *testing.T, output chan *stream.StreamChunk) { function check (line 33) | func check(t *testing.T, toxic *toxics.LimitDataToxic, chunks [][]byte, ... function TestLimitDataToxicMayBeRestarted (line 52) | func TestLimitDataToxicMayBeRestarted(t *testing.T) { function TestLimitDataToxicMayBeInterrupted (line 83) | func TestLimitDataToxicMayBeInterrupted(t *testing.T) { function TestLimitDataToxicNilShouldClosePipe (line 98) | func TestLimitDataToxicNilShouldClosePipe(t *testing.T) { function TestLimitDataToxicChunkSmallerThanLimit (line 113) | func TestLimitDataToxicChunkSmallerThanLimit(t *testing.T) { function TestLimitDataToxicChunkLengthMatchesLimit (line 120) | func TestLimitDataToxicChunkLengthMatchesLimit(t *testing.T) { function TestLimitDataToxicChunkBiggerThanLimit (line 127) | func TestLimitDataToxicChunkBiggerThanLimit(t *testing.T) { function TestLimitDataToxicMultipleChunksMatchThanLimit (line 136) | func TestLimitDataToxicMultipleChunksMatchThanLimit(t *testing.T) { function TestLimitDataToxicSecondChunkWouldOverflowLimit (line 144) | func TestLimitDataToxicSecondChunkWouldOverflowLimit(t *testing.T) { function TestLimitDataToxicLimitIsSetToZero (line 154) | func TestLimitDataToxicLimitIsSetToZero(t *testing.T) { FILE: toxics/noop.go type NoopToxic (line 4) | type NoopToxic struct method Pipe (line 6) | func (t *NoopToxic) Pipe(stub *ToxicStub) { function init (line 21) | func init() { FILE: toxics/reset_peer.go type ResetToxic (line 16) | type ResetToxic struct method Pipe (line 21) | func (t *ResetToxic) Pipe(stub *ToxicStub) { function init (line 36) | func init() { FILE: toxics/reset_peer_test.go constant msg (line 15) | msg = "reset toxic payload\n" function TestResetToxicNoTimeout (line 17) | func TestResetToxicNoTimeout(t *testing.T) { function TestResetToxicWithTimeout (line 21) | func TestResetToxicWithTimeout(t *testing.T) { function TestResetToxicWithTimeoutDownstream (line 33) | func TestResetToxicWithTimeoutDownstream(t *testing.T) { function checkConnectionState (line 45) | func checkConnectionState(t *testing.T, listenAddress string) { function resetTCPHelper (line 73) | func resetTCPHelper(t *testing.T, toxicJSON io.Reader) { FILE: toxics/slicer.go type SlicerToxic (line 12) | type SlicerToxic struct method chunk (line 31) | func (t *SlicerToxic) chunk(start int, end int) []int { method Pipe (line 51) | func (t *SlicerToxic) Pipe(stub *ToxicStub) { function init (line 83) | func init() { FILE: toxics/slicer_test.go function TestSlicerToxic (line 13) | func TestSlicerToxic(t *testing.T) { function TestSlicerToxicZeroSizeVariation (line 60) | func TestSlicerToxicZeroSizeVariation(t *testing.T) { FILE: toxics/slow_close.go type SlowCloseToxic (line 6) | type SlowCloseToxic struct method Pipe (line 11) | func (t *SlowCloseToxic) Pipe(stub *ToxicStub) { function init (line 32) | func init() { FILE: toxics/timeout.go type TimeoutToxic (line 8) | type TimeoutToxic struct method Pipe (line 13) | func (t *TimeoutToxic) Pipe(stub *ToxicStub) { method Cleanup (line 47) | func (t *TimeoutToxic) Cleanup(stub *ToxicStub) { function init (line 51) | func init() { FILE: toxics/timeout_test.go function WithEstablishedProxy (line 16) | func WithEstablishedProxy(t *testing.T, f func(net.Conn, net.Conn, *toxi... function TestTimeoutToxicDoesNotCauseHang (line 71) | func TestTimeoutToxicDoesNotCauseHang(t *testing.T) { function TestTimeoutToxicClosesConnectionOnRemove (line 97) | func TestTimeoutToxicClosesConnectionOnRemove(t *testing.T) { FILE: toxics/toxic.go type Toxic (line 26) | type Toxic interface type CleanupToxic (line 32) | type CleanupToxic interface type BufferedToxic (line 37) | type BufferedToxic interface type StatefulToxic (line 45) | type StatefulToxic interface type ToxicWrapper (line 50) | type ToxicWrapper struct type ToxicStub (line 61) | type ToxicStub struct method Run (line 81) | func (s *ToxicStub) Run(toxic *ToxicWrapper) { method WriteOutput (line 94) | func (s *ToxicStub) WriteOutput(p *stream.StreamChunk, d time.Duration... method InterruptToxic (line 110) | func (s *ToxicStub) InterruptToxic() bool { method Closed (line 120) | func (s *ToxicStub) Closed() bool { method Close (line 129) | func (s *ToxicStub) Close() { function NewToxicStub (line 70) | func NewToxicStub(input <-chan *stream.StreamChunk, output chan<- *strea... function Register (line 141) | func Register(typeName string, toxic Toxic) { function New (line 151) | func New(wrapper *ToxicWrapper) Toxic { function Count (line 168) | func Count() int { FILE: toxics/toxic_test.go function NewTestProxy (line 27) | func NewTestProxy(name, upstream string) *toxiproxy.Proxy { function WithEchoServer (line 42) | func WithEchoServer(t *testing.T, f func(string, chan []byte)) { function WithEchoProxy (line 86) | func WithEchoProxy( function ToxicToJson (line 105) | func ToxicToJson(t *testing.T, name, typeName, stream string, toxic toxi... function AssertEchoResponse (line 120) | func AssertEchoResponse(t *testing.T, client, server net.Conn) { function TestPersistentConnections (line 154) | func TestPersistentConnections(t *testing.T) { function TestToxicAddRemove (line 206) | func TestToxicAddRemove(t *testing.T) { function TestProxyLatency (line 270) | func TestProxyLatency(t *testing.T) { function BenchmarkProxyBandwidth (line 316) | func BenchmarkProxyBandwidth(b *testing.B) { function TestToxicStub_WriteOutput (line 363) | func TestToxicStub_WriteOutput(t *testing.T) { FILE: toxiproxy_test.go function NewTestProxy (line 17) | func NewTestProxy(name, upstream string) *toxiproxy.Proxy { function WithTCPProxy (line 32) | func WithTCPProxy( function AssertProxyUp (line 48) | func AssertProxyUp(t *testing.T, addr string, up bool) net.Conn {