Sha256: d9ac978f360998d41ff3bd66f92ad8100b62ddb58f2b6b57519dfa91e0f904c7
Contents?: true
Size: 573 Bytes
Versions: 2
Compression:
Stored size: 573 Bytes
Contents
module Dryad module Consul class ConfigObserver < ::Dryad::Core::Observer def initialize @last_version = 0 end def update(time, config_desc, exception) if exception puts "(#{time}) [#{self.class.to_s}] #{exception.message}" elsif config_desc if @last_version < config_desc.version update_self(config_desc) @last_version = config_desc.version end end end def update_self(config_desc) raise "Implement this method" end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dryad-consul-0.3.2 | lib/dryad/consul/config_observer.rb |
dryad-consul-0.3.0 | lib/dryad/consul/config_observer.rb |