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

Array Jms Serializer Bundle Laravel Package

epwt/array-jms-serializer-bundle

A Symfony bundle that extends JMSSerializerBundle with an Array format, letting you serialize and deserialize data to and from PHP arrays alongside the formats JMS already supports. A small add-on for projects needing array output within the JMS serialization pipeline.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Serialization boundary choice: array vs. wire format. JMS Serializer's default formats are JSON/XML/YAML. This bundle adds an "array" format so domain objects hydrate directly from, and export to, plain PHP arrays — useful when the data never needs to cross a network boundary in a text encoding. This informs the decision of where to spend serialization cost: skip JSON encode/decode for internal hops (message queues, cache layers, event payloads, DB JSON columns you already decode).

  • Build vs. buy — and the answer here is mostly "build." The capability is a thin extension over JMSSerializerBundle (a format/visitor registration). At 4 stars, 0 dependents, and README-level maturity, this is better treated as a reference implementation of the pattern than a dependency. The PM decision it enables is: "we want array (de)serialization with our existing JMS metadata; do we vendor this, fork it, or write ~50 lines ourselves?" Realistic effort for in-house is well under a sprint.

  • Stack-fit veto. The prompt frames this as a Laravel/PHP package, but it is a Symfony bundle (EPWTArrayJMSSerializerBundle, depends on JMSSerializerBundle and the Symfony bundle/kernel registration model). If the product is Laravel, this is a non-starter without an adapter layer — that alone is a roadmap-relevant finding, not a footnote.

  • Roadmap / legacy-compat input. Any roadmap item touching JMS Serializer 3.x or PHP 8.x should assume this bundle is not covered. It predates and likely conflicts with modern JMS releases; if a migration is planned, budget for replacing this dependency rather than upgrading it.

  • Concrete use cases worth scoping: fixture and snapshot generation in tests, DTO hydration from already-decoded payloads (config trees, request bodies, cached arrays), and normalizing objects into array shapes for comparison/diffing in test and tooling code.

When to Consider This Package

Consider it only when all of these hold:

  • You are on Symfony with the bundle/kernel registration path available.
  • You already run JMSSerializerBundle with meaningful investment in annotations/XML/YAML metadata (dozens of models, exclusion policies, groups). That investment is the only thing that makes a JMS format extension worth anything.
  • You need array-shaped output without a JSON round-trip, and you can vendor or fork the code into your repo.
  • You are on a JMS Serializer version this bundle was actually built against — verify by reading the composer.json constraint, not the README.

Look elsewhere when:

  • The stack is Laravel — use spatie/laravel-data, symfony/serializer, or hand-rolled DTOs with toArray().
  • You are on JMS Serializer 3.x / PHP 8+ — expect incompatibility; the maturity signal (README only, 0 dependents, 4 stars) means nobody has validated it against current releases.
  • You need maintenance guarantees, security patching, or an SLA. There is no signal of active upkeep.
  • The need is performance-critical (hot serialization path). A thin array format may still lose to purpose-built array mapping; benchmark before committing.
  • You're starting greenfield. Adopting JMS Serializer plus an unmaintained format extension to get arrays is two dependencies where zero would do.

How to Pitch It (Stakeholders)

To executives: This package is a small format adapter that lets our models convert to and from plain PHP arrays instead of JSON, within an established Symfony serialization framework. The capability is genuinely useful for internal data plumbing and test tooling. The package is not investable: 4 stars, zero dependent projects, README-only documentation, and no evidence of maintenance. Recommendation: do not add it as a dependency. If the capability is on our roadmap, we can build the equivalent in roughly a day of engineering and own it outright.

To engineering: Treat this as a design reference, not a library. Read it to see how a JMS format/visitor is registered, then implement the array format in-house against whatever JMS Serializer version we actually run — or skip JMS entirely if the goal is array output for a Laravel or greenfield service. Two specific checks before anyone spends time on it: (1) confirm the target framework really is Symfony, since this is a bundle and the framing as a Laravel package is misleading; (2) confirm the JMS Serializer version constraint supports our runtime, since the project shows no signs of PHP 8 / JMS 3.x adaptation. Expect to fork rather than composer require if we proceed at all.

Bottom line for the roadmap: low priority, low risk to explore, high risk to depend on. Do not put it on the critical path.

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.
takashato/laravel-vietqr
aitor24/laralang
kraenzle-ritter/entity-relations
dindigital/din-image
pomirleanu/image-colors
sawmainek/laravel-api-generator
delatbabel/jsonresponses
mouhamedfd/permissions-generator
eduplus/qr
laravel2580/idehelpers
delatbabel/viewpages
anavel/gettext
muhamadrezaar/highcharts
delatbabel/keylists
frankkessler/salesforce-laravel-oauth2-rest
anavel/foundation
wdmtech/enviricons
eii/laravel-captcha
muka/shape-reader
tdt/json