Working Block Polling for difficulty change in current block
Some coins changes difficulty over time in current block, and this makes block polling for CURRENT block difficulty in node-stratum-pool work for this change.
JobRebraodcastTimeout makes stratum server check for new difficulty, and if difficulty has changed, it will print it to nomp's log as " Block notification or difficulty change through RPC polling " and effectively send new work to miners, not just new job. If it hasn't changed, it still does update the current job id, but will not send a new work request to miners.
So this change to node-stratum-pool to include possible CURRENT block difficulty changes over time and send it as new work to pool miners does work. And it doesn't changes anything else in the code.
When a new block is found OR the current block difficulty changes, after a jobrebroadcasttimeout is called, it will now print " Block notification or Block difficulty change via RPC polling " instead of just " Block notification via RPC polling " .
I have tested this and confirms that it works.
https://github.com/Lightningcash-dev/node-stratum-pool
https://github.com/zone117x/node-stratum-pool/pull/171/commits/e0fc581a1e364fb62023831fd927182a95e9b1b6