diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2017-05-30 10:41:41 +0200 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2017-05-30 10:41:41 +0200 |
| commit | 1fa04d0c589e400d616c7e4e00b86a04f930cc82 (patch) | |
| tree | 7aead4f74fb019e5dfe22b30b5be6654be7e2f06 | |
| parent | 53a4a0d89571783b58b16d5cb76d69cdb4587f00 (diff) | |
| download | cruncher-1fa04d0c589e400d616c7e4e00b86a04f930cc82.tar.gz cruncher-1fa04d0c589e400d616c7e4e00b86a04f930cc82.zip | |
send notification before sleeping
| -rw-r--r-- | worker.js | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -139,15 +139,16 @@ if (LOGGLY_TOKEN) type: seq.QueryTypes.UPSERT }); + // notify web + // TODO notify for player too + await ch.publish("amq.topic", "global", new Buffer("points_update")); + if (SLOWMODE > 0) { logger.info("slowmode active, sleeping…", { wait: SLOWMODE }); await sleep(SLOWMODE * 1000); } // ack await Promise.map(msgs, async (m) => await ch.ack(m)); - // notify web - // TODO notify for player too - await ch.publish("amq.topic", "global", new Buffer("points_update")); profiler.done("crunched", { size: msgs.size }); } |
