hyperdrive
hyperdrive copied to clipboard
'sync' event on hyperdb branch
The hyperdb branch of hyperdrive doesn't emit a 'sync' event.
I put a temporary workaround in the branch of integration-tests that just does a setTimeout() for 1 second for now.
https://github.com/jimpick/integration-tests/blob/multiwriter/tests/dat/replicate-multiwriter.js#L32
@jimpick is the idea that the 'sync' event will emit whenever a hyperdrive is done syncing or replicating?
I think that's what it does on the master branch of hyperdrive.
I was talking with mafintosh in Oakland on Sunday, and apparently the plan is to merge the hyperdb-backend work into the master branch so there will be a single version of hyperdrive that works with both legacy and multiwriter archives.
thanks @jimpick . should the sync event be documented? I see it being emitted in the source code but not mentioned in the readme, but maybe it's intentionally undocumented?