类:Mongo::Monitoring::Event::Cmap::ConnectionCheckedIn
- 继承:
-
Base
- 对象
- Event::Base
- Base
- Mongo::Monitoring::Event::Cmap::ConnectionCheckedIn
- 定义于:
- lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb
Overview
当连接返回到连接池时发布的事件。
实例属性摘要折叠
-
#地址⇒ 地址
只读
地址 连接所连接到的服务器的地址。
-
# connection_id ⇒ 整数
只读
Connection_id 连接的ID 。
-
#池⇒ Mongo::Server::ConnectionPool
只读
已签入到。
实例方法摘要折叠
-
#初始化(解决, ID , 池 ) ⇒ ConnectionCheckedIn
构造函数
private
创建事件。
-
#摘要⇒ string
返回简洁而有用的事件摘要。
构造函数详情
#初始化(解决, ID , 池 ) ⇒ ConnectionCheckedIn
此方法是私有 API 的一部分。 您应尽可能避免使用此方法,因为它将来可能会被删除或更改。
创建事件。
52 53 54 55 56 |
# File 'lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb', line 52 def 初始化(地址, id, 池) @address = 地址 @connection_id = id @pool = 池 end |
实例属性详细信息
#解决⇒地址(只读)
返回解决连接所连接到的服务器的解决。
31 32 33 |
# File 'lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb', line 31 def 地址 @address end |
# connection_id ⇒整数(只读)
返回 connection_id 连接的 ID。
36 37 38 |
# File 'lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb', line 36 def connection_id @connection_id end |
#池⇒ Mongo::Server::ConnectionPool (只读)
已签入到。
43 44 45 |
# File 'lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb', line 43 def 池 @pool end |
实例方法详细信息
#摘要⇒ string
注意:
此方法是实验性的,可能会发生变化。
返回简洁而有用的事件摘要。
66 67 68 69 |
# File 'lib/ Mongo/ 监控/ 事件/cmap/connection_checked_in.rb', line 66 def 总结 " #< #{ { self . class . name . sub ( / ^Mongo::Monitoring::Event::Cmap:: / , ' ' ) } " + "解决= #{解决} connection_id= #{ connection_id }池 = 0 x #{池。object_id } } > " end |