D.Gray-man 19
12/09
碧海のAiON 4
12/18
最上の命医 8
12/22
×××HOLiC 16
鋼の錬金術師 24
ながされて藍蘭島 16
12/25
セキレイ 9
黒神 13
12/26
文学少女と美味しい噺(レシピ) 1
朝霧の巫女 6
スポンサーサイト
# Disconnects all connections in the pool, and clears the pool.
def disconnect!
@reserved_connections.each do |name,conn|
checkin conn
end
@reserved_connections = {}
@connections.each do |conn|
conn.disconnect!
end
@connections = []
end
# Clears the cache which maps classes
def clear_reloadable_connections!
@reserved_connections.each do |name, conn|
checkin conn
end
@reserved_connections = {}
@connections.each do |conn|
conn.disconnect! if conn.requires_reloading?
end
@connections = []
end
続きを読む
@@ -64,6 +64,7 @@
#
# The default ConnectionPool maximum size is 5.
def initialize(spec)
+ pp caller
@spec = spec
# The cache of reserved connections mapped to threads
@@ -179,6 +180,9 @@
# - ConnectionTimeoutError: no connection can be obtained from the pool
# within the timeout period.
def checkout
+ puts "checkout"
+ puts @size
+ puts @connections.size
# Checkout an available connection
@connection_mutex.synchronize do
loop do
Author:まこp