Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 3.63 KB

File metadata and controls

49 lines (35 loc) · 3.63 KB

Advanced documentation map

Use this index when you need to customize internals: custom middleware, adapters, queue providers, tooling, or diagnostics.

Configuration and infrastructure

Middleware, envelopes, and handlers

Queue adapters and interoperability

Tooling, diagnostics, and storage

Internals and contribution

  • Internals guide — local QA tooling (PHPUnit, Infection, Psalm, Rector, ComposerRequireChecker).

Queue provider registry

When multiple queue names share infrastructure, rely on QueueProviderInterface:

  • A queue name is passed to QueueProviderInterface::get($queueName) and resolved into a configured QueueInterface instance.
  • Providers typically construct adapters lazily via yiisoft/factory and call AdapterInterface::withChannel($channel) to switch broker-specific channels.
  • Default implementation (AdapterFactoryQueueProvider) enforces a strict registry defined in yiisoft/queue.channels. Unknown names throw ChannelNotFoundException.
  • Alternative providers include:
    • PrototypeQueueProvider — clones a base queue/adapter, switching only the channel name (useful when all queues share infrastructure but risks typos).
    • CompositeQueueProvider — aggregates multiple providers and selects the first that knows the queue name.
  • Implement QueueProviderInterface to introduce custom registries or fallback strategies, then register the implementation in DI.