Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Custom Index Bundle Laravel Package

intaro/custom-index-bundle

Symfony bundle for adding and managing custom Doctrine database indexes via configuration, so you can tune query performance without modifying entity mappings. Useful for optimizing large tables and controlling indexes from application config.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit. The framing mismatch from the prior assessment stands and is untouched by v1.1.0: intaro/custom-index-bundle is a Symfony bundle built against Doctrine ORM, not an Eloquent/Illuminate package. It attaches metadata (attributes, formerly annotations) to Doctrine entities describing index shapes Doctrine's schema tool cannot express — GIN, GiST, partial, functional/expression, and covering indexes — and emits the corresponding DDL. For Symfony + Doctrine + PostgreSQL it fills a real gap. For a Laravel codebase there is still no adapter path short of porting the metadata reader and DDL generator into a custom Artisan command, which is reimplementation, not adoption. The release does not change this calculus in either direction.

Integration feasibility. Unchanged and still low-effort if the stack fits: register the bundle, annotate entities, wire generation into the existing Doctrine migration or deploy pipeline. The package supplements rather than replaces migrations, keeping blast radius small and a time-boxed spike (1–2 engineer-days) cheap. Two things improved materially here. First, Doctrine ORM 3 compatibility (PR #27) removes what was the most likely near-term integration blocker — teams already on ORM 3, or planning that upgrade, previously had to treat this package as a hard pin against ORM 2 and a scheduling conflict. Second, the addition of CI, PHPStan, and php-cs-fixer (PR #26) means the package now has an automated correctness gate; the "unvalidated single-author code" characterisation is now slightly too harsh. PostgreSQL remains the gating requirement — MySQL/SQLite users still get almost nothing.

Technical risk. Still the dominant concern, but the composition has shifted. At 27 stars and 0 dependents, there is no downstream ecosystem validation and no evidence of production use outside the author's projects, and all v1.1.0 changes come from the same single maintainer (@muxx) — the release signals continued attention, not redundant maintenance capacity. The Doctrine-coupling risk that previously topped this list is now partly retired: ORM 3 support is explicitly claimed, and the new CI/PHPStan harness gives some confidence that the claimed support is exercised rather than aspirational. What remains is DBAL coupling and the next major bump (ORM 4 / DBAL 5), which is a future gate rather than a live one, plus the unchanged hazards: silent schema drift when entity metadata is removed but the physical index persists, and index-creation operational risk — non-concurrent builds take locks on large tables, and CREATE INDEX CONCURRENTLY cannot run inside a transaction, conflicting with how Doctrine migrations normally execute.

Key questions. Is our target application actually Symfony/Doctrine, or Laravel? Which database — Postgres or MySQL? Are we on ORM 2 or ORM 3 today, and does this release let us collapse two upgrade tracks into one? (New, and now the highest-leverage question — it is the concrete win this release creates.) Do we have a named internal owner willing to vendor/fork this if it goes stale? What is the largest table we intend to index, and can we tolerate a lock window or do we need out-of-band concurrent creation? Do we need this at all, given that hand-written raw SQL migrations can express every index this package generates?

Integration Approach

Stack fit. Adopt only for Symfony 6/7 + Doctrine ORM 2 or 3 + PostgreSQL. Reject for Laravel/Eloquent, and reject for MySQL/SQLite targets. If the org is Laravel, the recommended alternative is unchanged: a plain migration containing raw CREATE INDEX statements — you lose declarative entity-level metadata but gain zero dependency risk, and the SQL is identical.

Migration path. Still additive, so no data migration and no risky cutover. Existing Doctrine-generated indexes stay untouched; new non-standard indexes arrive as new migration steps. The retrofit concern is unchanged: if a table already carries a redundant standard index, the team must drop it explicitly — the package will not. New in this release: teams on ORM 2 can now sequence their ORM 3 upgrade without first having to find a replacement for this bundle, which removes a dependency-ordering constraint from the upgrade plan.

Compatibility. Pin PHP, Doctrine ORM, and DBAL versions explicitly in composer.json. v1.1.0 is the first release that should be treated as ORM 3-valid, so pin to v1.1.0 or later rather than v1.0.3 if ORM 3 is in scope. One consequence worth calling out to engineers: ORM 3 dropped the annotation metadata driver, so this release implicitly makes attribute-based metadata mandatory — the "verify attribute vs. annotation driver" check from the prior assessment is now effectively resolved in favour of attributes, and any team still on annotations must migrate their entity metadata as part of adopting this. Treat the next Doctrine major as a re-validation gate; the new PHPStan/CI harness makes that re-validation cheaper than it was.

Sequencing. (1) Spike in a staging branch against a copy of the real schema, on the ORM version we actually intend to run; (2) confirm generated DDL matches expectations for one GIN and one partial index; (3) validate the deploy-time execution path, including whether index creation runs inside a transaction; (4) if Postgres and large tables, split index creation into a separate concurrent, non-transactional deploy step; (5) roll out to one read-heavy service, measure query plans before/after; (6) only then generalize as a team standard. If an ORM 3 upgrade is also in flight, run steps 1–2 against ORM 3 specifically — do not validate on ORM 2 and assume forward compatibility.

Operational Impact

Maintenance. Assume you own the code, but the burden is now modestly lighter than previously assessed. The repo has CI, static analysis, and a formatter, which means upstream breakage is more likely to be caught by the maintainer before it reaches you, and a fork is easier to keep healthy because the tooling comes with it. Budget a fork-and-vendor posture from day one regardless: mirror the repo internally, tag v1.1.0 as the known-good baseline, and treat upstream releases as optional patches rather than a supply chain you depend on. The maintenance load remains small (the package is thin) but non-zero, and it lands the moment Doctrine ships the next breaking change.

Support. MIT, community-only, no vendor, no SLA, contributor base of effectively one — unchanged by this release, and the concentration of both PRs under a single author is a reminder rather than a reassurance. Internal escalation routes to the adopting team, not to an external party. Acceptable for an internal convenience library; unacceptable anywhere a schema change is business-critical without a fallback plan.

Scaling. The package's scaling characteristics are Postgres's, not the package's. Expression indexes require IMMUTABLE functions — a subtle constraint producing runtime rather than compile-time errors. Partial indexes only pay off if the planner actually matches the predicate, so effectiveness must be validated with EXPLAIN, not assumed. On large tables the dominant cost is build time and locking, which the package does not solve and this release does not address; that stays a pipeline-level concern.

Failure modes. Watch for: silent no-op when the DB driver isn't supported; orphaned indexes after entity metadata is deleted (bloat, write amplification, wasted storage); lock-induced outages during migration on high-traffic tables; version-coupled breakage at the next Doctrine major (the ORM 3 instance of this is now closed, the class of risk is not); and divergence between environments if the index-generation step is wired into migrations in one environment and run manually in another. Add one release-specific item: a false sense of ORM 3 readiness — "compatible" here means the metadata/DDL path works, not that every index type has been exercised against ORM 3's schema tool, so verify on our schema rather than trusting the changelog line.

Ramp-up. Developer learning curve stays genuinely low — a handful of attributes and one console command. The real ramp-up remains Postgres index literacy: when a GIN index beats a B-tree, how selectivity affects partial-index usefulness, and how to build indexes without locking production. Plan that training regardless of whether this package is adopted.

Recommendation. Still a conditional adopt, but the condition is now easier to satisfy. v1.1.0 closes the single most likely near-term breakage vector (Doctrine ORM 3) and adds real engineering hygiene (CI, PHPStan, php-cs-fixer), which upgrades this from "unvalidated single-author code" to "small but competently maintained library." What it does not change: zero dependents, one maintainer, Postgres-only relevance, and a Laravel framing that still does not match the artifact. Adopt for Symfony/Doctrine/Postgres teams with a named internal owner — and if an ORM 3 upgrade is on the roadmap, this release makes adoption more attractive than it was last quarter, because it removes a dependency-ordering conflict rather than adding one. Skip otherwise; the 80% alternative — hand-written raw SQL index migrations — still captures most of the benefit with none of the dependency risk.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
snowsoft/faker
meditationsteps/blogetc
animalyoung/laravel-influxdb
onix-solutions/sms-telera
lonely-lights/prosetta
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin
artisan-build/community-prompts
vleroy/smart
ayles-software/laravel-australian-public-holidays
cboxdk/laravel-id-spatie
cboxdk/laravel-id-billing
cboxdk/laravel-id-billing-bridge
simple-as-fuck/php-performance-log
hsluv/hsluv
seampact/codegen