nats_request_asap
Python function to return one or multiple responses to a NATS request as soon as possible.
Documentation
nats-request-asap.readthedocs.io
Installation
pip install nats_request_asap
Usage
One response
Return a single NATS Msg.
>>> import nats_request_asap
>>> nats_request_asap.req_asap(z, b'{"nodes": ["af9c"]}', timeout=5)
<Msg: subject='_INBOX.tdSY0nNLoa9bYPqw9moCwC' reply='' data='{"initial_...'>
Multiple responses
Return a list of NATS Msgs.
>>> nats_request_asap.req_asap(z, b'{"nodes": "all"}', expected=3, timeout=5)
[<Msg: subject='_INBOX.tdSY0nNLoa9bmNqw9moCwC' reply='' data='{"error": ...'>,
<Msg: subject='_INBOX.tdSY0nNLoa9bmNqw9moCwC' reply='' data='{"initial_...'>,
<Msg: subject='_INBOX.tdSY0nNLoa9bmNqw9moCwC' reply='' data='{"initial_...'>]
License
This project is under the MIT License. See LICENSE.txt.
Release files for nats-request-asap 0.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| nats-request-asap-0.2.2.tar.gz | 3.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| nats_request_asap-0.2.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 7.7 kB
Release files / nats-request-asap-0.2.2.tar.gz
| Download URL | nats-request-asap-0.2.2.tar.gz |
|---|---|
| Size | 3.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
db062fed189580804ded0c50155b9dac8108eec59c873069f7c1355b45f65d30
|
|
BLAKE2b-256 checksum How to use checksums |
6e3d11f5544b4c17ced71474628db5de4ea371150f14384a0dd776d28cbdd3df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
|
Release files / nats_request_asap-0.2.2-py3-none-any.whl
| Download URL | nats_request_asap-0.2.2-py3-none-any.whl |
|---|---|
| Size | 3.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bc1e194f9d3ac2ddb1947bbd8a756ae05d7320820d3f3cd7bb09814637da12e5
|
|
BLAKE2b-256 checksum How to use checksums |
df5f4dbba46ea5a9b044eec300a640986a97d0c8a0756d6244da73d5ba803639
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
|