Memory, SQLite, MySQL, and Redis checkpoint repositories for JHarness
Project description
jharness-repository
Official in-memory, SQLite, MySQL, and Redis implementations of the JHarness
RunRepository protocol.
# Memory and SQLite only
uv add jharness-repository
# Add exactly the remote drivers the application uses
uv add "jharness-repository[mysql]"
uv add "jharness-repository[redis]"
uv add "jharness-repository[mysql,redis]"
from jharness.repository import MemoryRunRepository
MySQL TLS is explicit and remains lazy with the optional driver:
from jharness.repository import MySQLRunRepository, MySQLTLS
repository = MySQLRunRepository(
host="mysql.internal",
user="jharness",
password=mysql_password,
database="jharness",
tls=MySQLTLS(ca="/etc/jharness/mysql-ca.pem"),
)
MySQLTLS always enables certificate verification and verifies the server identity by
default. Mutual TLS additionally accepts paired cert and key paths plus an optional
key_password. Omitting tls leaves TLS policy to the endpoint and PyMySQL defaults.
Standalone Redis and Redis Cluster use the same optional redis extra. Select the
cluster-aware client explicitly:
from jharness.repository import RedisRunRepository
repository = RedisRunRepository(
"redis://redis-cluster.internal:6379",
cluster=True,
key_prefix="production-agent",
)
In cluster mode, redis-py's RedisCluster client owns topology discovery and redirect
routing. Each run's three keys share one hash tag and therefore one slot; different
runs use different tags and can be distributed across slots. The default
cluster=False continues to use the standalone client.
The base installation has no database-driver dependency. MemoryRunRepository needs
no service, and SQLite uses Python's embedded sqlite3 module. MySQL and Redis load
their selected client only when that backend is initialized; there is no fallback or
compatibility driver. Their services remain supplied by the application, while the
JHarness development suite exercises them in disposable Docker containers.
All adapters consume kernel DurableCommit deltas. Memory shares immutable values;
SQLite, MySQL, and Redis store new history chunks under a v2 physical namespace and do
not read or migrate obsolete v1 data. Complete recovery remains available through
await repository.get_head(run_id).
The source, contracts, and release process are maintained in the JHarness repository.
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
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 jharness_repository-0.3.0.tar.gz.
File metadata
- Download URL: jharness_repository-0.3.0.tar.gz
- Upload date:
- Size: 26.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
770578ec11211d3e64714450cacf38445fc2bf8989b42801f1c3d411b5a8df38
|
|
| MD5 |
331424da3fb46a0faf3acf12374e210c
|
|
| BLAKE2b-256 |
7a9399702c5b51656ed9300fee58b24b0a4e6e0794c38cdbe2e40762a8c12359
|
Provenance
The following attestation bundles were made for jharness_repository-0.3.0.tar.gz:
Publisher:
release.yml on Ezio2000/jharness
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
jharness_repository-0.3.0.tar.gz -
Subject digest:
770578ec11211d3e64714450cacf38445fc2bf8989b42801f1c3d411b5a8df38 - Sigstore transparency entry: 2201106091
- Sigstore integration time:
-
Permalink:
Ezio2000/jharness@534abec13320690df4c08360bbf4f5cc3c9d7939 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/Ezio2000
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@534abec13320690df4c08360bbf4f5cc3c9d7939 -
Trigger Event:
push
-
Statement type:
File details
Details for the file jharness_repository-0.3.0-py3-none-any.whl.
File metadata
- Download URL: jharness_repository-0.3.0-py3-none-any.whl
- Upload date:
- Size: 30.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
35f3eafe6d577bf266edede1199403775de447bc263007ac298e5ac2a971bfc2
|
|
| MD5 |
820c9e99a9c864f185904c4b9c648753
|
|
| BLAKE2b-256 |
d1ff868105687f4d6e18b49508c63f7da95c8b3895077abd242238a11cf6624e
|
Provenance
The following attestation bundles were made for jharness_repository-0.3.0-py3-none-any.whl:
Publisher:
release.yml on Ezio2000/jharness
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
jharness_repository-0.3.0-py3-none-any.whl -
Subject digest:
35f3eafe6d577bf266edede1199403775de447bc263007ac298e5ac2a971bfc2 - Sigstore transparency entry: 2201106661
- Sigstore integration time:
-
Permalink:
Ezio2000/jharness@534abec13320690df4c08360bbf4f5cc3c9d7939 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/Ezio2000
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@534abec13320690df4c08360bbf4f5cc3c9d7939 -
Trigger Event:
push
-
Statement type: