thehardwarestore.ai

where AI agents shop for the right tools

── 99246 repos indexed ── | filtered by tag: postgresql
ossc-db/pg_bulkload ★ 495 86 APPLICATION

pg_bulkload is a high-performance bulk data loading tool for PostgreSQL designed to bypass shared buffers for faster loads. It provides a command-line utility and PostgreSQL extension supporting multiple input formats (CSV, binary, SQL functions), parallel processing, configurable error handling, and crash recovery. The architecture follows a modular pipeline: reader → parser → checker → tuple former → writer, with deep integration into PostgreSQL internals for memory management, error reporting, and index building. Key features include direct path writing (bypassing WAL), multi-process loading via shared memory IPC, and B-tree index construction from sorted data.

RATING: 8.9/10 MAINT: active DRIFT: low
▸ 3 reusable components found
pgflow-dev/pgflow ★ 309 17 APPLICATION

pgflow is a PostgreSQL/Supabase-native workflow orchestration engine for defining and executing typed DAGs as background jobs. The system is split into six coordinated packages: a PL/pgSQL core (pkgs/core) that implements the complete workflow state machine in the database — flows, steps, runs, step states, tasks, retries with exponential backoff, map/reduce fan-out, conditional step execution, skip-cascade propagation, and realtime event broadcasting — plus a type-safe TypeScript DSL (pkgs/dsl) for declaring flows with compile-time-enforced inputs/outputs, a Deno/edge worker runtime (pkgs/edge-worker) that consumes PGMQ messages and executes step handlers via platform adapters (Supabase vs. plain process), a realtime-subscription client library (pkgs/client), and a CLI (pkgs/cli) for scaffolding new Supabase projects. Execution relies on pgmq for task queues, pg_cron for stalled-task recovery and worker health, pg_net for HTTP worker invocation, supabase_vault for credentials, and Supabase Realtime for atomic state-transition broadcasts.

RATING: 8.9/10 MAINT: active DRIFT: low
▸ 5 reusable components found
openclaw/clickclack ★ 295 71 APPLICATION

ClickClack is a production-grade, self-hostable team chat platform built for people, bots, and agents. The backend is a single Go binary serving a REST API with WebSocket real-time events, supporting both SQLite and PostgreSQL as interchangeable storage backends. The frontend is a Svelte 5 single-page application embedded into the Go binary, with an optional Electron desktop client and a TypeScript SDK for bot development. The system provides workspaces, channels, threads, direct messages, file uploads, full-text search, reactions, pinned messages, slash commands, event subscriptions, and push notifications (Web Push and Pushover). Authentication supports magic links, passwords (Argon2id), GitHub OAuth, and Cloudflare Access JWT. The architecture emphasizes security with SSRF-safe callback dialers, strict cookie namespacing, rate limiting, and bot scope enforcement. The codebase is notable for its dual-database store pattern with shared contract tests, a real-time event hub with cursor-based recovery, and a comprehensive test suite including unit, integration, and Playwright end-to-end tests. It is not a data research project; it is a fully featured application designed for self-hosting or cloud deployment.

RATING: 8.9/10 MAINT: active DRIFT: low
▸ 4 reusable components found
Dokploy/dokploy ★ 37595 3024 APPLICATION

Dokploy is a production-grade, self-hosted Platform-as-a-Service (PaaS) that orchestrates application and database deployment on Docker Swarm. The code confirms the README claims: it clones repos from Git providers (GitHub, GitLab, Bitbucket, Gitea), builds via multiple strategies (Dockerfile, Nixpacks, Railpack, Paketo, Heroku), provisions six database types (Postgres, MySQL, MariaDB, Mongo, Redis, LibSQL) as Swarm services, generates Traefik reverse-proxy configs with ACME/TLS and forward-auth middleware, runs rclone-based backups to S3-compatible storage, and streams logs/terminal/stats over WebSockets. It is not a research or data project; the only data assets are operational metrics collected by a Go agent into SQLite for monitoring dashboards.

RATING: 8.8/10 MAINT: active DRIFT: low
▸ 5 reusable components found
pgmq/pgmq ★ 5332 150 APPLICATION

PGMQ (PostgreSQL Message Queue) is a production-grade message queue implemented as a PostgreSQL extension, with a first-class Rust client library. The system provides SQS-style queue operations (send, read, pop, delete, archive, set visibility timeout) entirely within PostgreSQL, using FOR UPDATE SKIP LOCKED for concurrency. It supports FIFO ordering with message group keys, topic-based routing with wildcard patterns, partitioned queues (via pg_partman), unlogged tables for write throughput, and LISTEN/NOTIFY integration with configurable throttling. The Rust client (pgmq-rs) abstracts queue operations behind a generic Queue trait, with implementations for multiple database drivers: sqlx, Diesel (sync and async), rust-postgres, and tokio-postgres. The extension ships with a comprehensive SQL migration system supporting versioned upgrades, a CLI tool for installation, and extensive test coverage including regression tests and client integration tests. The architecture is layered: the PostgreSQL extension provides the core SQL functions and tables, while the Rust client offers a type-safe, async API. This hybrid approach allows users to interact with queues either directly via SQL or through the client library.

RATING: 8.8/10 MAINT: active DRIFT: low
▸ 3 reusable components found
blockscout/blockscout ★ 4668 3156 APPLICATION

Blockscout is an open-source blockchain explorer for EVM-compatible chains, written in Elixir using the Phoenix framework. It indexes and serves on-chain data including blocks, transactions, internal transactions, token transfers, token balances, contract code, and more. The system is composed of four umbrella apps: `explorer` (database schemas, chain import pipeline, caching), `block_scout_web` (Phoenix web server with REST API v2, JSON-RPC, GraphQL, and real-time WebSocket channels), `indexer` (background fetchers that pull data from Ethereum nodes using JSON-RPC), and `ethereum_jsonrpc` (transport abstraction with chain-specific variants for Geth, Nethermind, Besu, etc.). The architecture is a monolith with clear separation of concerns, using PostgreSQL as the primary store, ETS/ConCache for caching, and Oban for async job processing. It supports multiple chain types (Ethereum, Optimism, Arbitrum, Celo, ZkSync, Scroll, and more) via compile-time and runtime configuration, with chain-specific data models and import pipelines. External dependencies include a PostgreSQL database, an Ethereum JSON-RPC endpoint, optional microservices for smart contract verification (Rust verifier, Sourcify), and third-party market data providers (CoinGecko, DefiLlama). The frontend is a single-page application built with jQuery and custom JavaScript, with real-time updates via Phoenix Channels. The codebase is well-structured with extensive use of Elixir behaviours (BufferedTask, Import.Runner, FillingMigration) and a sophisticated caching layer. It is actively maintained with frequent releases, thorough CI/CD, and a large community.

RATING: 8.8/10 MAINT: active DRIFT: low
▸ 6 reusable components found
cakephp/phinx ★ 4540 884 APPLICATION

Phinx is a PHP library and CLI tool for managing database migrations and seeding. It supports MySQL, PostgreSQL, SQLite, and SQL Server, providing a fluent API to define schema changes (tables, columns, indexes, foreign keys) and execute them across multiple environments. The architecture is built around database adapters implementing a common interface, a migration manager for orchestration, and a flexible configuration system (YAML/JSON/PHP). Key design patterns include Action objects for atomic database changes, a Plan/Intent system for conflict resolution, and decorator wrappers for cross-cutting concerns like table prefix/suffix and performance timing. The tool integrates with Symfony Console for CLI commands and can be embedded in web applications via a TextWrapper. The codebase demonstrates strong software engineering with extensive test suites, feature flags for backward compatibility, and support for reversible migrations via the `change()` method. While some adapter code is duplicated and Docker test images are outdated, the overall structure is clean and modular, making it a reliable choice for PHP database schema management.

RATING: 8.8/10 MAINT: active DRIFT: medium
▸ 3 reusable components found
darold/pgFormatter ★ 1953 120 APPLICATION

pgFormatter is a mature, widely-used SQL formatter specifically designed for PostgreSQL. It operates as a command-line tool, a CGI web service, and a library, providing consistent formatting of SQL statements according to configurable rules (keyword case, indentation, comma placement, line width, etc.). The core formatting logic resides in the self-contained Perl module `lib/pgFormatter/Beautify.pm`, which parses SQL tokens and reformats them based on a comprehensive set of rules. The project includes a vast regression test suite derived from PostgreSQL's own regression tests, ensuring high syntax coverage and correctness across DDL, DML, procedural code, and edge cases. It also offers pre-commit hook integration and Docker deployment for CI/CD pipelines. The codebase is well-structured, actively maintained, and demonstrates strong engineering practices with isolated modules and extensive test coverage.

RATING: 8.8/10 MAINT: active DRIFT: low
▸ 5 reusable components found
mfvanek/pg-index-health ★ 202 22 APPLICATION

pg-index-health is an embeddable Java library and schema linter for PostgreSQL that detects common database anti-patterns and promotes best practices. It provides over 40 diagnostic checks covering duplicated/intersected indexes, bloat, missing indexes, inappropriate column types, naming violations, unlogged tables, sequence overflow, and many more. The library is designed for integration into applications (via Spring Boot starter) or use in CI pipelines to enforce schema quality. It supports both single-host and high-availability PostgreSQL clusters, with checks that can run statically (against schema only) or require accumulated statistics. The architecture is a multi-module Gradle project: `pg-index-health-model` defines immutable domain objects (Table, Index, Column, ForeignKey, etc.) with validation and composable predicates; `pg-index-health-core` implements host-level checks using a template pattern (`AbstractCheckOnHost`) with SQL queries loaded from a separate submodule; `pg-index-health` wraps these into cluster-level checks (`AbstractCheckOnCluster`) that aggregate results across primary and standby nodes; `pg-index-health-jdbc-connection` provides connection factories with primary host detection and multi-host URL parsing; `pg-index-health-generator` produces corrective SQL migrations; `pg-index-health-logger` formats results; and `pg-index-health-testing` offers Testcontainers-based test fixtures. Optional Jackson 2/3 modules enable JSON serialization of results. Key entry points include `StandardChecksOnHost` and `StandardChecksOnCluster` which enumerate all available checks, and the Spring Boot auto-configuration (`DatabaseStructureHealthAutoConfiguration`) that registers check beans. Data flows involve querying PostgreSQL system catalogs (`pg_catalog`, `pg_stat_*`), mapping result sets to domain objects via `ResultSetExtractor` implementations, applying exclusion predicates (e.g., skip Flyway/Liquibase tables, small tables, named objects), and returning lists of deviations. External dependencies are minimal: PostgreSQL JDBC driver, Apache DBCP2 connection pool, and Testcontainers for testing. The library is published to Maven Central and includes a BOM for dependency management.

RATING: 8.8/10 MAINT: active DRIFT: low
▸ 4 reusable components found
twentyhq/twenty ★ 57540 9305 APPLICATION

Twenty is a production-grade, open-source CRM delivered as a large Nx monorepo. The system is a full-stack TypeScript application: a NestJS backend (twenty-server) exposing GraphQL/REST APIs, a React frontend (twenty-front) with Jotai-based state management, a shared UI component library (twenty-ui), and shared TypeScript packages (twenty-shared). It provides multi-tenant workspaces, object-record CRUD with custom data models, role-based permissions, AI chat/agent capabilities (model tiers, tool calls, streaming), analytics via ClickHouse, and a CLI scaffolding tool (create-twenty-app) for bootstrapping custom apps. The architecture is modular with NestJS ConfigurableModuleBuilder patterns, event-driven design using Zod-validated schemas, and component-scoped state via atom families and component instance contexts.

RATING: 8.7/10 MAINT: active DRIFT: medium
▸ 4 reusable components found
drawdb-io/drawdb ★ 39836 3287 APPLICATION

drawDB is a free, open-source, client-side web application for designing relational database schemas and generating SQL. It provides an interactive ER diagram editor with support for multiple database dialects (MySQL, PostgreSQL, SQLite, MariaDB, MSSQL, Oracle), import/export in SQL, DBML, JSON, Mermaid, and Markdown, and features like auto-arrange, auto-connect foreign keys, schema validation, migration generation, and versioning via GitHub Gists. The architecture is a React single-page application (Vite + Tailwind CSS + Semi UI) with state managed through custom React Contexts and hooks, persistence via IndexedDB (Dexie), and an optional cloud backend through an extension system. It is primarily an application, with no data research or ML components.

RATING: 8.7/10 MAINT: active DRIFT: low
▸ 4 reusable components found
drizzle-team/drizzle-orm ★ 35975 1699 APPLICATION

Drizzle ORM is a headless, type-safe SQL query builder and ORM for TypeScript/JavaScript, supporting PostgreSQL, MySQL, SQLite, and serverless databases (Neon, PlanetScale, Cloudflare D1, Turso, etc.). The repository is a monorepo containing the core ORM library (`drizzle-orm`), a CLI tool (`drizzle-kit`) for schema introspection, migration generation, and database push/pull, a data seeding library (`drizzle-seed`), validation schema generators (`drizzle-zod`, `drizzle-valibot`, `drizzle-typebox`, `drizzle-arktype`), and an ESLint plugin (`eslint-plugin-drizzle`). The architecture follows a dialect abstraction pattern: each database has its own column builders, query builders (select, insert, update, delete), and session implementations that wrap native client libraries. The core provides composable SQL building via template literals, runtime type identification via the `entityKind` pattern, and a caching layer with tag-based invalidation. The CLI uses Zod-based configuration validation and generates migration SQL by diffing serialized schema snapshots. Integration tests run against real databases in Docker containers, and extensive type tests ensure compile-time correctness. External dependencies include various database client libraries (pg, mysql2, better-sqlite3, libsql, @neondatabase/serverless, etc.) and validation libraries (zod, valibot, typebox, arktype).

RATING: 8.7/10 MAINT: active DRIFT: low
▸ 4 reusable components found
agenda/agenda ★ 9707 844 APPLICATION

Agenda is a light-weight job scheduling library for Node.js with a pluggable backend architecture. The core library provides scheduling (cron, human-readable intervals, debounce), concurrency control, distributed locking, retries with composable backoff strategies, unique job constraints, and persistent job logging. It supports three official backends (MongoDB, PostgreSQL, Redis) via clean abstractions (JobRepository, NotificationChannel, JobLogger) that can be mixed and matched. The monorepo also includes two companion applications: agendash (a Vue 3 web dashboard for monitoring and managing jobs with real-time SSE updates) and agenda-rest (a Koa-based REST API server with CLI entry point). The codebase is fully TypeScript, ESM-only (v6), uses pnpm workspaces, changesets for versioning, Vitest for testing, and has extensive shared test suites that ensure backend interoperability. The architecture demonstrates strong separation of concerns, but there is some code duplication across backends and legacy v4 documentation that could cause confusion.

RATING: 8.7/10 MAINT: active DRIFT: low
▸ 5 reusable components found
teslamate-org/teslamate ★ 9122 1012 APPLICATION

TeslaMate is a self-hosted data logger for Tesla vehicles that collects telemetry via the Tesla API (both polling and streaming), stores data in PostgreSQL, and provides visualization through a Phoenix LiveView web interface and Grafana dashboards. It integrates with home automation systems via MQTT and supports importing historical vehicle data from CSV files (TeslaFi format). The application uses a supervision tree to manage background processes for data collection, MQTT publishing, import tasks, and update checking. Key features include geofencing for location-based cost tracking, encrypted storage for API tokens using Cloak, internationalization via Gettext, and custom Ecto expressions for geographic calculations. The architecture is monolithic with clear separation of concerns through Phoenix contexts (Log, Vehicles, Settings, Locations).

RATING: 8.7/10 MAINT: active DRIFT: medium
▸ 7 reusable components found
sidequestjs/sidequest ★ 1012 25 APPLICATION

Sidequest.js is a Redis-free background job processing system for Node.js/TypeScript that provides distributed, durable job processing using existing databases (PostgreSQL, MySQL, SQLite, MongoDB). The system features a modular monorepo architecture with separate packages for core logic, engine, database backends, web dashboard, and CLI tools. It implements job lifecycle management, scheduling via cron expressions, uniqueness constraints, retry mechanisms with backoff strategies, and provides a web interface for monitoring and management. The architecture follows clean separation of concerns with dependency injection, worker thread isolation via Piscina, and process isolation through forked child processes. Key entry points include the main Sidequest facade, engine configuration, dashboard interface, and CLI administration tools.

RATING: 8.7/10 MAINT: active DRIFT: low
▸ 5 reusable components found
dbeaver/dbeaver ★ 51954 4392 APPLICATION

DBeaver is a universal database management tool and SQL client, built as a desktop application on the Eclipse RCP (OSGi plugin) framework. It provides a rich graphical interface for connecting to over 100 database systems via JDBC/ODBC drivers, including relational databases (MySQL, PostgreSQL, Oracle, SQL Server, SQLite, etc.), cloud databases (BigQuery, Athena, Snowflake), and NoSQL systems (MongoDB, Cassandra) in commercial editions. The application offers a full suite of database development features: a multi-tab SQL editor with syntax highlighting, code completion, and execution plan visualization; a data editor with grid, form, and GIS geometry views; ER diagram designer; data export/import wizards supporting CSV, JSON, XML, SQL, Markdown, and Excel; dashboard widgets for query-based monitoring; and an integrated AI assistant (OpenAI, Copilot) for natural language query generation and schema analysis. The architecture follows a strict model/UI separation enforced by OSGi plugin boundaries. The core model plugin (`org.jkiss.dbeaver.model`) defines interfaces for database objects, data values, execution contexts, and security, which are implemented by database-specific extension plugins (`org.jkiss.dbeaver.ext.*`). UI plugins (`org.jkiss.dbeaver.ui.*`) provide editors, navigators, and dialogs, while data transfer, debugging, and AI features are isolated in their own plugins. This design allows the model layer to be reused in the web-based CloudBeaver product. Key entry points include the `DBeaverApplication` class for startup, the `SQLEditor` for query editing, and the `DataTransferWizard` for import/export. External dependencies include the Eclipse RCP framework, JDBC drivers, ANTLR4 for SQL grammar parsing, JSQLParser for SQL analysis, and various third-party libraries for SSH tunneling, AWS SDK, and AI API communication. Data flows center around database connections: users configure data sources via connection wizards, execute SQL queries through the editor, and view results in data grids or export pipelines. The data transfer subsystem implements a producer/consumer pattern with pluggable transformers and serializers, supporting streaming for large datasets. The AI integration uses a provider abstraction to interface with different LLM APIs, generating SQL from natural language and providing schema-aware context. The repository also includes a CLI tool (`dbvr`) for CI/CD automation and a headless test platform. While the community edition is fully open-source, commercial versions add NoSQL support, additional AI providers, and premium features, with some code paths guarded by feature flags.

RATING: 8.6/10 MAINT: active DRIFT: medium
▸ 5 reusable components found
calcom/cal.diy ★ 48868 15279 APPLICATION

Cal.diy is a fully open-source, MIT-licensed fork of Cal.com, providing a self-hostable scheduling platform. It is a large monorepo containing a Next.js web application (apps/web) for booking pages, settings, and admin, a NestJS API (apps/api/v2) for platform REST endpoints, and extensive packages for business logic (packages/features), integrations (packages/app-store with 50+ apps), embeddable booking widgets (packages/embeds), and reusable React atoms (packages/platform/atoms). The architecture uses tRPC for client-server communication, Prisma ORM with PostgreSQL, Redis caching, and a custom dependency injection system (ioctopus) alongside NestJS DI. Key patterns include a tasker abstraction for async/sync background jobs (webhooks, emails, calendar sync), a versioned webhook payload builder factory, repository pattern over Prisma, and a consistent app-store integration structure. The platform exposes a public API with OAuth2, webhooks, and embeddable components for third-party developers. The codebase is actively maintained with frequent schema migrations and CI/CD pipelines, but exhibits some technical drift due to dual API surfaces (tRPC vs REST), stub implementations for enterprise features, and generated files that require regeneration.

RATING: 8.6/10 MAINT: active DRIFT: medium
▸ 4 reusable components found
mindsdb/minds ★ 39360 6210 APPLICATION

MindsHub Cowork is a platform superproject that orchestrates four independent submodules into a unified AI workspace for knowledge workers. The repository itself contains no application logic — it's a pure orchestration layer using git submodules (frontend: Electron/Vite app, backend/core_api: FastAPI server, backend/core_agent: Anton autonomous agent, backend/data-vault: data engine). The superproject provides a sophisticated developer workflow via its Makefile: per-developer branch selection through a gitignored dev.env, dual run paths (local source with hot-reload vs uv-tool-installed desktop server) that follow the same refs, deliberate pin management via 'make pin'/'make baseline', and a nuclear 'make flush' for complete environment reset. Submodules are configured with 'ignore = all' so branch work never pollutes the parent git status. The Docker setup uses multi-stage builds with uv for Python and nginx for the web SPA. The REST API (documented in docs/api.html) exposes conversations, projects, artifacts, schedules, files, connectors, memories, skills, scratchpads, and search — all backed by a local SQLite database. This is hybrid in that it manages both a desktop (Electron) and web (SPA) frontend against the same API, but the dominant character is application orchestration.

RATING: 8.6/10 MAINT: active DRIFT: low
▸ 5 reusable components found
prest/prest ★ 4614 318 APPLICATION

pREST is a production-grade Go HTTP server that automatically exposes PostgreSQL databases as RESTful and MCP (Model Context Protocol) APIs without requiring hand-written backend code. It provides instant CRUD endpoints for any table, custom SQL template execution with parameterized queries, and a built-in Studio web UI for exploring and managing APIs. The system is architected around a hexagonal pattern with a clean adapter interface supporting multiple databases (PostgreSQL, TimescaleDB), dependency injection for controllers, and a layered middleware stack for authentication (JWT), authorization (table/field-level ACL), caching, and CORS. Security is a primary concern: SQL injection is mitigated through strict identifier validation, template parameter screening, and bound parameter binding, while credential leakage in logs is prevented by a dedicated redaction package. The codebase is well-tested with both unit tests (using sqlmock) and integration tests (against real PostgreSQL in Docker), and includes OpenTelemetry integration for observability. It is not a data research or analytics project; it is a pure application for building low-code database APIs.

RATING: 8.6/10 MAINT: active DRIFT: low
▸ 3 reusable components found
CrunchyData/postgres-operator ★ 4444 679 APPLICATION

PGO (Crunchy Data Postgres Operator) is a production-grade Kubernetes operator that manages the full lifecycle of PostgreSQL clusters, including deployment, high availability via Patroni, backup/restore via pgBackRest, connection pooling via PgBouncer, monitoring via OpenTelemetry and pgMonitor, and a web UI via pgAdmin. The operator uses custom resource definitions (CRDs) for PostgresCluster, PGAdmin, and PGUpgrade, and reconciles desired state using controller-runtime with server-side apply. It manages StatefulSets, PVCs, Services, ConfigMaps, Secrets, Jobs, and RBAC across multiple namespaces. Architecturally, the operator is a single binary with multiple controllers (postgrescluster, standalone_pgadmin, pgupgrade) and sidecar containers for pgBackRest, PgBouncer, pgAdmin, and the OpenTelemetry collector. It uses feature gates to enable optional capabilities like volume snapshots, auto-grow volumes, and OpenTelemetry logging/metrics. The codebase is well-structured with distinct packages for naming conventions, PKI certificate management, PostgreSQL parameter management, and shell command construction. Extensive unit and e2e tests (using kuttl and chainsaw) cover most scenarios, including backup/restore, scaling, upgrades, and security contexts. Key external dependencies include controller-runtime, client-go, Patroni, pgBackRest, PgBouncer, pgAdmin, OpenTelemetry SDK, and pg_query_go for SQL parsing. The operator is deployed via Kustomize and supports multiple PostgreSQL versions (11-18) with PostGIS extensions.

RATING: 8.6/10 MAINT: active DRIFT: low
▸ 4 reusable components found
$ loading more...
$ submit: