-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Connection pooling seems to be broken #24
Comments
It seems that I have the same problem. I'm using an I put up my code @ https://gist.github.com/1344664 edit: I'm using |
tsuna are you using scala 2.8.x or 2.9x. Did you recompile querulous 2.5.0 to work with 2.9.x? |
I'm using |
Halp! :) Am I doing something obviously wrong? Maybe I shouldn't be getting a new This issue is a show stopper for me right now :( |
Same here, i am using Scala 2.9.1 but querulous 2.5.0 does not seem to work with that and i am forced to use 1.2.0-generic. I have posted on stackoverflow as well but awaiting a response http://stackoverflow.com/questions/7962766/querulous-connection-pooling-does-not-seem-to-work |
also i seem to be getting the same MyDataSource.queryEvaluator still the issue. |
I can still reproduce with v 2.5.1 I also run into this one:
|
I added some print statements in I think either Querulous isn't using Apache's DBCP API properly, or there's a problem in Apache's code. All these layers of factories are giving me a nausea, I think I'll look at using another simpler connection pooling library or write my own. |
This has been fixed, I believe, in the most recent versions. I ran into this issue a few weeks ago and fixed a race condition in FuturePool. |
Can you give us the link to the fix? |
This fix made JavaTimer more resilient This fixed a race condition in FuturePool |
If you can reproduce this with querulous 2.6.5+, please feel free to re-open this issue. |
OK, but FWIW I do not believe my problem had to do with these bugs. I guess I was using Querulous incorrectly, but I still don't see how. |
We have this object from which we are fetching our queryEvaluator
object MyDataSource {
val queryFactory = new SqlQueryFactory
val apachePoolingDatabaseFactory = new ApachePoolingDatabaseFactory(
"SELECT 1",
10,
10,
new Duration(1000),
new Duration(10),
true,
new Duration(30000))
val queryEvaluatorFactory = new StandardQueryEvaluatorFactory(apachePoolingDatabaseFactory, queryFactory)
val queryEvaluator = queryEvaluatorFactory(dbConfig.driverClassName, dbConfig.url, dbConfig.username, dbConfig.password)
}
We are not explicitly closing connections, assuming that it is handled. We seem to be running out of connections on our MySQL db.
We are using the following dependencies
libraryDependencies += "com.twitter" % "querulous" % "1.2.0-generic"
libraryDependencies += "mysql" % "mysql-connector-java" % "5.1.12"
The text was updated successfully, but these errors were encountered: