Class: Emque::Producing::ChangesPayloadGenerator

Inherits:
Object
  • Object
show all
Defined in:
lib/emque/producing/message/message_with_changeset.rb

Instance Method Summary collapse

Constructor Details

#initialize(opts = {}) ⇒ ChangesPayloadGenerator



30
31
32
33
# File 'lib/emque/producing/message/message_with_changeset.rb', line 30

def initialize(opts = {})
  @original = opts.fetch(:original, {}) || {}
  @updated = opts.fetch(:updated, {}) || {}
end

Instance Method Details

#executeObject



35
36
37
# File 'lib/emque/producing/message/message_with_changeset.rb', line 35

def execute
  {:original => original, :updated => updated, :delta => delta}
end