LangGraph Checkpoint ScyllaDB
Implementation of a LangGraph CheckpointSaver that uses ScyllaDB.
Installation
pip install langgraph-checkpoint-scylladb
Usage
Sync
from cassandra.auth import PlainTextAuthProvider
from cassandra.cluster import Cluster, ExecutionProfile, EXEC_PROFILE_DEFAULT
from cassandra.policies import DCAwareRoundRobinPolicy
from langgraph.checkpoint.scylladb import ScyllaDBSaver
profile = ExecutionProfile(
load_balancing_policy=DCAwareRoundRobinPolicy(local_dc="AWS_US_EAST_1"),
)
cluster = Cluster(
contact_points=["node-0.example.scylla.cloud"],
port=9042,
auth_provider=PlainTextAuthProvider("scylla", "secret"),
execution_profiles={EXEC_PROFILE_DEFAULT: profile},
)
session = cluster.connect()
checkpointer = ScyllaDBSaver(session, keyspace="langgraph")
checkpointer.setup()
write_config = {"configurable": {"thread_id": "1", "checkpoint_ns": ""}}
read_config = {"configurable": {"thread_id": "1"}}
checkpointer.put(write_config, {...}, {}, {})
checkpointer.get(read_config)
list(checkpointer.list(read_config))
Async — from_conn_string
from langgraph.checkpoint.scylladb import ScyllaDBSaver
SCYLLADB_URI = "scylladb://scylla:secret@node-0.example.scylla.cloud:9042/langgraph?dc=AWS_US_EAST_1"
async with ScyllaDBSaver.from_conn_string(SCYLLADB_URI) as checkpointer:
await checkpointer.aput(write_config, {...}, {}, {})
await checkpointer.aget(read_config)
[c async for c in checkpointer.alist(read_config)]
The connection string format is:
scylladb://<user>:<password>@<host>:<port>/<keyspace>?dc=<datacenter>
The dc query parameter is required for ScyllaDB Cloud (enables DC-aware load balancing).
TTL
Checkpoints can be automatically expired by passing ttl (seconds):
checkpointer = ScyllaDBSaver(session, keyspace="langgraph", ttl=3600)
# or via from_conn_string
async with ScyllaDBSaver.from_conn_string(SCYLLADB_URI, ttl=3600) as checkpointer:
...
Schema
Two tables are created in the target keyspace:
| Table | Partition key | Clustering key |
|---|---|---|
checkpoints |
thread_id |
checkpoint_ns ASC, checkpoint_id DESC |
checkpoint_writes |
(thread_id, checkpoint_ns, checkpoint_id) |
task_id, idx |
The schema is intentionally query-first: every access pattern hits a full partition key with no ALLOW FILTERING.
Additional Links
Metadata
Release files for langgraph-checkpoint-scylladb 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| langgraph_checkpoint_scylladb-0.1.0.tar.gz | 82.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| langgraph_checkpoint_scylladb-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 90.1 kB
Release files / langgraph_checkpoint_scylladb-0.1.0.tar.gz
| Download URL | langgraph_checkpoint_scylladb-0.1.0.tar.gz |
|---|---|
| Size | 82.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6b32649deb988eb98db75c54eb2689475a257404d4b62c4d57ce8d5e4be1134f
|
|
BLAKE2b-256 checksum How to use checksums |
752f0b773d66055494effaed021faff1aed55b2adb3b9365a4169637ca768be9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Release files / langgraph_checkpoint_scylladb-0.1.0-py3-none-any.whl
| Download URL | langgraph_checkpoint_scylladb-0.1.0-py3-none-any.whl |
|---|---|
| Size | 7.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
28364d145575dd809b46ee1d25e38782c1e4245f3340f8f8eabacb98166ce82f
|
|
BLAKE2b-256 checksum How to use checksums |
5fd58f6aa4c6d83805e737078095c5081b51ee1e43e52c536eb9ebae49fb53c1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|