Metadata-Version: 2.4
Name: moat-kv
Version: 0.71.37
Summary: A distributed no-master key-value store
Author-email: Matthias Urlichs <matthias@urlichs.de>
Project-URL: homepage, https://m-o-a-t.org
Project-URL: repository, https://github.com/M-o-a-T/moat
Keywords: MoaT
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Information Technology
Classifier: Framework :: AsyncIO
Classifier: Framework :: Trio
Classifier: Operating System :: POSIX :: Linux
Classifier: Operating System :: MacOS :: MacOS X
Classifier: Operating System :: Microsoft :: Windows
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Database
Classifier: Topic :: Home Automation
Classifier: Topic :: System :: Distributed Computing
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: LICENSE.APACHE2
License-File: LICENSE.MIT
License-File: LICENSE.txt
Requires-Dist: asyncclick>=8.3
Requires-Dist: trio>=0.22
Requires-Dist: anyio>=4
Requires-Dist: range_set>=0.2
Requires-Dist: attrs>=22
Requires-Dist: asyncactor~=0.28.0
Requires-Dist: asyncscope>=0.10.4
Requires-Dist: jsonschema>=2.5
Requires-Dist: ruyaml>=0.89
Requires-Dist: PyNaCl>=1.3
Requires-Dist: moat-lib-diffiehellman~=0.13.7
Requires-Dist: moat-link~=0.10.1
Requires-Dist: psutil
Requires-Dist: simpleeval>=0.9.10
Requires-Dist: moat-mqtt~=0.42.18
Requires-Dist: moat-util~=0.64.0
Requires-Dist: exceptiongroup; python_version < "3.11"
Requires-Dist: moat-lib-codec~=0.4.20
Requires-Dist: moat-lib-config~=0.2.2
Requires-Dist: moat-lib-run~=0.2.2
Dynamic: license-file

# MoaT-KV

Welcome to [MoaT-KV](https://github.com/MoaT/moat-kv)!

% start synopsis
% start main

MoaT-KV is a master-less distributed key-value storage system. It
circumvents the CAP theorem (you can't have all of consistency, availablilty,
and fault tolerance) using the assumption that a key is typically changed
by one node only. It is thus resistant to partitioning and intended to be
always-on; it will not block or lose updates, even in a partitioned
network.

% end synopsis

MoaT-KV comes with several batteries included:

- Basic user management, pattern-based ACLs
- Strong typing, code- and/or `JSON Schema`-based
- Data mangling
- Background code execution
- Seamless recovery even if only one master is running

The underlying communication is based on MQTT. A Serf back-end is also
available. Others are easy to implement.

MoaT-KV was originally called "distkv".

## API

MoaT-KV offers an efficient msgpack-based interface to access data and to
change internal settings. Most configuration is stored inside MoaT-KV
itself.

Stored data are **not** forced to be strings or binary sequences, but can
be anything that `MsgPack` supports. Keys to storage are multi-level and
support string, integer/float, and tuple keys.

## Status

MoaT-KV is in end-of-life. There are a lot of corner cases that don't
have tests. Critical bugs may be fixed, but "real" development continues
in `MoaT-Link`.

% end main

## Non-Features

MoaT-KV does not support data partitioning. Every node stores the whole
data set and can instantly deliver mostly-uptodate data.

MoaT-KV does not have a disk-based storage backend. Periodic snapshots and
event logs can be used to quickly restore a system, if necessary.

## TODO

- clean up some of the more egregious command line mistakes
- create a page for showcase-ing subprojects (knx owfs akumuli …)
- improve Home Assistant integration
