HashedWheelTimer exception when running tests in parallel

45 views
Skip to first unread message

Christian Kaps

unread,
Apr 19, 2018, 2:22:58 AM4/19/18
to ReactiveMongo - http://reactivemongo.org
Hi,

I have an app which runs a lot of test against an embedded MongoDB in parallel. Now I get an HashedWheelTimer exception and some tests failed.

p.s.a.i.n.u.HashedWheelTimer - You are creating too many HashedWheelTimer instances. HashedWheelTimer is a shared resource that must be reused across the JVM,so that only a few instances are created.


Is this an bug?

Best regards,
Christian

Cédric Chantepie

unread,
Apr 22, 2018, 6:06:08 AM4/22/18
to ReactiveMongo - http://reactivemongo.org
The ChannelFactory is managed by MongoConnection, which is a pool. According that design it's not expected to create so many pool that it raise the issue with Netty, as the pool can itself be used for several parallel tests.

Christian Kaps

unread,
Apr 26, 2018, 9:09:42 AM4/26/18
to ReactiveMongo - http://reactivemongo.org
Any idea how I could solve that with Play and DI? Play creates a new application for every test, so I have no idea how I could provide a shared pool between the tests.

Cédric Chantepie

unread,
May 6, 2018, 2:29:59 PM5/6/18
to ReactiveMongo - http://reactivemongo.org
Not using such DI or executing more tests per injected app.
Reply all
Reply to author
Forward
0 new messages