Class: ExportStatsJob

Inherits:
Object
  • Object
show all
Defined in:
lib/palava_machine/jobs/export_stats_job.rb

Defined Under Namespace

Classes: StatsExporter

Class Method Summary collapse

Class Method Details

.perform(redis_address = 'localhost:6379', mongo_address = 'localhost:27017') ⇒ Object



51
52
53
54
55
56
57
# File 'lib/palava_machine/jobs/export_stats_job.rb', line 51

def perform(redis_address = 'localhost:6379', mongo_address = 'localhost:27017')
  se = StatsExporter.new(redis_address, mongo_address)
  se.import_timestamps! "room_peaks"
  se.import_timestamps! "connection_time"
  se.prune_timestamps!
  se.store_in_mongo!
end