Skip to main content

Default adapters for Framework M (SQLAlchemy, Redis, Litestar)

Project description

Framework M Standard

PyPI version Python 3.12+ License: MIT GitLab Pipeline Status Code style: ruff

Default adapters for Framework M - batteries included.

Installation

pip install framework-m-standard

Or with uv:

uv add framework-m-standard

What's Included

Database Adapters

  • SQLAlchemy Repository - Generic repository implementation with async support
  • Schema Mapper - Automatic Pydantic → SQLAlchemy table generation
  • Migration System - Alembic integration with auto-migration detection
  • Unit of Work - Transaction management with optimistic concurrency control

Web Framework

  • Litestar Integration - REST API with automatic OpenAPI docs
  • Auth Guards - JWT authentication and permission checking
  • Exception Handlers - Consistent error responses

Cache & Events

  • Redis Cache - Distributed caching with TTL support
  • Redis Event Bus - Pub/sub for domain events

Background Jobs

  • Taskiq Integration - Background job processing with NATS JetStream
  • Outbox Pattern - Reliable event publishing

Supported Databases

Database Status
PostgreSQL ✅ Full support
SQLite ✅ For testing
MySQL 🔜 Planned

Usage

This package is typically used as a dependency of framework-m. For most applications, install the full framework-m package instead.

from framework_m_standard.adapters.db import GenericRepository
from framework_m_standard.adapters.cache import RedisCache
from framework_m_standard.adapters.web import create_litestar_app

License

MIT License - see LICENSE for details.

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

framework_m_standard-0.2.13.tar.gz (286.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

framework_m_standard-0.2.13-py3-none-any.whl (204.9 kB view details)

Uploaded Python 3

File details

Details for the file framework_m_standard-0.2.13.tar.gz.

File metadata

  • Download URL: framework_m_standard-0.2.13.tar.gz
  • Upload date:
  • Size: 286.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for framework_m_standard-0.2.13.tar.gz
Algorithm Hash digest
SHA256 5b32eeee9e8d17691bab0041b07e9b7d9acdeca23731536425afd5563403430c
MD5 541a37bc25d6bf8f7261f8ac9c324d86
BLAKE2b-256 1707779adde6a267957ed5aa52908cfe4ecb12693bbf61a7900cf1130142a7e8

See more details on using hashes here.

File details

Details for the file framework_m_standard-0.2.13-py3-none-any.whl.

File metadata

File hashes

Hashes for framework_m_standard-0.2.13-py3-none-any.whl
Algorithm Hash digest
SHA256 1d2c4671022b5fbb756df9c156d83b5744279cf504dbb186ec0401674499b7c2
MD5 0daa9eec31f35ad59d8c6a94988343c1
BLAKE2b-256 e6950fe5609accbf17cc7dafd956c76a1e414a783859df8da2631cbb4c05bc4a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page