Module: EventStore::HTTPClient::Handler
- Defined in:
- lib/event_store_http_client/handler.rb
Defined Under Namespace
Modules: Build
Classes: NullCommand
Class Method Summary
collapse
Instance Method Summary
collapse
Class Method Details
.included(cls) ⇒ Object
4
5
6
7
|
# File 'lib/event_store_http_client/handler.rb', line 4
def self.included(cls)
cls.send :dependency, :logger, Logger
cls.extend Build unless cls.ancestors.include? Build
end
|
Instance Method Details
#!(event, attempt = 0) ⇒ Object
15
16
17
18
19
20
21
22
|
# File 'lib/event_store_http_client/handler.rb', line 15
def !(event, attempt=0)
logger.trace "Event sourced: #{event}"
command = command(event)
logger.trace "Executing #{command.class} on #{event}"
command.!
logger.debug "Executed #{command.class}"
end
|
10
11
12
13
|
# File 'lib/event_store_http_client/handler.rb', line 10
def configure(receiver)
receiver.handler = self
self
end
|