Closed Frando closed 4 years ago
Ah shoot. Thanks for finding the issue! I think I actually had this problem in the past.
I think injecting the feed into corestore somehow would probably be best.
Would probably need to copy-paste all the stuff here in the the SDK: https://github.com/andrewosh/corestore/blob/master/index.js#L368
Working on fixing this. Got hypercore working, having some trouble with hyperdrive because I'm doing some zany shit with it. 😂
Fixed in 2.0.0-7
Hiya, I was testing out the dat2-take-two branch. Looking good!
Hypercores created with the
{ persist: false }
option cannot be replicated at the moment. As they are created outside of the Corestore they are not injected into replication streams, ascorestore-swarm-networking
doesn't know about them.I'm not sure what the best fix is for this. Maybe doing a PR to corestore that would add support for a
persist
opt there? So that it could create hypercores with arandom-access-memory
storage but otherwise treat them exactly the same, so that they're part of the normal replication workflow. @andrewosh? Alternatively we'd need a way to dynamically inject hypercores intocorestore-swarm-networking
, that seems difficult though with its reliance on corestore's stream injection handling. A third option would be not to usecorestore-swarm-networking
and roll our own replication manager in the SDK, but then that would have to be maintained.