Description
Mnemonix encodes the behaviour, lifecycle, and feature set of a key-value store behind a common GenServer interface, normalizes different store APIs like ETS, Redix, and Memcached to conform to that interface, polyfills stores lacking desirable features, and exposes access to them through a familiar Map API.
Mnemonix alternatives and similar packages
Based on the "ORM and Datamapping" category.
Alternatively, view Mnemonix alternatives based on common mentions on social networks and blogs.
-
memento
Simple + Powerful interface to the Mnesia Distributed Database 💾 -
paper_trail
Track and record all the changes in your database with Ecto. Revert back to anytime in history. -
ExAudit
Ecto auditing library that transparently tracks changes and can revert them. -
ecto_psql_extras
Ecto PostgreSQL database performance insights. Locks, index usage, buffer cache hit ratios, vacuum stats and more. -
arbor
Ecto elixir adjacency list and tree traversal. Supports Ecto versions 2 and 3. -
sqlitex
An Elixir wrapper around esqlite. Allows access to sqlite3 databases. -
boltun
Transforms notifications from the Postgres LISTEN/NOTIFY mechanism into callback execution -
sql_dust
Easy. Simple. Powerful. Generate (complex) SQL queries using magical Elixir SQL dust.
Access the most powerful time series database as a service
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Mnemonix or a related project?
README
Mnemonix
A unified interface to key/value stores.
Synopsis
Mnemonix
aims to help you:
- Get running with key/value stores with minimal ceremony
- Experiment with different key/value store backends for your application
- Allow end-users of your library liberty to choose their preferred backend
- Enable composing access to different key/value stores with different read/write strategies
It encodes the behaviour, lifecycle, and feature set of a key/value store behind a common GenServer
interface, normalizes different store APIs to conform to that interface, polyfills stores lacking features, and exposes access to them through a familiar Map
API.
Learn more about starting a store and manipulating it with the Mnemonix
API in the documentation.
Pronunciation: /nɛˈmɑːnɪks/
– noo-MAHN-icks
Mnemonic systems are techniques or strategies consciously used to improve memory. They help use information already stored in long-term memory to make memorization an easier task.
— Mnemonics, Wikipedia
Status
:thumbsup: | Continuous Integration | Test Coverage |
---|---|---|
Master | ||
Development |
Features
Naturally, Mnemonix
gives you Map
-style functions to manipulate various key/value stores. However, Mnemonix
also offers extra features beyond simple Map functions. Stores that don't natively support these features have the capability added through an Elixir polyfill, guaranteeing you can use and switch stores without worrying about what features they support under the hood.
Available features are:
Mnemonix.Features.Map
- The key/value manipulation you know and loveMnemonix.Features.Bump
- Increment/decrement integer valuesMnemonix.Features.Expiry
- Set entries to remove themselves from the store with a ttlMnemonix.Features.Enumerable
- Iterate over all key/value pairs in supported stores
Installation
Add Mnemonix
to your project's dependencies in its mix.exs
:
def deps do
[
# ...
{:mnemonix, "~> 0.10.0"},
# ...
]
end
Contributing
Pull requests are welcome and greatly appreciated!
Please submit them against the development
branch rather than master
––this allows useful changes to be finessed before release. The GitHub UI should do this by default.
Here are some useful commands if you've just forked the project and want to contribute:
mix deps.get
- Get development dependenciesmix test
- Run the test suitemix credo list
- Run static code analysis for style pointers on Elixir sourcemix dialyzer
- Run static code analysis for type checking on compiled BEAM bytecodemix coveralls.html
- Generate test suite coverage reportmix docs
- Generate documentation pagesmix inch
- Evaluate quality of documentationmix checks
- Run all of the above checks and analysesmix clean
- If any of the above stop behaving as expected
For more information on helping the development of Mnemonix, check out the contributing guide.
Notes
- Not to be confused with the mnemonicode library,
Mnemonex
.
*Note that all licence references and agreements mentioned in the Mnemonix README section above
are relevant to that project's source code only.