Sha256: 4a26b2559f5667b9177dafca2f1f5f84d3f473374c72171110238764a763cc87
Contents?: true
Size: 640 Bytes
Versions: 13
Compression:
Stored size: 640 Bytes
Contents
module PhobosDBCheckpoint module EventHelper def configured_listener listener = Phobos .config .listeners .find { |l| l.group_id == self.group_id } raise(ListenerNotFoundError, self.group_id) unless listener listener end def configured_handler configured_listener .handler .constantize end def method_missing(m, *args, &block) rex = m.to_s.match /^fetch_(.+)/ if rex handler = configured_handler.new return handler.send(rex[1], payload) if handler.respond_to?(rex[1]) else super end end end end
Version data entries
13 entries across 13 versions & 1 rubygems