Skip to content

Commit 706151c

Browse files
committed
chore: send msg every 5s
1 parent 6bfd658 commit 706151c

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

libp2p.nimble

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ skipDirs = @["tests", "examples", "Nim", "tools", "scripts", "docs"]
1010
requires "nim >= 2.0.0",
1111
"nimcrypto >= 0.6.0", "dnsclient >= 0.3.0 & < 0.4.0", "bearssl >= 0.2.5",
1212
"chronicles >= 0.11.0", "chronos >= 4.0.4", "metrics", "secp256k1", "stew >= 0.4.2",
13-
"websock >= 0.2.1", "unittest2", "results", "quic >= 0.5.2",
13+
"websock >= 0.2.1", "unittest2", "results", "quic >= 0.5.2", "redis",
1414
"https://github.com/vacp2p/nim-jwt.git#18f8378de52b241f321c1f9ea905456e89b95c6f"
1515

1616
let nimc = getEnv("NIMC", "nim") # Which nim compiler to use

quic.nim

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,11 @@ proc main() {.async.} =
199199

200200
info "Starting listening endpoint for publish controller"
201201

202+
while true:
203+
discard await gossipSub.publishNewMessage(50 * 1024, "test")
204+
await sleepAsync(5.seconds)
205+
206+
202207
await sleepAsync(2.days)
203208

204209
waitFor(main())

0 commit comments

Comments
 (0)