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

Api Redis Bundle Laravel Package

experteam/api-redis-bundle

Symfony 5.1+ bundle providing Redis services for APIs: a Predis client wrapper for reading and writing, plus a transport to persist entities and dispatch message queues, configured via YAML with per-entity prefixes and serialization groups.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit — primary blocker: the package is a Symfony bundle, not a Laravel package. It ships a Symfony Bundle class, a DependencyInjection extension, and a YAML config tree loaded from config/packages/. Laravel has no bundle/extension lifecycle; adopting this in a Laravel codebase requires either (a) porting the container wiring into a ServiceProvider + config/api_redis.php, or (b) ignoring the bundle and consuming only its underlying classes via Composer autoload. Neither is a drop-in integration. If the target application is genuinely Laravel, the architecture fit is poor and should be treated as "source of design ideas," not a dependency.

Scope delivered: two thin capabilities — a Predis client wrapper (read/write) and a "Redis Transport" that persists entities to Redis and dispatches messages to queues. Both are commodity concerns in either ecosystem (Illuminate\Redis, Illuminate\Queue, symfony/cache, symfony/messenger with the Redis transport). The package's only differentiated surface is convention: serialize_groups, per-entity prefix/save/message/message_class config, and an elk_logger toggle that logs save/message operations.

Integration feasibility: mechanically trivial (single composer require, one YAML file, an optional vendor_copy.php post-install script). Substantively risky: the config-copy-via-composer-script pattern mutates the host project's filesystem on every install/update and is a well-known source of CI drift and merge conflicts.

Technical risk — high:

  • Adoption risk: 0 stars, 0 dependents, 0 known consumers. No production evidence, no issue history to mine for failure modes.
  • Maintenance risk: "readme" maturity implies no test suite, no CI badge, no changelog, no tagged release cadence. Predis and Symfony 5.x API surfaces have both moved; an untested wrapper will silently break on major bumps.
  • Version decay: the stated floor is Symfony 5.1 (EOL since Jan 2021). Even the newest 5.4 LTS is out of security support. The package is advertised against a dead platform — assume it has not been validated on Symfony 6/7 either.
  • Bus factor: single-vendor (Experteam MX), no stated support channel.
  • Correctness surface: message dispatch semantics (retry, ack, dead-letter, idempotency) are not described in the README. For a queue transport, that is the entire risk profile.

Key questions before any commitment:

  1. Is the target stack Laravel, Symfony, or framework-agnostic PHP? (If Laravel: stop here.)
  2. What does "dispatch message queues" mean concretely — Redis lists, streams, pub/sub? At-most-once or at-least-once? Retry/backoff/DLQ behavior?
  3. Does serialize_groups reuse Symfony Serializer groups? If so, what prevents over-exposure of entity fields into Redis payloads?
  4. How are message_class mappings resolved — container, reflection, or string convention? What is the failure mode on a typo?
  5. Does the Predis wrapper support cluster, sentinel, TLS, and connection pooling, or only a single host?
  6. Is elk_logger synchronous and blocking on the request path?

Verdict: MIT license makes forking viable, but there is no compelling reason to adopt this over first-party primitives. Recommend no-go as a dependency; consider it a ~1–3 dev-day reference implementation if the team wants the entity-prefix + serialize-group convention internally.

Integration Approach

Stack fit:

  • Laravel target: do not integrate. Use Illuminate\Support\Facades\Redis for read/write, Illuminate\Queue\RedisQueue (optionally Horizon) for dispatch, and Laravel's config/*.php + a ServiceProvider if the entity-prefix convention is genuinely wanted. Net new code is small and fully under team ownership.
  • Symfony target: integration is feasible but must be treated as an unmaintained third-party. Pin exactly, vendor the config into config/packages/ manually (skip the vendor_copy.php post-install script), and add a contract test around the client and transport.
  • Framework-agnostic services: consume only the underlying classes via Composer; discard the bundle wiring.

Migration path (Symfony):

  1. Spike: install in a throwaway branch, instantiate the client against a scratch Redis, confirm supported Predis major and PHP constraint via composer why-not.
  2. Fork to an internal namespace (Acme\RedisTransport) under MIT — strip the vendor_copy.php script, replace the YAML example with a checked-in config, add PHPUnit coverage for save/message paths.
  3. If Laravel: port only the two behaviors (~150–300 LOC) into app/Support/Redis/ with a RedisTransportServiceProvider.

Compatibility checks to run before writing code:

  • composer.json require block: Symfony version range, Predis version range, PHP floor. Any of these alone can veto the integration on a modern app.
  • Symfony 6/7 deprecation scan (bundle extension return types, TreeBuilder, autowiring aliases).
  • Redis server version and whether the deployment is single-node, sentinel, or cluster.

Sequencing:

  1. Framework decision gate (kills or greenlights everything else).
  2. Dependency audit + license/security scan (~0.5 day).
  3. Isolated spike against non-production Redis (~1 day).
  4. Fork-or-port decision with an explicit owner (~1–3 days).
  5. Pilot on one low-risk entity with save: false, message: true to exercise only the queue path.
  6. Expand entity coverage; only then enable the request-path save writes.

Compatibility note: serialize_groups binds the persistence schema to serializer groups, so entity changes become Redis-schema changes. Any rollout must include a key-prefix/versioning convention (e.g., prefix includes a schema version) before the first production write, because there is no documented migration tooling.

Operational Impact

Maintenance: the dominant cost is not the code — it is the absence of an upstream. Expect to own the fork outright: Predis major upgrades, Symfony major upgrades, and PHP minor bumps all become internal work. Budget roughly 2–4 days/year of stewardship for a package this small, plus the risk of a Redis-format migration if the serializer contract changes. MIT + small surface makes this tractable; it does not make it free.

Support: no vendor SLA, no issue traffic, no community to search when something breaks. On-call runbooks must be written internally from scratch. Compare against symfony/messenger or Laravel queues, where failure modes are documented and widely encountered.

Scaling:

  • Predis is single-connection-per-process by default; confirm whether the wrapper exposes persistent connections or a pool. Under queue-dispatch load, unpooled connections are a common throughput ceiling.
  • No documented cluster/sentinel support — treat horizontal Redis scaling as unproven until tested.
  • The elk_logger toggles sit on the save and message paths. If they are synchronous, they add latency and a second failure domain to every write. Verify they are fire-and-forget or sampled.
  • Message volume scaling is bounded by whatever the transport's underlying Redis primitive is (list vs stream); streams give consumer groups and ack semantics, lists do not. This materially changes the scaling story.

Failure modes to instrument before the pilot:

  • Redis unavailable: does save fail open (degrade to DB) or fail the request? Undefined in the README — must be decided explicitly.
  • Serialization failure: an entity that cannot be serialized under the configured group should not produce a half-written key. Check for atomicity (single SET vs multi-command).
  • Message loss / duplication: no documented retry, DLQ, or idempotency key. Assume at-most-once and design compensating logic, or you will discover this during an incident.
  • Schema drift: entity fields renamed or removed while old keys remain → poisoned reads. Mitigate with versioned prefixes and a TTL policy.
  • Silent misconfiguration: message_class is string-resolved; a typo likely surfaces only at dispatch time, on the queue worker, not at boot. Add a container-compile or boot-time assertion.
  • ELK/observability coupling: a broken log sink should never block a queue dispatch; verify.

Ramp-up: the code surface is small, so a mid-level engineer can read it in an afternoon. The real ramp-up cost is institutional — the team must reconstruct the contracts the README omits (delivery semantics, failure behavior, scaling limits) through testing rather than documentation. Estimate 1–2 days of a senior engineer's time to produce an internal design note that a vendor would normally supply.

Overall recommendation: treat as a reference design, not a dependency. For a Laravel stack the answer is unambiguous — use first-party Redis and queue primitives. For a Symfony stack, a fork under MIT with added tests and explicit failure-mode decisions is defensible if the entity-prefix/serialize-group convention saves real application code; otherwise symfony/messenger + symfony/cache covers the same ground with a maintained upstream and a documented operational contract.

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.
steadrun/laravel-monitor
labyrinthe/connect-laravel
elmogy/layan
drewdan/sentinel-client
dskripchenko/laravel-llm
fatryst/nuonuo
stevenay/myanfont
gmostafa/php-graphql-client
xeviant/paystack
snowsoft/faker
meditationsteps/blogetc
animalyoung/laravel-influxdb
onix-solutions/sms-telera
lonely-lights/prosetta
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin