A Conduit connector that can be configured to behave in unexpected ways to figure out how Conduit handles it.
Run make build
to build the connector.
Run make test
to run all the unit tests.
Each method of the connector can be configured to act in a certain way. Currently supported modes are:
success
- The connector method acts as expected (returns successfully).error
- The connector method returns an error with the message "chaos".block
- The connector method blocks forever and never returns.context-done
- The connector method blocks until the supplied context is closed, after that it returns the context error.panic
- The connector method panics.
Each source method can be configured to act as described in one of the modes.
For a list of methods and their descriptions
see sdk.Source
interface
. Note that the behavior of Parameters
can't be adjusted, because that method
is called before the connector receives the configuration.
name | description | required | default value |
---|---|---|---|
configureMode |
Controls the mode that the Configure method executes. | false | success |
openMode |
Controls the mode that the Open method executes. | false | success |
readMode |
Controls the mode that the Read method executes. | false | success |
ackMode |
Controls the mode that the Ack method executes. | false | success |
teardownMode |
Controls the mode that the Teardown method executes. | false | success |
Each destination method can be configured to act as described in one of the modes.
For a list of methods and their descriptions
see sdk.Destination
interface
. Note that the behavior of Parameters
can't be adjusted, because that method
is called before the connector receives the configuration.
name | description | required | default value |
---|---|---|---|
configureMode |
Controls the mode that the Configure method executes. | false | success |
openMode |
Controls the mode that the Open method executes. | false | success |
writeMode |
Controls the mode that the Write method executes. | false | success |
teardownMode |
Controls the mode that the Teardown method executes. | false | success |