A binary data persistence layer built on top of persisty
Project description
Persisty Data
This is an addition to the persisty framework for handling binary data (File Uploads). The objective is to be compatible with third party services, including ones that use signed URLs for posting / reading (Such as S3).
Concepts
- DataItems represent the storage of binary data, with methods for reading and writing as well as obtaining meta such as file size, last modified and etag
- DataStores store data items, with higher level methods for copying efficiently
- DataStoreFactories handle authorization when creating create data stores, as well as providing methods for generating presigned urls meaning that the server may be bypassed completely in some implementations (such as S3)
Implementations
Chunk
The chunk implementation breaks up an item into chunks smaller than preset size and storing these using regular persisty.
Directory
The Directory Store stores data items as files within a directory on a hosted file system.
S3
The S3 Store stores data items as entries in an S3 bucket. It is unique in the stock implementations in that it also provides an S3 Data Store Factory rather than relying on the Hosted Data Store Factory used by other implementations for providing pre-signed read urls and Upload Forms.
- Reading Data
- Writing data
- Strategy for bypassing server using Signed URLs
- Example
Example
A variant of the persisty messenger example application demonstrates file upload.
Installing local development dependencies
python setup.py install easy_install "persisty-data[dev]"
Release Procedure
The typical process here is:
- Create a PR with changes. Merge these to main (The
Quality
workflows make sure that your PR meets the styling, linting, and code coverage standards). - New releases created in github are automatically uploaded to pypi
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file persisty-data-0.0.3.tar.gz
.
File metadata
- Download URL: persisty-data-0.0.3.tar.gz
- Upload date:
- Size: 28.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a671e5210a7d7fc18bd8ac7a8cd0323c89e1ed83b91062b28efe1f947df916b2 |
|
MD5 | c3c0d70bf2f015fb6ca2f53a7464d69e |
|
BLAKE2b-256 | 52e90c487764dc63a9a6a1f42d448af861303c7bda636024812d63d9a3bb2a6f |
File details
Details for the file persisty_data-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: persisty_data-0.0.3-py3-none-any.whl
- Upload date:
- Size: 42.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 585ae27cbe0deb9c06b0f3a55f0b633686c00c1442a7be6f3e16d2dfc0fa5742 |
|
MD5 | 3388baf67583bcca62cd8fafd4876f12 |
|
BLAKE2b-256 | 80f183d68cb1b4bc01895767d92d33f549dba54eadbae6a07418a0d6db0c0b6a |