Sha256: 96a824db9d8d345aa504bf17bb1f67dfbcdcc3529d42bc00dd96c649ff15f026
Contents?: true
Size: 540 Bytes
Versions: 2
Compression:
Stored size: 540 Bytes
Contents
require 'fluent/plugin/out_copy' require 'fluent/plugin/out_mongo' module Fluent class MongoBackupOutput < CopyOutput Fluent::Plugin.register_output('mongo_backup', self) class MongoOutputForBackup < MongoOutput def initialize super # default parameters @database_name = 'fluent' @collection_name = 'out_mongo_backup' end end def configure(conf) super backup = MongoOutputForBackup.new backup.configure(conf.merge({'capped' => true})) @outputs.unshift(backup) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
fluent-plugin-mongo-0.3.1 | lib/fluent/plugin/out_mongo_backup.rb |
fluent-plugin-mongo-0.3.0 | lib/fluent/plugin/out_mongo_backup.rb |