Client library for the pulsar-relay HTTP wire contract (auth, transport, device flow, topic management)
Project description
pulsar-relay-client
Python client for the pulsar-relay HTTP wire contract.
Used by:
- the Pulsar daemon's relay subscriber/auth layer
- Galaxy's BYOC (Bring-Your-Own-Compute) Pulsar manager
- pulsar-relay's own end-to-end tests
The package is the single source of truth for the relay wire contract; the
server (pulsar-relay) and the client (pulsar-relay-client) version
independently. A new client version that knows about a new wire feature
bumps the minor version; breaking changes bump major.
Modules
| Module | Public surface |
|---|---|
pulsar_relay_client.auth |
RelayAuthManager, PasswordAuthenticator, RefreshTokenAuthenticator, RelayAuthError |
pulsar_relay_client.credentials |
CredentialsFile, InMemoryCredentialsStore, utcnow_iso |
pulsar_relay_client.device_flow |
RelayDeviceFlowAuthenticator, DeviceFlowError (RFC 8628 + the pair=true extension) |
pulsar_relay_client.transport |
RelayTransport, RelayTransportError (HTTP + auth + cursor persistence) |
pulsar_relay_client.topics |
HttpRelayClient with create_or_verify_topic, the RelayClient Protocol (caller-facing typing surface), and the relay-error hierarchy. Topic naming conventions are the caller's concern. |
pulsar_relay_client.testing |
FakeRelayClient — in-memory implementation of the RelayClient Protocol for consumers writing tests against a fake. |
Installation
pip install pulsar-relay-client
Quick start
from pulsar_relay_client import RelayTransport
transport = RelayTransport(
"https://relay.example.org",
credentials_file="/etc/pulsar/relay_credentials.json",
cursor_path="/var/lib/pulsar/relay_cursor.json",
)
transport.post_message("job_status_update_my_manager", {"job_id": "j1", "state": "ok"})
messages = transport.long_poll(["job_setup_my_manager"], timeout=30)
Versioning
1.0.0— first standalone release. Wire features: device-flow withpair=true, chain-scoped revocation, topic create-or-verify-ownership, refresh-token rotation withInMemoryCredentialsStorecallback.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pulsar_relay_client-0.2.1.tar.gz.
File metadata
- Download URL: pulsar_relay_client-0.2.1.tar.gz
- Upload date:
- Size: 28.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9169f29aa7a30d58f1eb74f11dd8bf2013a9743dff66c4545db79eeebe240bd4
|
|
| MD5 |
b9647d7ef9cff1e6768202904492618b
|
|
| BLAKE2b-256 |
33e4b024c3b4171ba98dcc3a7390ceabc91b268c7f73e55dbebfc852e75d0dba
|
Provenance
The following attestation bundles were made for pulsar_relay_client-0.2.1.tar.gz:
Publisher:
release-client.yml on mvdbeek/pulsar-relay
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pulsar_relay_client-0.2.1.tar.gz -
Subject digest:
9169f29aa7a30d58f1eb74f11dd8bf2013a9743dff66c4545db79eeebe240bd4 - Sigstore transparency entry: 1523663178
- Sigstore integration time:
-
Permalink:
mvdbeek/pulsar-relay@38311d004ac9befada98fc8698e2a8be1a61b39c -
Branch / Tag:
refs/tags/client-v0.2.1 - Owner: https://github.com/mvdbeek
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-client.yml@38311d004ac9befada98fc8698e2a8be1a61b39c -
Trigger Event:
push
-
Statement type:
File details
Details for the file pulsar_relay_client-0.2.1-py3-none-any.whl.
File metadata
- Download URL: pulsar_relay_client-0.2.1-py3-none-any.whl
- Upload date:
- Size: 24.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eb3749b02faa93c8b7837e845362377329f3a0132928e6ec7c3d33c2c9af1eb1
|
|
| MD5 |
d56518c435ac61a665ac90850b65e4f7
|
|
| BLAKE2b-256 |
0484685c0e9731ae511c406542e2f98a3947fb48245020aecd743694120e4f6a
|
Provenance
The following attestation bundles were made for pulsar_relay_client-0.2.1-py3-none-any.whl:
Publisher:
release-client.yml on mvdbeek/pulsar-relay
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pulsar_relay_client-0.2.1-py3-none-any.whl -
Subject digest:
eb3749b02faa93c8b7837e845362377329f3a0132928e6ec7c3d33c2c9af1eb1 - Sigstore transparency entry: 1523663198
- Sigstore integration time:
-
Permalink:
mvdbeek/pulsar-relay@38311d004ac9befada98fc8698e2a8be1a61b39c -
Branch / Tag:
refs/tags/client-v0.2.1 - Owner: https://github.com/mvdbeek
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-client.yml@38311d004ac9befada98fc8698e2a8be1a61b39c -
Trigger Event:
push
-
Statement type: