file Key-Value Store driver

The file driver uses the filesystem as a key-value store directly. A key directly specifies a path under a given root directory; the value is stored as the file contents.

Locking provided by the filesystem is used to safely allow concurrent access from multiple processes. (The locking protocol used does not block readers.) Provided that shared locking is supported, concurrent access from multiple machines to a network filesystem is also safe.

json kvstore/file : object

JSON specification of file-backed key-value store.

  • KvStore — Key-value store specification.

Required members:
driver : "file"
path : string

Path to root directory on local filesystem.

Optional members:
context : Context

Specifies context resources that augment/override the parent context.

file_io_concurrency : ContextResource

Specifies or references a previously defined Context.file_io_concurrency.

json KvStoreUrl/file : string

file:// KvStore URL scheme

File-based key-value stores may be specified using the widely-supported file://path URL syntax.


URL representation

JSON representation


{"driver": "file",
 "path": "/tmp/dataset/"}


{"driver": "file",
 "path": "C:/Users/abc/dataset/"}
  • KvStoreUrl — URL representation of a key-value store.



This driver is only supported on Windows 10 RS1 or later, due to its reliance on file operations with POSIX semantics.