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

Eloquent Joins Laravel Package

tjbp/eloquent-joins

Eloquent Joins adds relationship-aware join helpers to Laravel's query builder, letting you join tables through model relations and reuse constraints without hand-writing ON clauses. A small package that keeps joined queries readable and DRY.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit. The package is a thin extension of Laravel's Eloquent ORM, adding join support at the relationship-definition level rather than at the query-builder call site. Architecturally it sits in the data-access layer and has a small blast radius, but it depends on Eloquent internals (relation query construction and builder macros) that are not a stable public contract. That makes it a poor long-term architectural dependency even though it "fits" a Laravel monolith on paper.

Integration feasibility. Composer installation is trivial, but the repository is archived, so framework version constraints are almost certainly stale (likely Laravel 5/6/7-era). Integration is realistic only on a legacy, pinned Laravel stack where the team accepts the constraints. On Laravel 9+, native features (joinRelationship, whereHas, whereRelation, hasManyThrough, withAggregate) cover most of the same use cases without a third-party dependency.

Technical risk. High. Specific concerns:

  • Archived / unmaintained: no security patches, no framework compatibility updates, no bug fixes.
  • License: GPL-3.0 is copyleft. Fine for internal SaaS in most interpretations, but a legal exposure for distributed or on-prem products. Requires legal sign-off before adoption.
  • Adoption signal: 17 stars and a single-maintainer bus factor means minimal community validation and no realistic upstream support.
  • Correctness: generated relationship joins are prone to row multiplication and duplicate results unless distinct/groupBy is applied carefully; this can silently corrupt aggregates and pagination.

Key questions.

  • Which Laravel/PHP versions does the package actually support, and does that match our target stack?
  • Do we distribute source or binaries to customers (GPL exposure), or is this strictly internal SaaS?
  • Can native Eloquent APIs replace the required query patterns? If not, which specific patterns cannot be expressed natively?
  • Has legal approved GPL-3.0 in production dependencies?
  • Is there a maintained fork, or will we own an internal fork?
  • What is the rollback plan if the package breaks a Laravel upgrade?

Integration Approach

Stack fit. Only viable if the application is on a compatible Laravel version and legal accepts GPL-3.0. It is not a fit for new greenfield services on current Laravel.

Migration path. Default recommendation: do not adopt; express the requirement with native Eloquent (joinRelationship, whereHas, hasManyThrough, withAggregate). If a legacy feature already depends on the package, wrap the affected queries behind a repository/query-object boundary, add characterization tests that lock current result sets, and replace the package incrementally behind that seam.

Compatibility. Verify Composer constraints against the framework version, audit transitive dependencies, and run the full query/integration test suite. Check for conflicts with other Eloquent extensions (global scopes, soft deletes, custom builder macros). Confirm behavior with soft-deleted models and polymorphic relations, which are common breakage points for relationship-level join packages.

Sequencing.

  1. Legal/license review for GPL-3.0.
  2. Version-compatibility spike on a throwaway branch against our pinned Laravel version.
  3. Proof-of-concept comparing the package against native Eloquent on 2–3 real query patterns, including pagination and aggregate correctness.
  4. Decision gate: adopt, fork, or reject. Default is reject unless native APIs demonstrably fail.
  5. If adopted, vendor or fork with named internal ownership and a documented deprecation/replacement plan.

Operational Impact

Maintenance. Effectively zero upstream maintenance. Any fix, security patch, or framework-compatibility update becomes our responsibility via an internal fork. That is a recurring engineering cost disproportionate to the package's small feature surface.

Support. Community-only, no SLA, no vendor. Incident resolution is self-service; the archived status means issues and PRs will not be addressed. Runbooks must assume we own the code.

Scaling. SQL joins themselves are usually efficient, but relationship-generated joins can multiply rows, inflating result sets and breaking pagination counts and aggregates. Monitor slow-query logs and row counts on joined paths; require distinct/groupBy and explicit index review before using on high-cardinality relationships.

Failure modes.

  • Silent breakage or changed query semantics after a Laravel upgrade.
  • Duplicate rows causing incorrect aggregates or pagination.
  • Security exposure through an abandoned dependency and its transitive packages.
  • License contamination if the product is distributed.
  • Single-maintainer abandonment already realized (repo archived).

Ramp-up. Low API learning curve for engineers, but high organizational cost: legal review, fork ownership, upgrade monitoring, and eventual replacement work. Net recommendation for a TPM: treat this as legacy/contain-only, block new adoption, and budget a replacement with native Eloquent features.

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.
coleus/frame
thtg88/journalism
filagora/filagora-ai-forums
rlacerda83/query-parser
socialdept/atp-orm
cboxdk/laravel-assistant-client
socialdept/atp-resolver
socialdept/tenant-domains
tautvydasr/blade-class-names
socialdept/color-scales
maherelgamil/controller
coleus/widgets
coleus/table
coleus/users
coleus/music
coleus/health
coleus/calendar
coleus/notes
coleus/support
coleus/settings