WSGI-based RPC
Why this package?
- JSON-RPC is easy and fast, but you need to convert your arguments and return values to basic python types (strings, lists, dicts, etc)
- Pyro and RPyC are very powerful, but sometimes you don't need nor want every object to be proxied over sockets.
This package provides the ability to invoque methods on a remote object with pickable arguments and receiving a pickable object on return.
This module is about 70 lines of code and depends only on Python and requests package.
This implementation is supposed to be fast while being easy to understand.
Running the included example
The included example implements a program that mimics the Linux rev command.
The client program runs a loop that reads a line of text from stdin, sends it to
the server which reverses it and returns it back to the client, which prints it to stdout.
To run the example server with Python's wsgi reference implemetantion:
$ python example/server.py
To run the example server with gunicorn:
$ cd example && gunicorn -b localhost:5555 server:app
To run the client:
$ echo Hello world | python example/client.py
dlrow olleH
License
This Python module is licensed under the MIT license.
Metadata
Release files for wsgirpc 2.1.1
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 | Actions |
|---|---|---|---|---|
| wsgirpc-2.1.1.tar.gz | 2.6 kB | Without provenance | Details for wsgirpc-2.1.1.tar.gz |
Release files / wsgirpc-2.1.1.tar.gz
| Download URL | wsgirpc-2.1.1.tar.gz |
|---|---|
| Size | 2.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1bc7dd21c6b60a5c21be329ce76b7f52bcf57b62c618ac255c8a74cb687fab32
|
|
BLAKE2b-256 checksum How to use checksums |
508d310d43c7dfe1953f0e33d5cf12eeb37465758920249aaedd160d0c023ab5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3
|
Security for wsgirpc 2.1.1
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.