From 18491389befa91637ace284fed1bffbf0dec5ef4 Mon Sep 17 00:00:00 2001 From: Rongjian Lan Date: Tue, 26 Feb 2019 16:49:48 -0800 Subject: [PATCH] minor change --- cmd/harmony.go | 2 +- node/staking.go | 2 +- test/deploy.sh | 5 ++++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/cmd/harmony.go b/cmd/harmony.go index b6f962b72..87a2c6d7a 100644 --- a/cmd/harmony.go +++ b/cmd/harmony.go @@ -231,7 +231,7 @@ func main() { panic("unable to new host in harmony") } - log.Info("HARMONY", "multiaddress", fmt.Sprintf("/ip4/%s/tcp/%s/p2p/%s", *ip, *port, host.GetID().Pretty())) + log.Info("New Harmony Node...", "multiaddress", fmt.Sprintf("/ip4/%s/tcp/%s/p2p/%s", *ip, *port, host.GetID().Pretty())) host.AddPeer(&leader) diff --git a/node/staking.go b/node/staking.go index e4f35727f..780e82906 100644 --- a/node/staking.go +++ b/node/staking.go @@ -43,7 +43,7 @@ func (node *Node) UpdateStakingList(block *types.Block) error { //This means its a new node that is staking the first time. node.CurrentStakes[currentSender] = value } - case withdrawFuncSignature: //withdaw, currently: 0x2e1a7d4d + case withdrawFuncSignature: //withdraw, currently: 0x2e1a7d4d value := decodeStakeCall(data) if isPresent { if node.CurrentStakes[currentSender] > value { diff --git a/test/deploy.sh b/test/deploy.sh index 9f3064994..f0ae08f16 100755 --- a/test/deploy.sh +++ b/test/deploy.sh @@ -154,14 +154,17 @@ NUM_NN=0 while IFS='' read -r line || [[ -n "$line" ]]; do IFS=' ' read ip port mode shardID <<< $line if [ "$mode" == "leader" ]; then + echo "launching leader ..." $DRYRUN $ROOT/bin/harmony -ip $ip -port $port -log_folder $log_folder $DB -min_peers $MIN $HMY_OPT $HMY_OPT2 $HMY_OPT3 -key /tmp/$ip-$port.key -is_leader 2>&1 | tee -a $LOG_FILE & fi if [ "$mode" == "validator" ]; then + echo "launching validator ..." $DRYRUN $ROOT/bin/harmony -ip $ip -port $port -log_folder $log_folder $DB -min_peers $MIN $HMY_OPT $HMY_OPT2 $HMY_OPT3 -key /tmp/$ip-$port.key 2>&1 | tee -a $LOG_FILE & fi sleep 0.5 if [[ "$mode" == "newnode" && "$SYNC" == "true" ]]; then - (( NUM_NN += 35 )) + (( NUM_NN += 10 )) + echo "launching new node ..." (sleep $NUM_NN; $DRYRUN $ROOT/bin/harmony -ip $ip -port $port -log_folder $log_folder $DB -min_peers $MIN $HMY_OPT $HMY_OPT2 $HMY_OPT3 -key /tmp/$ip-$port.key 2>&1 | tee -a $LOG_FILE ) & fi done < $config