Class: RabbitMQ::Actors::HeadersConsumer Abstract
- Inherits:
-
Base::Consumer
- Object
- Base::Agent
- Base::Consumer
- RabbitMQ::Actors::HeadersConsumer
- Defined in:
- lib/rabbitmq/actors/patterns/headers/headers_consumer.rb
Overview
This class is abstract.
Subclass and override #perform to define your customized headers worker class.
A consumer of messages from RabbitMQ based on exchange and message headers matching.
Instance Attribute Summary collapse
-
#binding_headers ⇒ Object
readonly
Returns the value of attribute binding_headers.
-
#headers_name ⇒ Object
readonly
Returns the value of attribute headers_name.
Attributes inherited from Base::Agent
Instance Method Summary collapse
-
#initialize(headers_name:, binding_headers:, **opts) ⇒ HeadersConsumer
constructor
Rest of options required by your subclass.
Methods inherited from Base::Consumer
Constructor Details
#initialize(headers_name:, binding_headers:, **opts) ⇒ HeadersConsumer
Rest of options required by your subclass.
72 73 74 |
# File 'lib/rabbitmq/actors/patterns/headers/headers_consumer.rb', line 72 def initialize(headers_name:, binding_headers:, **opts) super(opts.merge(headers_name: headers_name, binding_headers: binding_headers)) end |
Instance Attribute Details
#binding_headers ⇒ Object (readonly)
Returns the value of attribute binding_headers.
64 65 66 |
# File 'lib/rabbitmq/actors/patterns/headers/headers_consumer.rb', line 64 def binding_headers @binding_headers end |
#headers_name ⇒ Object (readonly)
Returns the value of attribute headers_name.
57 58 59 |
# File 'lib/rabbitmq/actors/patterns/headers/headers_consumer.rb', line 57 def headers_name @headers_name end |