MPIIComputationalEpigenetics / DeepBlue

DeepBlue Epigenomic Data Server
Other
2 stars 0 forks source link

Connection::Connection() returns an invalid connection #107

Closed felipealbrecht closed 8 years ago

felipealbrecht commented 8 years ago

The connection is not build correctly when too many connections are made to the mongodb server or there is a network fault.

It can result in an exception be thrown or an invalid connection object. Both cases are unacceptable.

This problem usually happens in the score_matrix builder, where many threads (number of experiments x number of chromosomes) are created, and each thread has its own Connection object.

It could (and must) be fixed in the score_matrix, e.g. do not allowing more than N simultaneous threads. But before, we have to fix the connection constructor.