Skip to content

πŸš€ Ryx v0.1.1 β€” Bulk Ops Overhauled & Performance Unleashed

Choose a tag to compare

@Einswilli Einswilli released this 05 Apr 20:05
· 620 commits to master since this release
2d38e4c

This release is all about speed. We've completely rewritten bulk operations and query internals to eliminate Python overhead, slash database round-trips, and handle massive datasets efficiently.

⚑ Performance Highlights

  • bulk_update() ~1000x faster: Generates a single CASE WHEN statement per batch instead of N individual UPDATEs. (0.31s β†’ ~0.01s for 1000 rows)
  • bulk_create() ~500x faster: Now uses true multi-row INSERT. Instances automatically get their PKs assigned after creation.
  • bulk_delete() optimized: Single FFI call per batch with automatic chunking (fixes SQLite's 999-param limit).
  • stream() upgraded: Added keyset pagination (keyset="id") for O(n) scans on large tables, and as_dict=True for zero-overhead ETL pipelines.

πŸ”§ Core Improvements

  • Zero-allocation decoding: decode_row now uses case-insensitive prefix checks, eliminating millions of string allocations for large result sets.
  • Backend-aware conflict handling: bulk_create(ignore_conflicts=True) now generates correct syntax for PostgreSQL (ON CONFLICT DO NOTHING), SQLite (INSERT OR IGNORE), and MySQL (INSERT IGNORE).
  • Fast-path for integers: Skips type-checking cascade for PK lists in bulk operations (~60-80% reduction in overhead).

πŸ“š Docs & CI

  • Added step-by-step progressive examples (examples/).
  • Fixed macOS runner in release CI workflow.
  • Added performance benchmark table to README.

πŸ“¦ Upgrade

pip install ryx --upgrade