TMSP -> ABCI

This commit is contained in:
Ethan Buchman
2017-01-12 15:53:32 -05:00
parent 3a55339114
commit c147b41013
38 changed files with 208 additions and 206 deletions
+8 -8
View File
@@ -21,13 +21,13 @@ echo ""
###########################
# test using the tmsp-cli
# test using the abci-cli
###########################
echo "... testing query with tmsp-cli"
echo "... testing query with abci-cli"
# we should be able to look up the key
RESPONSE=`tmsp-cli query \"$KEY\"`
RESPONSE=`abci-cli query \"$KEY\"`
set +e
A=`echo $RESPONSE | grep '"exists":true'`
@@ -39,7 +39,7 @@ fi
set -e
# we should not be able to look up the value
RESPONSE=`tmsp-cli query \"$VALUE\"`
RESPONSE=`abci-cli query \"$VALUE\"`
set +e
A=`echo $RESPONSE | grep '"exists":true'`
if [[ $? == 0 ]]; then
@@ -50,13 +50,13 @@ fi
set -e
#############################
# test using the /tmsp_query
# test using the /abci_query
#############################
echo "... testing query with /tmsp_query"
echo "... testing query with /abci_query"
# we should be able to look up the key
RESPONSE=`curl -s 127.0.0.1:46657/tmsp_query?query=$(toHex $KEY)`
RESPONSE=`curl -s 127.0.0.1:46657/abci_query?query=$(toHex $KEY)`
RESPONSE=`echo $RESPONSE | jq .result[1].result.Data | xxd -r -p`
set +e
@@ -69,7 +69,7 @@ fi
set -e
# we should not be able to look up the value
RESPONSE=`curl -s 127.0.0.1:46657/tmsp_query?query=\"$(toHex $VALUE)\"`
RESPONSE=`curl -s 127.0.0.1:46657/abci_query?query=\"$(toHex $VALUE)\"`
RESPONSE=`echo $RESPONSE | jq .result[1].result.Data | xxd -r -p`
set +e
A=`echo $RESPONSE | grep '"exists":true'`
+4 -4
View File
@@ -65,9 +65,9 @@ function counter_over_grpc() {
rm -rf $TMROOT
tendermint init
echo "Starting counter_over_grpc"
counter --serial --tmsp grpc > /dev/null &
counter --serial --abci grpc > /dev/null &
pid_counter=$!
tendermint node --tmsp grpc > tendermint.log &
tendermint node --abci grpc > tendermint.log &
pid_tendermint=$!
sleep 5
@@ -81,11 +81,11 @@ function counter_over_grpc_grpc() {
rm -rf $TMROOT
tendermint init
echo "Starting counter_over_grpc_grpc (ie. with grpc broadcast_tx)"
counter --serial --tmsp grpc > /dev/null &
counter --serial --abci grpc > /dev/null &
pid_counter=$!
sleep 1
GRPC_PORT=36656
tendermint node --tmsp grpc --grpc_laddr tcp://localhost:$GRPC_PORT > tendermint.log &
tendermint node --abci grpc --grpc_laddr tcp://localhost:$GRPC_PORT > tendermint.log &
pid_tendermint=$!
sleep 5
+1 -1
View File
@@ -19,7 +19,7 @@ RUN make get_vendor_deps
COPY . $REPO
RUN go install ./cmd/tendermint
RUN bash scripts/install_tmsp_apps.sh
RUN bash scripts/install_abci_apps.sh
# expose the volume for debugging
VOLUME $REPO
+1 -1
View File
@@ -1,5 +1,5 @@
#! /bin/bash
# This is a sample bash script for a TMSP application
# This is a sample bash script for a ABCI application
cd app/
git clone https://github.com/tendermint/nomnomcoin.git
+1 -1
View File
@@ -8,7 +8,7 @@ BRANCH="master"
go get -d $TMREPO/cmd/tendermint
### DEPENDENCIES (example)
# cd $GOPATH/src/github.com/tendermint/tmsp
# cd $GOPATH/src/github.com/tendermint/abci
# git fetch origin $BRANCH
# git checkout $BRANCH
### DEPENDENCIES END
+1 -1
View File
@@ -12,7 +12,7 @@ fi
####################
LIBS_GO_TEST=(go-clist go-common go-config go-crypto go-db go-events go-merkle go-p2p)
LIBS_MAKE_TEST=(go-rpc go-wire tmsp)
LIBS_MAKE_TEST=(go-rpc go-wire abci)
for lib in "${LIBS_GO_TEST[@]}"; do