Skip to main content

No project description provided

Project description

Grpc Orchestrator SDK

A gRPC-based implementation of the Saga pattern for distributed transactions.

Features

  • Transaction orchestration
  • Automatic compensation
  • gRPC interface
  • gRPC Connection
  • Memory storage backends

Installation

pip install grpc_orchestrator

Quick Start

from grpc_orchestrator.core.client.client import GrpcOrchestratorClient

client = GrpcOrchestratorClient(orchestrator_host="localhost")
steps = [
    {
        "port": 50052,
        "rpc_method": "CleateOrder",
        "compensation_method": "RollbackOrder",
        "timeout_seconds": 5,
    },
    {
        "port": 50052,
        "rpc_method": "CheckoutOrder",
        "compensation_method": "CheckoutOrder",
        "timeout_seconds": 5,
    },
]
client.start_transaction(transaction_id="1234",steps=steps,payload={
    "id": "1",
    "name":"item1"
})

status = client.get_transaction_status(transaction_id="order_123")
print(status)

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

grpc_orchestrator-0.0.3.tar.gz (10.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

grpc_orchestrator-0.0.3-py3-none-any.whl (14.6 kB view details)

Uploaded Python 3

File details

Details for the file grpc_orchestrator-0.0.3.tar.gz.

File metadata

  • Download URL: grpc_orchestrator-0.0.3.tar.gz
  • Upload date:
  • Size: 10.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.2

File hashes

Hashes for grpc_orchestrator-0.0.3.tar.gz
Algorithm Hash digest
SHA256 ac87d3a344684d166872b8b03e996e706492068d750124131b9d43bcf04285f5
MD5 cc2b8d92b4da3e99fc3cd5bb7842cff6
BLAKE2b-256 05fd0fa697f6b530603bd77617e7c0c140bddc9d1c471bf3055adf7799f25f81

See more details on using hashes here.

File details

Details for the file grpc_orchestrator-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for grpc_orchestrator-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e9d055be25d0a9bd9484bd6d3f1f3defe934a9c419b7b49a03af2f4862799635
MD5 38e73cc7d473be54af4ba6544009cb7b
BLAKE2b-256 90322865aea80bfd8c9ff04d2ca7147e9ab07fdbcfa5f4cd6953fc901dd13795

See more details on using hashes here.

Supported by

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