How maheshpulivarthi18/postgres-connector works
Oceanic Postgres ORM is an async Python ORM over PostgreSQL. Applications declare typed models and filters, then call the connector for CRUD or streaming; it builds SQL, executes through a connection pool, hydrates model instances, and batch-resolves requested relations. Separate capabilities cover additive migrations, transactions, stored procedures, and PostgreSQL Pub/Sub. The map emphasizes these product stages; several links rely on the connector’s SOURCE INDEX references or README rather than inspected call sites, so unsampled implementation details are not expanded.
Main entry points: connector.py ORM connector · model.py Typed models · pool.py Async connection pool · query_builder.py SQL query builder
Components 18
Models and filters
- Typed models
src/postgres_connector/model.py - Fields and relations
src/postgres_connector/fields.py - Model registry
src/postgres_connector/registry.py - Filter types
src/postgres_connector/types.py
Query runtime
- ORM connector
src/postgres_connector/connector.py - SQL query builder
src/postgres_connector/query_builder.py - Relation resolver
src/postgres_connector/relation_resolver.py - Async connection pool
src/postgres_connector/pool.py - Typed errors
src/postgres_connector/exceptions.py
Schema management
- Schema migrator
src/postgres_connector/migrator.py
Transactions
- Transaction context
src/postgres_connector/transaction.py
Database features
- Stored procedures
src/postgres_connector/procedures.py - Postgres Pub/Sub
src/postgres_connector/pool.py - Result streaming
src/postgres_connector/connector.py - Upsert operations
src/postgres_connector/connector.py - Row locking
src/postgres_connector/query_builder.py
Other components
- Application
- PostgreSQL
Connections 22
- Application → ORM connector: calls
README.md - Application → Typed models: declares
README.md - Typed models → Fields and relations: uses declarations
src/postgres_connector/model.py - Typed models → Model registry: registers models
src/postgres_connector/registry.py - Application → Filter types: provides filters
README.md - ORM connector → SQL query builder: builds SQL
src/postgres_connector/connector.py - ORM connector → Async connection pool: executes queries
src/postgres_connector/connector.py - Async connection pool → PostgreSQL: queries
src/postgres_connector/pool.py - ORM connector → Relation resolver: resolves includes
src/postgres_connector/connector.py - Relation resolver → Async connection pool: batch fetches
src/postgres_connector/relation_resolver.py - ORM connector → Typed models: hydrates rows
src/postgres_connector/connector.py - ORM connector → Typed errors: maps errors
src/postgres_connector/connector.py - ORM connector → Schema migrator: syncs schema
src/postgres_connector/connector.py - Schema migrator → Async connection pool: executes migrations
src/postgres_connector/migrator.py - ORM connector → Transaction context: creates context
src/postgres_connector/transaction.py - Transaction context → ORM connector: delegates ORM calls
src/postgres_connector/transaction.py - ORM connector → Stored procedures: calls procedures
src/postgres_connector/connector.py - ORM connector → Postgres Pub/Sub: offers notifications
README.md - Postgres Pub/Sub → PostgreSQL: LISTEN and NOTIFY
src/postgres_connector/pool.py - ORM connector → Result streaming: streams results
README.md - ORM connector → Upsert operations: upserts records
README.md - SQL query builder → Row locking: builds lock filters
README.md