py-client
LokiDB python client SDK
Example
from random import randrange
from lokidb_sdk import Client
c = Client(
[
("localhost", 50051),
("localhost", 50052),
("localhost", 50053),
("localhost", 50054),
("localhost", 50055),
]
)
for _ in range(1000):
key = f'{randrange(-99999999, 99999999)}'
value = f'{randrange(-99999999, 99999999)}'*10
c.set(key, value)
print(c.get(key))
# Get all keys from all nodes
print(c.keys())
# Close connection to all nodes
c.close()
API
| Method | Input | Output |
|---|---|---|
| Get | key (str) | value (str) |
| Set | key (str), value (str) | |
| Del | key(str) | |
| Keys | list of keys (list[str]) | |
| Flush |
Release files for lokidb-sdk 0.1.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 | |
|---|---|---|---|
| lokidb_sdk-0.1.0.tar.gz | 4.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| lokidb_sdk-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 10.6 kB
Release files / lokidb_sdk-0.1.0.tar.gz
| Download URL | lokidb_sdk-0.1.0.tar.gz |
|---|---|
| Size | 4.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
62b66f2cd253486e325dbeb50c74d1b7031c8fd8b4164d6d0886bea56a90b124
|
|
BLAKE2b-256 checksum How to use checksums |
780a76a672b6125a3d3491092eda419805be2f8aa43e912eb532ae243603a19b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.0 CPython/3.8.10 Linux/5.15.0-46-generic
|
Release files / lokidb_sdk-0.1.0-py3-none-any.whl
| Download URL | lokidb_sdk-0.1.0-py3-none-any.whl |
|---|---|
| Size | 5.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f322493e6fd5988820de0db533a1f45eaacaf494404b0a1e9ef2f85fece17b41
|
|
BLAKE2b-256 checksum How to use checksums |
2578c37b3866f41bb2c138b1b6c6a03a1052eac3e7ffde99ec38640d430473ff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.0 CPython/3.8.10 Linux/5.15.0-46-generic
|