diff --git a/src/crane/worker.go b/src/crane/worker.go index bd7172d2594043f5f175c85cc63a35ae8637cba4..c7ab7e3a54ab8365f3df408779775a32e5b2c142 100644 --- a/src/crane/worker.go +++ b/src/crane/worker.go @@ -9,6 +9,7 @@ import ( "plugin" "strconv" "strings" + "time" "../failure" "../shared" @@ -90,6 +91,7 @@ func handleMasterRequest(conn net.Conn) { //conn.Write([]byte("Bolt received")) // fmt.Println(*boltInfo) } + time.Sleep(100 * time.Millisecond) } conn.Close() } diff --git a/src/shared/shared.go b/src/shared/shared.go index e01a514609f2b6dfc1ba9776d9f91e3744f1ee4b..e583b529f682e6d5511f37198e3f327cd6c16bf1 100644 --- a/src/shared/shared.go +++ b/src/shared/shared.go @@ -44,8 +44,8 @@ const NumFileReplicas = 4 // How long to wait to get the membership list from the introducer const IntroducerTimeout = 3 * time.Second const GrepTimeout = 5 * time.Second -const ACKTimeout = 4000 * time.Millisecond -const PingInterval = 3000 * time.Millisecond +const ACKTimeout = 3000 * time.Millisecond +const PingInterval = 6000 * time.Millisecond // Simulate false positives by dropping packets before they are sent out const FalsePosChance = 0.0