KairCS - Small File Cloud System over Riak KV
===============================================
This project allows to put mostly immutable files (written once,
updated mostly never) on a Riak KV store, that are read sequentially
(no random access to a file is supported).
This project is not meant to be a substitute of Riak CS:
- There's a single file space in KairCS. No butcket, no users. It's
almost a file-system you can write to, that expects your files don't
change much.
- No encryption of data.
Architecture
============
KairCS is split in two main components:
- The KairCS Very Simple Blob Store
- The KairCS Service
KairCS Very Simple Blob Store (VSBS)
------------------------------------
It's responsible to actually manage the storage of blobs. It DOES NOT
keep a notion of directories so there's no way to list all the blobs
in the store. In fact, this layer support only two operations:
- Write a blob
- Read a blob from begin to end
The `KiarCS Service`_ leverage these function to provide *some*
support for listing and deletion.
When storing a blob, you must provide a name which is used to create a
*master key* of the blob. The master key is actually a SHA256 of the
blob name.
The blob is divided in chunks of 1 MB. Each chunk is stored
individually under an automatically generated key composed by the
blob's *master key* and a counter.
The first chunk contains both metadata and data. The metadata record
is like this::
record metadata {
uint8 metadata_size;
# The size of the metadata including this byte. Currently this
# is 1 + 8 bytes.
uint64 size_of_the_blob;
}
The maximum size of the first chunk is thus 1 MB plus 9 bytes. Other
chunks are just data and the size of the chunk is the size of the
data.
To write a blob you need the name and the size. To read a blob you
just need the name.
VSBS store the chunks in Riak KV.
KiarCS Service
--------------
This is a high level component. It exposes a REST API over HTTP/1.1:
``GET /path/to/x``
Read the file or directory under the given path. It may return 404
if the file is not found.
.. todo:: If path is a directory, reply with a 300 Multiple Choices?
``PUT /path/to/a/file``
Create or replace the file under the given path.
If the given path exists and points to a directory, reply with a 400
Bad request.
This method creates the directories as needed.
Trying to upload large files may fail if the client does not support
chunked transfer.
The Content-Length header MUST be sent
.. todo:: Chunked response replies.
``DELETE /path/to/a/file``
Remove the file. Deleting a directory is not supported. If by
removing a file a directory becomes empty further requests for the
directory MAY get 404 responses.
Security
~~~~~~~~
RiakCS has no authentication mechanism. You must ensure that only
authoritative parties may reach the server. A common way to deploy it
is behind a nginx proxy
Configuration
-------------
When setting up a KiarCS cluster you must:
- Set up as many Riak KV nodes you need that match your space and RAM
requirement.
Join them in a cluster.
See the document `Configure Riak KV for KiarCS`.
- Set up Kiar CS nodes and connect them to the Riak KV nodes.
There're several possible configurations:
- 1 to 1.
- 1 to many.
See the document `KiarCS cluster layout`.
Copyright and license
=====================
Copyright (c) Merchise Autrement [~º/~] and Contributors.
This program is free software: you can redistribute it and/or modify
it under the terms of the :abbr:`GNU (GNU is Not Unix)` General Public
License as published by the Free Software Foundation, either version 3
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
the:abbr:`GNU (GNU is Not Unix)` General Public License for more
details. You should have received a copy of the :abbr:`GNU (GNU is
Not Unix)` General Public License along with this program. If not,
see http://www.gnu.org/licenses/.
..
Local Variables:
fill-column: 70
End:
Metadata
Release files for kaircs 0.4.0
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 | |
|---|---|---|---|---|
| kaircs-0.4.0.tar.gz | 119.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| kaircs-0.4.0-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details |
Total release size: 283.6 kB
Release files / kaircs-0.4.0.tar.gz
| Download URL | kaircs-0.4.0.tar.gz |
|---|---|
| Size | 119.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cfae6ef5717552ed4a2e7e92a92e1416dd305482044f90608c2f1109118f95d5
|
|
BLAKE2b-256 checksum How to use checksums |
ca5a01c3831a7edfffdd06057a479e6d436c7f71ecfe83824910d86268d82365
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.9.1 pkginfo/1.4.2 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.15.0 CPython/2.7.15rc1
|
Release files / kaircs-0.4.0-py2.py3-none-any.whl
| Download URL | kaircs-0.4.0-py2.py3-none-any.whl |
|---|---|
| Size | 164.0 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
ee6fff2abe7ea1d66a7f2be39b9b45cbff4e0f15b3ab05f3bf26d1d7717f1bd6
|
|
BLAKE2b-256 checksum How to use checksums |
6c5c1d7f90e81c0d3acbb8c199a8906a758f04deeaaf317fe0c6d2f665cfcbd5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.9.1 pkginfo/1.4.2 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.15.0 CPython/2.7.15rc1
|
Security for kaircs 0.4.0
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.