opensoft/doctrine-postgres-types
Doctrine DBAL types for PostgreSQL-specific columns. Map arrays, hstore, jsonb, uuid, inet, and other native Postgres types in your entities so schema tools and queries handle them correctly. Useful for Laravel apps using Doctrine.
Architecture fit. This is a Doctrine DBAL extension, not a Laravel/Eloquent package. It only earns a place in a Laravel codebase where Doctrine is already present — typically via a bridge such as laravel-doctrine, or where DBAL is used directly for schema introspection and migrations. In a conventional Eloquent-only application it has no integration surface and should be rejected outright. Where Doctrine is present, the package's job is narrow but valuable: mapping Postgres-native types (arrays, jsonb, hstore, network types, ranges) to PHP values so ORM hydration and schema comparison work correctly.
Integration feasibility. Registering a custom type is mechanically simple (Type::addType during bootstrap), but that is exactly where the risk concentrates. A release dated August 2016 predates DBAL 3.x, where the type-registration API changed, and certainly predates DBAL 4.x. Expect the package to target DBAL 2.4–2.5 and PHP 5.6/7.0 idioms. There is no declared PHP 8 compatibility, no CI matrix, and no evidence of maintenance beyond the original Opensoft use case.
Technical risk. High relative to its value. The code is effectively single-vendor and abandoned; any incompatibility becomes our problem to patch. Because these types sit directly on the data hydration path, a subtle defect can silently corrupt reads (e.g., array or jsonb decoding), which is a far worse failure mode than an outright exception.
Key questions. Which DBAL version does the target application pin? Which Postgres types are actually in use versus merely supported? Is the application genuinely on Doctrine, or is this being evaluated for an Eloquent stack? Is there a maintained alternative that covers the same types before we take on a fork?
Stack fit. Confirm Doctrine presence first. If the answer is Eloquent-only, close the evaluation. If Doctrine is in play, scope the package to exactly the types the schema uses — do not adopt the full type set speculatively.
Migration path. Prefer a maintained replacement (for example martin-georgiev/postgresql-for-doctrine, which targets modern DBAL and PHP) over adopting a 2016 artifact. Fall back to this package only if it covers a type the alternative does not, and in that case vendor a fork into our own namespace rather than depending on the upstream tag.
Compatibility. Pin the DBAL major version explicitly, run the target PHP version in CI, and add a smoke test that round-trips each registered type through write and read. Treat any DBAL upgrade as a breaking change requiring re-validation of these types.
Sequencing. (1) Inventory Postgres column types actually used. (2) Proof-of-concept on a branch with the candidate library. (3) Wrap registration in a thin internal adapter so the dependency can be swapped. (4) CI compatibility tests across supported PHP/DBAL versions. (5) Production rollout behind the ORM configuration, with a rollback path to string-typed columns.
Maintenance. We inherit ownership. With no upstream activity since 2016, assume zero fixes arrive from the maintainer; budget a fork-and-patch line item and assign a named owner.
Support. Internal-only. Document the type registration point and the mapping table so on-call engineers can diagnose hydration issues without reading vendor source.
Scaling. Runtime cost is negligible — conversion is PHP-side and per-row, not an infrastructure concern. The scaling risk is organizational: knowledge concentration in whoever configured the types.
Failure modes. Silent mis-hydration of arrays and jsonb; schema-diff false positives during migrations; hard breaks on DBAL or PHP upgrades; deprecation noise on PHP 8.x. Each needs a test, not a hope.
Ramp-up. The Doctrine custom-type system is a niche skill most Laravel developers have never touched. Budget onboarding time and pair the integration with written runbook notes.
How can I help you explore Laravel packages today?