Skip to content

Feature: Clean API for programmatically starting Shoryuken #926

@mensfeld

Description

@mensfeld

Summary

Provide a clean, documented API for launching Shoryuken programmatically within Ruby code.

Use Cases

  1. Dynamic configuration (build YAML at runtime)
  2. Loading environment variables from external sources before startup
  3. Adding default middleware before workers are loaded
  4. Integration testing with real SQS
  5. Embedded Shoryuken in other applications

Current Workaround

Users must call load on the bin script or use undocumented Shoryuken::Runner.instance.run.

Proposed Solution

Document and stabilize the programmatic API:

Shoryuken.boot do |config|
  config.queues = ['my_queue']
  config.concurrency = 10
  # ...
end

Shoryuken.start  # Blocking
Shoryuken.stop   # Graceful shutdown

Original Issue

Originally requested in #680, closed by stale bot. Community workarounds exist in comments.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions