https://github.com/saghul/pysophia
WIP: Python (CFFI) bindings for Sophia
https://github.com/saghul/pysophia
Last synced: over 1 year ago
JSON representation
WIP: Python (CFFI) bindings for Sophia
- Host: GitHub
- URL: https://github.com/saghul/pysophia
- Owner: saghul
- Created: 2013-09-22T23:00:11.000Z (almost 13 years ago)
- Default Branch: master
- Last Pushed: 2014-05-20T09:12:31.000Z (about 12 years ago)
- Last Synced: 2025-02-28T12:07:00.875Z (over 1 year ago)
- Language: Python
- Size: 148 KB
- Stars: 9
- Watchers: 5
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.rst
Awesome Lists containing this project
README
========
pysophia
========
Overview
========
pysophia is a Python (CFFI based) library wrapping the `Sophia library `_.
Sophia is a modern embeddable key-value database designed for a high load environment.
It has unique architecture that was created as a result of research and rethinking of primary algorithmical
constraints, associated with a getting popular Log-file based data structures, such as LSM-tree.
NOTE: pysophia is still in early development, not all features all implemented yet, see below.
Not (yet) implemented features
==============================
* Cursors
* Transactions
* Maybe some of the options from sp_ctl
API
===
The entire API is contained in a single class, unsurprisingly, ``Sophia``.
Creating (or opening an existing) database::
db = Sophia('myDB', flags=Sophia.FL_CREAT|Sofia.FL_RDWR)
Setting a value for a given key::
db.set('foo', 'bar')
Getting the value assigned to a key::
db.get('foo')
Deleting a key::
db.delete('foo')
Closing the database, all further operations will raise an exception::
db.close()
Author
======
Saúl Ibarra Corretgé
License
=======
Unless stated otherwise on-file pysophia uses the MIT license, check LICENSE and NOTICE files.
Contributing
============
If you'd like to contribute, fork the project, make a patch and send a pull
request. Have a look at the surrounding code and please, make yours look
alike :-) If you intend to contribute a new feature please contact the maintainer
beforehand in order to discuss the design.