我只是按照以下链接使用grails和Mongo db构建示例应用程序。
http://etcpe9.wordpress.com/2012/01/28/beginning-grails-2-0-with-mongodb/
但每次我创建一个新人,我都可以在mongod shell中看到以下内容 XX连接现已打开。
我不确定这是否意味着连接泄漏?
Thu Feb 21 21:04:06 [initandlisten] connection accepted from 127.0.0.1:50526 #22
(1 connection now open)
Thu Feb 21 21:04:27 [initandlisten] connection accepted from 127.0.0.1:50527 #23
(2 connections now open)
Thu Feb 21 21:04:27 [initandlisten] connection accepted from 127.0.0.1:50528 #24
(3 connections now open)
Thu Feb 21 21:04:36 [initandlisten] connection accepted from 127.0.0.1:50531 #25
(4 connections now open)
Thu Feb 21 21:04:36 [initandlisten] connection accepted from 127.0.0.1:50532 #26
(5 connections now open)
Thu Feb 21 21:04:48 [initandlisten] connection accepted from 127.0.0.1:50533 #27
(6 connections now open)
Thu Feb 21 21:04:53 [initandlisten] connection accepted from 127.0.0.1:50534 #28
(7 connections now open)
Thu Feb 21 21:04:59 [initandlisten] connection accepted from 127.0.0.1:50535 #29
(8 connections now open)
Thu Feb 21 21:05:04 [initandlisten] connection accepted from 127.0.0.1:50536 #30
(9 connections now open)
Thu Feb 21 21:05:10 [initandlisten] connection accepted from 127.0.0.1:50537 #31
(10 connections now open)
答案 0 :(得分:3)
不,这是维护连接池的mongodb驱动程序,因此它可以重用连接。