filedb
Create a file that pretends to be a MongoDB collection. If you try to open the file, it will JSONify the collection and dump it back to you.
Why?
Because our enterprise database is file based, but our cloud based database isn’t.
…no really why?
Files are simpler and don’t break. The database operations we need to perform aren’t complicated and don’t require high performance. By using files there isn’t a database that can fail. There’s the added benefit that if customers want to use different types of databases for distributed systems, we can plug into any of them using a filedb (we just have to make something that dumps out JSON .
Quickstart
Install FUSE
Make sure you have FUSE installed.
Ubuntu: sudo apt-get install g++ libfuse-dev
Get mongo running
And you’ll need a collection with some data in it.
$ mongod
$ mongo
> use test
> db.people.insert({"username": "greg"})
> db.people.insert({"username": "phil"})
> db.people.insert({"username": "bob"})
> db.people.insert({"username": "samantha"})
Install filedb
$ pip install filedb
Running via python
$ filedb /tmp/tutorial/mnt/ mongodb://localhost:27017/test people
Open the file
$ cat /tmp/tutorial/mnt/db
[{ "_id": "52f104a7a0fb769e0cd0d1d4", "username": "greg" }
{ "_id": "52f104a9a0fb769e0cd0d1d5", "username": "phil" }
{ "_id": "52f104aca0fb769e0cd0d1d6", "username": "bob" }
{ "_id": "52f104aea0fb769e0cd0d1d7", "username": "samantha" }]
Running as a service
Upstart job.
# install the job
$ sudo cp -R overlay/* /
# or
$ wget https://raw2.github.com/yhat/filedb/master/overlay/etc/init/filedb.conf
$ sudo mv filedb.conf /etc/init/filedb.conf
# start the job
$ sudo start filedb
Metadata
Release files for filedb 0.2.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| filedb-0.2.3.tar.gz | 3.2 kB | Without provenance | Details for filedb-0.2.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| filedb-0.2.3-py2.7.egg | Legacy Egg format | - | - | Details for filedb-0.2.3-py2.7.egg |
Total release size: 8.4 kB
Release files / filedb-0.2.3.tar.gz
| Download URL | filedb-0.2.3.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
01f0b570365676fcdc1f9199e77075eba058d192ca14a3ca4115ff654b2dba70
|
|
BLAKE2b-256 checksum How to use checksums |
0b26b1f68f861f02f434c689a35e500425c583799baaad29b20266788fb88319
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / filedb-0.2.3-py2.7.egg
| Download URL | filedb-0.2.3-py2.7.egg |
|---|---|
| Size | 5.2 kB |
| Tags | Egg |
|
SHA-256 checksum How to use checksums |
f58668e78b0a7d0b63eac0330579edda97a0191a3b4cbb6e105e7c3728a3fd30
|
|
BLAKE2b-256 checksum How to use checksums |
f9b65a6419cb10c0593256a820186eb105f812c13b5838bd1ca4ec93513f14c7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for filedb 0.2.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.