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

Orm Laravel Package

analogue/orm

Analogue is a flexible data-mapper ORM for PHP and Laravel. It separates domain models from mappers and repositories, offering fluent query building, eager-loaded relations, collections and clean persistence without the active-record constraints of Eloquent.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit. Analogue is a Data Mapper ORM, not an Active Record ORM like Eloquent. That is the core evaluation point. It separates domain objects from persistence logic and provides a Unit of Work, Identity Map, and lazy-loaded proxies. For a bounded context with rich domain logic, aggregates, and business rules that should not inherit from Illuminate\Database\Eloquent\Model, this is a legitimate architectural fit. For the majority of Laravel applications — CRUD screens, admin panels, rapid feature delivery — it is a poor fit because it fights Laravel’s conventions and adds a second persistence paradigm.

Integration feasibility. The package is Composer-installable and MIT-licensed, with a Laravel service provider/config path and support for Laravel’s database connections. Coexistence with Eloquent at the database level is technically possible, but transaction boundaries, identity maps, and schema ownership must be designed deliberately. Framework features that assume Eloquent — authentication, Nova, Cashier, Sanctum, queue serialization patterns, policy/gate conventions — should remain on Eloquent. The integration is feasible, but it is an application-architecture project, not a package install.

Technical risk. Lifecycle risk dominates. The last release was April 2020, the project has 634 stars but zero dependents, and there is no evidence of active maintenance. PHP 8.x and Laravel 8+ compatibility must be proven with a spike, not assumed. An unmaintained ORM at the core of an application is a high-blast-radius dependency: security patches, PHP upgrades, and framework upgrades become internal work. The MIT license permits a fork, but a fork is a product-ownership commitment, not a mitigation footnote.

Key questions.

  • Which PHP and Laravel versions are actually supported on our target runtime?
  • Does it integrate with Laravel migrations, or does schema management move to the ORM?
  • How are transactions and Unit of Work coordinated with Laravel’s DB manager?
  • Can it safely coexist with Eloquent models on the same connection?
  • What is the proxy-generation and cache-warming strategy for deployment?
  • Who owns the fork if upstream is inactive, and what is the exit plan?
  • Is Doctrine ORM a better-maintained alternative for the same data-mapper requirement?

Integration Approach

Stack fit. Adopt only where the domain complexity justifies a data mapper. Good candidates are a single bounded context with complex aggregates, invariants, and domain services. Poor candidates are whole-application replacement, CRUD-heavy products, small teams without data-mapper experience, or applications deeply coupled to Eloquent-based ecosystem packages. Keep Laravel-native concerns on Eloquent and isolate Analogue behind repositories.

Migration path. Use a strangler pattern. Introduce Analogue in one module or bounded context, map existing tables to entities, and avoid dual-writing through two ORMs. Coordinate transactions at the application-service layer. Add an anti-corruption layer so domain code does not leak ORM annotations or proxy types into controllers. If migrating existing Eloquent models, migrate read paths first, validate parity, then move writes.

Compatibility. Pin PHP and Laravel to versions verified by a proof of concept. On Laravel 9+, assume a fork or patch is required until proven otherwise. Verify Composer constraints, proxy directory permissions, cache-clearing behavior, and PHP 8.1+ deprecation output. Treat framework upgrades as requiring an ORM compatibility gate.

Sequencing.

  1. Run a time-boxed spike on the exact PHP/Laravel runtime.
  2. Decide fork ownership and estimate ongoing maintenance before committing.
  3. Select one low-risk bounded context, not the core revenue path.
  4. Define entity, mapping, transaction, and repository conventions.
  5. Build integration tests against a real database and CI matrix.
  6. Add deploy-time proxy warmup and operational runbooks.
  7. Measure delivery speed and defect rates before expanding.

Operational Impact

Maintenance. Expect to self-maintain. Budget for a named owner, a fork or patch process, and compatibility work on every PHP/Laravel upgrade. Dependency updates are not “set and forget”; they are an engineering line item.

Support. Community support is effectively inactive, documentation is frozen, and hiring developers with Analogue experience is unrealistic. Internal documentation, patterns, and onboarding material become mandatory. A TPM should treat support as an internal platform capability.

Scaling. The data-mapper pattern is not inherently slow, but the Unit of Work and Identity Map can retain large object graphs in long-running workers such as Octane or queue consumers. Lazy loading creates N+1 risk. Performance validation should include memory growth, query counts, and transaction duration under realistic load.

Failure modes. Likely failure modes include proxy-generation failures on deploy, stale proxy caches, identity-map memory growth in long-running processes, incorrect transaction demarcation, schema drift where migrations and mappings diverge, and fatal incompatibilities on PHP upgrades. Mixing Eloquent and Analogue on the same tables raises duplicate-persistence and cache-coherence risks.

Ramp-up. Eloquent-native developers should expect weeks, not days, to become productive with entities, mappers, proxies, Unit of Work, and aggregate boundaries. Ramp-up is manageable for senior engineers with Doctrine or data-mapper experience and expensive for teams without it. The TPM recommendation is therefore conditional: do not adopt for a new core platform without an owned fork and a bounded-context isolation plan; evaluate Doctrine ORM first if the data-mapper requirement is genuine.

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.
skyraptor/chatter
edlugz/sasapay
abbasudo/artisan-route
mirvan/ippanel
ignibyte/aic-framework
glavweb/data-schema-bundle
glavweb/datagrid-bundle
tacticmedia/scim-server
uni-method/frame
neika-ai/sdk
adachsoft/php-code-style
pharaonic/laravel-notification-dependencies
beautinow/translug
dev-brainiac/bot-cloaked
octoberrain/html
octoberrain/extension
octoberrain/exception
octoberrain/contracts
adachsoft/api-version-bundle
cgv/localized-resource