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

Workerman Bundle Laravel Package

crazy-goat/workerman-bundle

Symfony bundle integrating Workerman to run a high-performance async HTTP server, scheduler and supervisor in pure PHP. Keeps the Symfony kernel/container alive between requests for faster apps. Supports SO_REUSEPORT and optional direct Request creation for speed.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Replacing Traditional Web Stacks: Eliminates the need for separate components (Nginx, PHP-FPM, Supervisor, Cron) by consolidating them into a single PHP-based solution, reducing operational complexity and infrastructure costs.
  • High-Performance Asynchronous Workloads: Enables event-driven architectures for real-time applications (e.g., WebSockets, chat apps, live dashboards) without external dependencies like Node.js or Go.
  • Serverless-Like Scaling: Supports horizontal scaling via reuse_port (Linux kernel load balancing) and process pooling, ideal for microservices or high-traffic APIs.
  • PHAR Packaging: Simplifies deployment by bundling the entire application (including dependencies) into a single executable, reducing deployment friction for edge/embedded use cases.
  • Roadmap for Event-Driven Features: Justifies investment in async PHP features (e.g., php-event extension) to align with modern architectures like serverless or reactive systems.
  • Build vs. Buy: Avoids licensing costs of proprietary solutions (e.g., Envoy, custom Go/Python services) while maintaining PHP ecosystem familiarity.
  • Use Cases:
    • Real-time APIs (WebSocket-based notifications, collaborative tools).
    • High-throughput batch processing (replacing cron + Supervisor).
    • Edge computing (PHAR deployments to IoT/low-resource devices).
    • Legacy system modernization (gradual migration from synchronous PHP-FPM).

When to Consider This Package

  • Avoid if:
    • Your stack already uses async-native tools (Node.js, Go, Rust) where PHP interop isn’t a bottleneck.
    • You need native Windows support (Workerman’s connection introspection is POSIX-only).
    • Your team lacks PHP async expertise (debugging event loops requires familiarity with Workerman’s internals).
    • You require advanced gRPC/Protocol Buffers features (Workaround: GRPC_ENABLE_FORK_SUPPORT=1 env var).
    • Your workload is CPU-bound (Workerman excels at I/O-bound tasks; CPU-heavy ops may still need FPM).
  • Consider alternatives:
    • Swoole (higher performance, but less Symfony integration).
    • RoadRunner (PHP worker pool with PSR-15 support, but heavier dependency).
    • Traditional LAMP (if operational simplicity outweighs performance needs).
    • Serverless (if vendor lock-in or cold starts are acceptable).

How to Pitch It (Stakeholders)

For Executives:

"This package lets us replace 4+ infrastructure components (Nginx, PHP-FPM, Supervisor, Cron) with pure PHP, cutting cloud costs by ~30% while enabling real-time features (e.g., live updates, WebSockets) without hiring Go/Node.js devs. It’s like serverless, but self-hosted and PHP-native. PHAR deployments also simplify edge/IoT rollouts. The tradeoff? A steeper learning curve for async PHP—but our team can pilot it on non-critical services first."

For Engineering:

*"Workerman-Bundle gives us:

  • Event-loop efficiency: Symfony kernel persists between requests (no DI container rebuilds).
  • Unified tooling: Start/stop/reload servers via bin/console (no manual Supervisor/Cron config).
  • Extensibility: Custom middlewares (e.g., auth, rate-limiting) and reload strategies (e.g., memory-based restarts).
  • PHARs: Single-file deployments for Docker/K8s edge cases. Risks: Debugging async code requires new skills, and Windows support is limited. We’d start with a proof-of-concept for a high-traffic API to measure performance vs. PHP-FPM."*

For DevOps:

*"This reduces our server sprawl by consolidating:

  • Web server: Replaces Nginx/PHP-FPM (but binds to port 8080 by default—we’ll need a reverse proxy for ports <1024).
  • Process manager: Built-in Supervisor replacement with graceful reloads.
  • Cron: Task scheduler with cron expressions (requires dragonmantank/cron-expression). Ops wins:
  • No more sudo for port binding (use CAP_NET_BIND_SERVICE or a proxy).
  • Logs/stdout unified in var/log/workerman.*.
  • Connection monitoring via bin/console workerman:server connections (Linux/macOS only)."*
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.
besmartand-pro/php-quality-config
sentix/ai-chatbot
terminal42/code-quality-tools
codifyo/ts-generator-bundle
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity