scylla-driver

Modern, highly tunable Python client for ScyllaDB and Apache Cassandra over CQL

SDK
PyPI
v3.29.11
82stars
Apache License 2.0

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
75/100Good
Development Activity100
Maintenance72
Community56
Maturity60
Momentum12

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
82/100Excellent
Architecture90
Code Quality88
Innovation82
Learning Curve66

scylla-driver is a modern, feature-rich, and highly tunable Python client library for ScyllaDB and Apache Cassandra, communicating exclusively over Cassandra’s binary protocol and CQL v3. Originally the DataStax Python Driver, it is now maintained by ScyllaDB and adds Scylla-specific optimizations such as shard awareness and tablet awareness on top of the mature Cassandra driver feature set.

It offers both synchronous and asynchronous execution APIs, prepared and batch statements, connection pooling, automatic node discovery and reconnection, configurable load-balancing and retry policies, and an integrated cqlengine object mapper, making it a complete toolkit for building Python applications against Scylla or Cassandra clusters.

What You Get

  • Synchronous and asynchronous execution APIs over CQL v3
  • Simple, prepared, and batch statements with request pipelining
  • Connection pooling, automatic node discovery, and reconnection
  • Configurable load-balancing and retry policies
  • Scylla shard and tablet awareness plus the integrated cqlengine object mapper

Common Use Cases

  • Building Python backends that read and write to ScyllaDB or Cassandra
  • Running high-throughput, shard-aware queries against a Scylla cluster
  • Modeling data with the cqlengine object mapper instead of raw CQL
  • Executing large batches or concurrent statements with tuned retry policies

Under The Hood

Architecture - The driver centers on the cassandra package with Cluster and Session objects that manage a control connection for topology/schema events, per-host connection pools, and pluggable load-balancing, retry, and reconnection policies; a concurrent module provides parallel execution helpers, and cqlengine adds an object-mapper layer. Scylla shard and tablet awareness let it route requests to the correct CPU core and data owner. Tech Stack - Predominantly Python (3.10-3.14) with performance-critical paths implemented in Cython and some C, pluggable event-loop backends (asyncio, libev, twisted, gevent), and optional compression/extension dependencies. Code Quality - This is a large, battle-tested codebase with 227 contributors, thousands of commits, extensive unit and integration test suites, CI workflows for build/docs/integration, and hosted documentation, reflecting production-grade maturity inherited from the DataStax lineage. API Design - The public API is well established and thoroughly documented: connect via Cluster, obtain a Session, and call execute/execute_async with statement objects, with the optional cqlengine mapper offering a higher-level modeling API for teams that prefer declarative schemas.

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search