Module: Clamour::Message

Extended by:
ActiveSupport::Autoload, ActiveSupport::Concern
Included in:
Sent
Defined in:
lib/clamour/message.rb

Overview

What is sent over the wire.

Defined Under Namespace

Modules: ClassMethods Classes: Receive, Sent

Instance Method Summary collapse

Instance Method Details

#publish(configuration = Clamour.configuration) ⇒ Object



39
40
41
42
43
# File 'lib/clamour/message.rb', line 39

def publish(configuration = Clamour.configuration)
  bus = Clamour::Bus.new(configuration)
  sent_message = Clamour::Message::Sent.new(payload: self)
  bus.publish(sent_message)
end