class Mongo::Monitoring::Event::Cmap::ConnectionCheckedIn

Event published when a connection is returned to a connection pool.

@since 2.9.0

Attributes

address[R]

@return [ Address ] address The address of the server the connection was connected to.

@since 2.9.0

connection_id[R]

@return [ Integer ] connection_id The ID of the connection.

@since 2.9.0

pool[R]

@return [ Mongo::Server::ConnectionPool ] pool The pool that the connection was checked in to.

@since 2.11.0 @api experimental

Public Class Methods

new(address, id, pool) click to toggle source

Create the event.

@example Create the event.

ConnectionCheckedIn.new(address, id, pool)

@since 2.9.0 @api private

# File lib/mongo/monitoring/event/cmap/connection_checked_in.rb, line 49
def initialize(address, id, pool)
  @address = address
  @connection_id = id
  @pool = pool
end

Public Instance Methods

summary() click to toggle source

Returns a concise yet useful summary of the event.

@return [ String ] String summary of the event.

@note This method is experimental and subject to change.

@since 2.9.0 @api experimental

# File lib/mongo/monitoring/event/cmap/connection_checked_in.rb, line 63
def summary
  "#<#{self.class.name.sub(/^Mongo::Monitoring::Event::Cmap::/, '')} " +
      "address=#{address} connection_id=#{connection_id} pool=0x#{pool.object_id}>"
end