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

Avro Laravel Package

jaumo/avro

jaumo/avro is a PHP implementation of Apache Avro, offering schema parsing and binary encoding/decoding for records, unions, and logical types. It helps PHP services exchange compact, schema-driven data with Kafka, Hadoop, and other Avro-based systems.

View on GitHub
Deep Wiki
Context7

jaumo/avro is a library for handling serialization and deserialization of Avro values and schemas, including RPC.

Frequently asked questions about Avro
Is jaumo/avro a Laravel package or a framework-agnostic library?
jaumo/avro is not a Laravel package. It is a framework-agnostic PHP implementation of Apache Avro with no service provider, facade, config file, or published config. That is the right shape for a serialization dependency: wrap it in an application-owned Codec contract and register it with a thin in-house service provider. Keep it out of Eloquent models and controllers entirely.
How do I install jaumo/avro with Composer in a Laravel app?
Install it with Composer using the jaumo/avro package name. It is PSR-4 autoloaded and has no Laravel version coupling, so install friction is near zero. Because there is no auto-discovered service provider or facade, you bind it yourself in a small AvroServiceProvider as a singleton behind your own codec interface. Check the package's composer.json for its PHP version constraint before adding it to an older Laravel application.
Does jaumo/avro work for Laravel queues and Kafka producers?
Yes. Its natural seat in a Laravel system is the outbound message path (Kafka producers, queue payloads, CDC event buses) and the inbound consumer path (queue workers, console consumers), plus batch import/export for analytics. It handles the bare binary body only, so Confluent-style framing and the schema registry client are layers you build or wrap yourself. Treat the bundled Avro RPC support as dead weight, since Avro RPC is a niche transport almost no modern stack uses.
Does jaumo/avro support Avro logical types, unions, and schema evolution?
The library advertises schema parsing and binary encoding/decoding for records, unions, and logical types. Avro correctness is binary and unforgiving, though: union resolution, default values, logical types such as decimal, timestamp-micros and uuid, aliases, and schema evolution rules are exactly where implementations diverge. Confirm which Avro spec version and which features are actually covered, and gate adoption on a golden-file conformance harness before trusting it in production.
Does jaumo/avro produce Confluent Schema Registry wire format?
Assume raw binary only. Confluent-style framing (magic byte plus schema ID) and registry client behaviour are typically not what a serialization library gives you, so plan to build or wrap that layer and own the registry client yourself. Verify the exact bytes your producers emit against your consumers before rollout. If you need registry-aware encoding, that belongs in your application-owned codec, not in this dependency.
Is jaumo/avro safe to use with Laravel Octane and long-lived workers?
This is an open question rather than a documented guarantee, so treat it as a risk. A serializer that holds static state can misbehave under Octane or long-running queue workers where state leaks between requests and jobs. Audit the source for static caches and reset them in an Octane listener or worker bootstrapping hook if needed. Load-test under Octane before production.
How do I test that jaumo/avro encodes correctly against Java or Python producers?
Build a golden-file conformance harness. Encode representative payloads with jaumo/avro, decode them with the Java, Python, or Go implementation on the other side of the wire, then reverse the direction. Cover unions, logical types, defaults, aliases, and schema evolution cases explicitly. This is the only reliable gate, because a serialization bug writes corrupt events into a queue or data lake where it surfaces hours later and is expensive to backfill.
What are the risks of using a low-adoption Avro library like jaumo/avro in production?
It is single-vendor, hosted on GitLab, with negligible adoption and zero dependents, so if Jaumo's internal priorities shift the library goes quiet with no community to fork around. Apache's own PHP Avro implementation is historically incomplete, so switching upstream is not a dependable exit ramp. Expect security review scrutiny, treat it as infrastructure rather than a utility package, and plan to vendor or fork it internally with a named owner.
Which Laravel and PHP versions does jaumo/avro support?
There is no Laravel version coupling because it is a plain Composer library, so Laravel 9, 10, 11, and 12 applications can all install it. The PHP version support matrix and license should be confirmed from the package's composer.json and repository before adoption, since these are open questions rather than stated facts. Run it on the oldest PHP version in your fleet to confirm compatibility.
What alternatives to jaumo/avro exist for Avro in PHP and Laravel?
The main alternative is Apache's official PHP Avro implementation, which has historically been incomplete and is not a reliable fallback. Otherwise you can vendor or fork jaumbo/avro internally, or drop Avro entirely in favour of JSON or Protobuf if Avro is not mandated by your Kafka, Hadoop, or data-lake peers. In practice the decision usually comes down to which side of the wire dictates the schema.
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.
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
coleus/apps
seampact/laravel
emmyconceptng/laravel-ng-postcode
jjsquady/round-robin
skyraptor/chatter
edlugz/sasapay
abbasudo/artisan-route