LokiDB python client SDK
Project description
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 |
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
lokidb_sdk-0.1.0.tar.gz
(4.9 kB
view hashes)
Built Distribution
Close
Hashes for lokidb_sdk-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f322493e6fd5988820de0db533a1f45eaacaf494404b0a1e9ef2f85fece17b41 |
|
MD5 | e93b6f11d7c5a07317d78af97300dea7 |
|
BLAKE2b-256 | 2578c37b3866f41bb2c138b1b6c6a03a1052eac3e7ffde99ec38640d430473ff |