Populator — Documentation by YARD 0.9.37 (original) (raw)

Class: Mongo::Server::ConnectionPool::PopulatorPrivate

Inherits:

Object

Includes:

BackgroundThread

Defined in:

lib/mongo/server/connection_pool/populator.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

A manager that maintains the invariant that the size of a connection pool is at least minPoolSize.

Constant Summary

Constants included from Loggable

Loggable::PREFIX

Instance Attribute Summary collapse

Instance Method Summarycollapse

Methods included from BackgroundThread

#run!, #running?, #stop!

Methods included from Loggable

#log_debug, #log_error, #log_fatal, #log_info, #log_warn, #logger

Constructor Details

#initialize(pool, options = {}) ⇒ Populator

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Populator.

32 33 34 35 36 # File 'lib/mongo/server/connection_pool/populator.rb', line 32 def initialize(pool, options = {}) @pool = pool @thread = nil @options = options end

Instance Attribute Details

#options ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

38 39 40 # File 'lib/mongo/server/connection_pool/populator.rb', line 38 def options @options end

Instance Method Details

#pre_stop ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

40 41 42 # File 'lib/mongo/server/connection_pool/populator.rb', line 40 def pre_stop @pool.populate_semaphore.signal end