Class: Dionysus::Producer::Genesis
- Inherits:
-
Object
- Object
- Dionysus::Producer::Genesis
- Defined in:
- lib/dionysus/producer/genesis.rb
Defined Under Namespace
Classes: CannotExecuteGenesisForModelThatIsOnlyDependency, Performed, StreamJob, Streamer
Instance Method Summary collapse
-
#initialize(config: Dionysus::Producer.configuration) ⇒ Genesis
constructor
A new instance of Genesis.
- #stream(topic:, model:, number_of_days:, from: nil, to: nil, streamer_job: Dionysus::Producer::Genesis::Streamer::StandardJob) ⇒ Object
Constructor Details
#initialize(config: Dionysus::Producer.configuration) ⇒ Genesis
Returns a new instance of Genesis.
7 8 9 |
# File 'lib/dionysus/producer/genesis.rb', line 7 def initialize(config: Dionysus::Producer.configuration) @config = config end |
Instance Method Details
#stream(topic:, model:, number_of_days:, from: nil, to: nil, streamer_job: Dionysus::Producer::Genesis::Streamer::StandardJob) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/dionysus/producer/genesis.rb', line 11 def stream(topic:, model:, number_of_days:, from: nil, to: nil, streamer_job: Dionysus::Producer::Genesis::Streamer::StandardJob) ensure_genesis_not_executed_for_model_that_is_only_a_dependency(model, topic) enqueue_stream_model_for_topic(topic, model, from, to, number_of_days, streamer_job) publish_genesis_performed(model: model, topic: topic, number_of_days: number_of_days) end |