Sha256: 1f46ab2f5ce5a282353920e7477317f7e44df2875059a1d18827ae16eb503014
Contents?: true
Size: 547 Bytes
Versions: 20
Compression:
Stored size: 547 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 config_param :database, :string, :default => 'fluent' config_param :collection, :string, :default => 'out_mongo_backup' # TODO: optimize end def configure(conf) super backup = MongoOutputForBackup.new backup.configure(conf.merge({'capped' => true})) @outputs.unshift(backup) end end end
Version data entries
20 entries across 20 versions & 1 rubygems