- where is time recorded?
- how do we unit test what values we have recorded?
- instrumentedResponseWriter does not support the http.CloseNotifier interface
| #!/bin/bash | |
| set -e -x | |
| apt-get install aufs-tools | |
| pushd $GOPATH_ROOT/src/github.com/cloudfoundry-incubator/warden-linux | |
| make # compile wshd/etc. | |
| export WARDEN_BINPATH=$PWD/linux_backend/bin | |
| popd |
if we modify storeadapter#compareAndSwapByIndex to return the new index, we can use this mechanism for our lifecycle/state machines:
type StoreAdapter interface {
CompareAndSwapByIndex(prevIndex uint64, newNode StoreNode) (newIndex uint64, err error)
}
This would allow our state machines to continue, even if the values changed (provided all versions of the model have a StoreIndex field that we can use). Doesn't solve the issue of our processes expecting the data to be in a different format that the model they currently have, but it does prevent model changes from messing up the state machine.
| ○ → brew install -v go --cross-compile-common | |
| ==> Downloading https://go.googlecode.com/files/go1.1.2.src.tar.gz | |
| Already downloaded: /Library/Caches/Homebrew/go-1.1.2.tar.gz | |
| tar xf /Library/Caches/Homebrew/go-1.1.2.tar.gz | |
| ==> ./make.bash --no-clean | |
| ./make.bash --no-clean | |
| # Building C bootstrap tool. | |
| cmd/dist | |
| # Building compilers and Go bootstrap tool for host, darwin/amd64. |
| function combinator(func,data,args){ | |
| new_args = [data].concat(args); | |
| return function(cb){ | |
| new_args.push(cb); | |
| func.apply(this,new_args); | |
| } | |
| } | |
| function getCell(data,row_id,col_id,cb){ |
| module.exports = test_data = { | |
| defaults:{ | |
| protocol: 'http', | |
| host: 'target-site.com', | |
| port: 80 | |
| }, | |
| requests:[ | |
| {method:'get', path:'/test', weight:200}, | |
| {method:'post', path:'/foo', body:'bar=false', weight:5}, | |
| {method:'post', path:'/bar', body:'foo=true', weight:10}, |