facile-it/mongodb-bundle
Symfony bundle that integrates Doctrine MongoDB ODM into your app, wiring document managers, repositories, and mappings through simple configuration so you can persist and query MongoDB documents using Symfony's service container.
Architecture fit. Unchanged by this release. facile-it/mongodb-bundle remains a thin Symfony bundle that wires the official mongodb/mongo-php-library into the container as autowirable services (MongoDB\Client, MongoDB\Database, MongoDB\Collection) — a service-integration layer, not an ODM. Strong fit for teams that want explicit, predictable MongoDB access inside a Symfony application without Doctrine ODM's ceremony and lock-in; weak fit for teams expecting repositories, hydrators, and lifecycle events, and non-viable for framework-agnostic or non-Symfony services in a polyglot estate. Note for the record: despite the generic "PHP package" framing, this is Symfony-only — there is no Laravel service provider, and none should be expected.
Integration feasibility. Still conventional and low-ceremony (require, enable in bundles.php, configure a DSN, inject MongoDB\Collection). Two constraints tightened in 2.0.0 and both must be verified before adoption:
The ext-mongodb extension remains a host-level prerequisite, resolvable only outside Composer.
Technical risk. The two dominant risks from the prior assessment shift in opposite directions.
Maintenance concentration / signal weakness — partially mitigated. A major release that adds current-Symfony support is exactly the cadence evidence the earlier assessment flagged as missing. One data point is not a trend, but it is the right kind of data point, and it materially lowers (does not eliminate) the abandonment scenario.
Version coupling — now the primary risk, and it has moved from theoretical to scheduled. 2.0.0 is a major version with explicit removals, which under semver implies breaking changes beyond the two listed. Because this package is a configuration-and-wiring layer, its breaking surface is precisely the config schema — the keys, service IDs, and DI aliases consuming applications bind to. The changelog as published lists only added/removed support ranges and does not describe config-schema changes. That gap is the thing to close before upgrading: read the actual diff or upgrade guide, and do not assume 2.0.0 is a no-op for existing 1.x configs.
Underlying driver risk is unchanged and remains a mitigation — the official library's maturity passes through.
Key questions.
ext-mongodb?ext-mongodb / mongodb/mongo-php-library version constraints 2.0.0 requires.Stack fit. Unchanged: a Symfony 6.x/7.x (and now 8.x) application on PHP 8.1+ needing direct, idiomatic MongoDB access — read models, event/audit logs, document stores, a CQRS read side beside a relational write model. Poor fit where the domain needs document mapping, embedding strategies, or ODM lifecycle callbacks, or where the team lacks MongoDB operational competence, since the bundle offers no guardrails beyond DI.
Migration path. Inbound paths are unchanged, with one new branch:
MongoDB\Client construction with injected services, move the DSN into config, delete bespoke factories.Compatibility. The three axes remain, but two now have published answers:
ext-mongodb / mongodb/mongo-php-library — still the axis most often missed, still not resolvable by Composer, still must be pinned in the base image. Confirm the library version 2.0.0 pulls and that its required extension version is in every environment including CI and local dev containers.Pin both the bundle and the library explicitly; do not float either in production.
Sequencing. Mostly unchanged, with the upgrade step made explicit:
ext-mongodb version in every target environment.Maintenance. Low ongoing code maintenance, and the dependency-hygiene burden now looks better owned than it did. 2.0.0 is evidence the maintainer tracks Symfony's release train rather than trailing it, which is the single most important maintenance property for a wrapper of this kind — being stranded on an unsupported Symfony major is the failure mode that matters, and there is now a data point against it. Two caveats: one release is not a cadence, and the major-version bump transfers effort to you. Budget a named owner for the upgrade path, and extend that ownership to tracking major releases specifically, since 2.0.0 demonstrates this package will cut a major version to follow Symfony rather than carry compatibility shims indefinitely. Plan for one bundle major per Symfony major; that is a reasonable and predictable tax, but it must be in the roadmap.
Support. Unchanged: community-tier — GitHub issues, no SLA, no bundle-specific commercial backing, with the mitigating factor that most hard problems are MongoDB-driver problems where the official documentation and commercial support apply directly. The 2.0.0 removals sharpen one support question: with the older-Symfony line dropped, does the maintainer backport fixes to 1.x, or must you be on 2.x to receive anything? Get that answered if you are pinned to Symfony 5.4. Organisations requiring vendor SLAs on data-store integrations should still record this as a gap.
Scaling. Unchanged and inherited from the official driver — pooling, replica-set topology discovery, read-preference routing come for free; the bundle adds no pooling layer and therefore no artificial bottleneck, but also no protection against developers bypassing DI to construct clients per request. The two standing caveats hold: long-running workers (Messenger consumers, RoadRunner) need explicit client-lifecycle review because a container singleton behaves differently than under PHP-FPM; and a low-star package will not have been load-tested across the topologies your estate may run. Nothing in 2.0.0 changes the scaling profile.
Failure modes. Updated set:
ext-mongodb mismatched to the library, failing fatally at boot rather than at query time. Unchanged.Ramp-up. Unchanged for the most part. Developers fluent in the MongoDB PHP library ramp in hours — there is essentially nothing new beyond the config keys. Developers from Doctrine ODM or relational ORMs face a genuine mindset shift: no unit of work, no identity map, no lazy loading, explicit cursor handling, manual error/retry semantics. Budget a short enablement session plus a reference implementation, and codify conventions (where clients are injected, how collections are named and resolved, how errors are wrapped) in a written standard — the absence of an abstraction layer otherwise produces inconsistent access patterns across teams. Add one item for the upgrade generation: a short internal note on the 1.x → 2.x delta and the new Symfony/MongoDB floors, so teams do not discover them at container-boot time.
How can I help you explore Laravel packages today?