Weave Code
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

Asynchronous Bundle Laravel Package

simple-bus/asynchronous-bundle

Symfony bundle for asynchronous command/event handling with SimpleBus. Integrates async middleware and message dispatching so work can be queued and processed later. Part of the SimpleBus ecosystem; docs and issue tracking in the main repository.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Decoupling synchronous workflows: Enables asynchronous message handling in Laravel applications, reducing latency for user-facing operations (e.g., background jobs like report generation, notifications, or data processing). Aligns with Laravel’s native queue system but offers strongly typed message contracts and event-driven architecture.
  • Event-driven architecture: Supports building scalable microservices or modular systems where components communicate via messages (e.g., order processing pipelines, analytics pipelines). Ideal for Laravel apps integrating with Symfony or legacy systems.
  • Build vs. buy: Justifies leveraging this package over building a custom async queue system if the team lacks time/resources to optimize for reliability, retries, or dead-letter queues. Tradeoff: Unmaintained (last release 2016), but core pattern is battle-tested.
  • Roadmap alignment:
    • Resilience: Handles failures gracefully (e.g., retries, timeouts) via message contracts.
    • Performance: Offloads CPU-heavy tasks (e.g., image resizing, API calls) without blocking requests.
    • Maintainability: Abstracts async logic into reusable message handlers, reducing spaghetti code in Laravel jobs.
  • Use cases:
    • User workflows: Async email sends, profile updates, or payment confirmations.
    • Data pipelines: Batch processing (e.g., syncing with third-party APIs).
    • Legacy modernization: Adding async layers to monolithic apps without full rewrite.
    • Hybrid Symfony/Laravel: Bridges Symfony’s event bus with Laravel’s queue system.

When to Consider This Package

Adopt if:

  • Your stack is Laravel + Symfony and you need a lightweight, PHP-native async solution (no need for Redis/RabbitMQ overhead).
  • You prioritize strongly typed messages (interfaces) over Laravel’s dynamic job classes.
  • Your async workloads are moderate (not high-throughput; the package is unmaintained post-2016).
  • You’re okay with MIT license and can fork/maintain if issues arise.
  • You need event-driven architecture (e.g., CQRS, event sourcing) in Laravel.
  • Your team has Symfony experience or is willing to learn its patterns.

Look elsewhere if:

  • You need active maintenance (last release: 2016). Alternatives: Laravel Queues, Symfony Messenger, or RabbitMQ.
  • Your use case requires scalability (e.g., 10K+ messages/sec). This bundle lacks optimizations for high load.
  • You need GUI tools (e.g., monitoring queues). Consider Horizon (Laravel) or RabbitMQ Management.
  • Your team lacks PHP/Symfony expertise. The learning curve may outweigh benefits.
  • You’re not using Symfony components elsewhere. Native Laravel queues are simpler.
  • You need distributed transactions or complex routing. This package is lightweight but limited.

How to Pitch It (Stakeholders)

For Executives: "This package lets us offload slow, blocking tasks (e.g., sending emails, processing orders) to background workers, improving response times for users—like adding a ‘silent assistant’ to our app. It’s a lightweight, open-source solution that integrates with Laravel’s existing queue system, reducing infrastructure costs. Risks are manageable: it’s unmaintained, but we can fork it or migrate to a supported tool (like Symfony Messenger) later. Think of it as a quick win for performance without upfront costs."

For Engineering: *"SimpleBus/AsynchronousBundle gives us a Symfony-native way to handle messages asynchronously in Laravel, with key benefits:

  • Strong typing: Messages are PHP interfaces (e.g., ProcessOrder), making them reusable and testable.
  • Decoupling: Handlers can be updated independently of the main app.
  • Event-driven: Aligns with Laravel’s queue system but adds routing/filtering capabilities. Tradeoffs:
  • Unmaintained (last release 2016), but the core pattern is solid. We’d need to:
    1. Bridge it with Laravel’s queue system (custom listeners/adapters).
    2. Benchmark against native Laravel queues or Symfony Messenger.
    3. Plan for migration if issues arise. Proposal: Pilot for one async workflow (e.g., notifications) to validate before wider adoption. If successful, we can expand to critical paths like order processing."*

For Developers: *"This adds message-driven async processing to Laravel, similar to Symfony Messenger but with a simpler setup. Here’s how it fits:

  • Dispatch messages like Symfony but use Laravel’s queue workers to execute them.
  • Example:
    // Define a message interface
    interface SendEmailMessage { public function getEmail(): string; }
    
    // Dispatch via SimpleBus
    $this->bus->dispatch(new SendEmailMessage($user->email));
    
    // Consume in Laravel (custom listener)
    public function handle(SendEmailMessage $message) {
        Mail::to($message->getEmail())->send(new WelcomeEmail());
    }
    

Gotchas:

  • Requires custom glue code to connect SimpleBus to Laravel’s queue system.
  • No built-in retries/failed-job handling (use Laravel’s queue features separately). Why not native queues? If you need strong typing or event routing, this is cleaner than dynamic job classes."*
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.
craftcms/url-validator
directorytree/privacy-filter-classifier
directorytree/privacy-filter
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi
splash/scopes
splash/toolkit
testo/output-teamcity
testo/bridge-symfony