Skip to main content

Easy to use IPC library

Project description

Easy to use IPC library

Sometimes there is no need for complicated blazingly fast connections with incredible throughput and even more incredible configuration. You just want made your processes communicate with each other. And that's what this library for.

Idea

There is two main entities: Client and Server, which uses Connectors to create Connections.

The only way client and server differs is who initiate a connection. After successful connect there is no difference between them, any side can make requests to other.

Entities

Pairs of Client and Server entities.

Entity Description
Simple These entities have only one handler and two operations: request (send message, wait response, return it) and throw (send message and notify responder, that response can be dropped). They use Serializers to serialize request data.
Route Similar to simple, but have multiple handlers, identified by exact string match.

Connectors:

Things which making connections. Connector can be serialized and passed to other processes, e.g. parent process creates connector, run server with it and start childs, which run clients with same connector.

Connector Description
LocalConnector Uses Named Pipes on Windows and Unix domain sockets on other systems, if available. This is similar to multiprocessing's connection, but LocalConnector doesn't fallback to TCP.
TcpConnector Uses TCP/IP protocol.
RmqConnector Uses AMQP message broker, can be scaled.

Extras

You can install additional dependencies for various features

pip install communica[extraname1, extraname2]

Extra name Feature
orjson Faster JSON library, recommended with CPython.
rabbitmq RmqConnector, which use AMQP server for communication.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

communica-0.3.2.post1.tar.gz (32.9 kB view details)

Uploaded Source

Built Distribution

communica-0.3.2.post1-py3-none-any.whl (40.1 kB view details)

Uploaded Python 3

File details

Details for the file communica-0.3.2.post1.tar.gz.

File metadata

  • Download URL: communica-0.3.2.post1.tar.gz
  • Upload date:
  • Size: 32.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.27.1 setuptools/56.0.0 requests-toolbelt/0.9.1 tqdm/4.65.0 CPython/3.8.10

File hashes

Hashes for communica-0.3.2.post1.tar.gz
Algorithm Hash digest
SHA256 f0eb041fe29c5e5c82422c185b890e93cafa5082fa5c5f8540237972dd9e3126
MD5 12a78b12cb5b5e7f01d7a5cbd0a3aa5c
BLAKE2b-256 6178163fde9edc10774f2d5cce5d76cdb5d57398d2faa09e298717591220c505

See more details on using hashes here.

File details

Details for the file communica-0.3.2.post1-py3-none-any.whl.

File metadata

  • Download URL: communica-0.3.2.post1-py3-none-any.whl
  • Upload date:
  • Size: 40.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.27.1 setuptools/56.0.0 requests-toolbelt/0.9.1 tqdm/4.65.0 CPython/3.8.10

File hashes

Hashes for communica-0.3.2.post1-py3-none-any.whl
Algorithm Hash digest
SHA256 bfe3607d2db5271bcb32720cede9634858b7e627b511e984bcb8169f5d2e8e61
MD5 b6af20fb726b8950aa67f32a51ebce2f
BLAKE2b-256 150165e7ce209a162fadc5363e3097b160c3b9a5d6c720edc39db3f1d03c0f05

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page