Instead of using an ephemeral data store that regularly gets rebuilt during project development (the default database key/value store is great but gets blown away during re-installs), this introduces a file based key/value storage back-end. One that could persist for a long time in a private folder.

The first component of this solution is JSON storage. It defaults to store its data in /tmp/{collection_name}.json. This can be overridden by setting an ENV variable JSON_KEY_VALUE_DIRECTORY and point it to private files directory, or some other file system that the developer desires to use.

Furthermore, since this is an API module, and unless you want to whole scale replace all database state for the entire site, you'll need to replace individual state arguments. Use one of the methods documented at https://www.drupal.org/docs/8/api/services-and-dependency-injection/alte....

Supporting organizations: 
Initial Development

Project information

  • caution Minimally maintained
    Maintainers monitor issues, but fast responses are not guaranteed.
  • caution Maintenance fixes only
    Considered feature-complete by its maintainers.
  • Module categories: Developer Tools
  • Created by heddn on , updated
  • shieldStable releases for this project are covered by the security advisory policy.
    There are currently no supported stable releases.

Releases