Closed willscott closed 4 years ago
Is there any way to avoid adding this to the public interface?
a manual stub for flatfs can be added in go-datastore/fuzz
. It seems like since this repo a convention has emerged of naming the entry point NewDatastore
, with functional store-specific options, versus the implementation specific entry point used by flatfs currently.
I don't think we're going to be able to define a good abstraction here:
*interface{}
is not a friendly abstraction for options.interface{} was a placeholder for whatever option type we want - it could just as easily be a `ShardIdV1since that's the current option taken by flatfs. The point is to have it structured such that a
nil` parameter provides sane defaults, as in badger / leveldb / etc.
Point taken though, and I'll do this as a stub in the fuzz code.
the fuzzer defaults to instantiating datastore implementations using
NewDatastore
, and interface method present in most of the other datastore implementations. Proposing adding here for ease of fuzzing.