ngauthier/hydra — Issue #55: runners & colliding databases
Author: avramd
Created: 2011-12-26 06:09:57+00:00
State: open

Hello,

I'm having trouble with Hydra hanging part way through a run. Sometimes gets as far as 20 specs, sometimes as few as 2. Then it just sits there, with no advancement after 10x as long as all my specs take to run serially.

I am only running locally (one worker), and things run fine when I specify only one runner. This is a rails app, and many specs use the same models as one another, so my best guess is that my database is getting frotzed by simultaneous access to the same objects. Sound like a good theory? After things go south, even running only 1 worker fails until I blow away my db and start from scratch.

I went through closed tickets, and found https://github.com/ngauthier/hydra/issues/43. This is a question about separate db's per runner, and the answer is "yes, but you have to do it yourself" - however the answer points to an init file for workers, not for runners. So...

How would you use a worker init file to get separate DB's per runner?

Also, would it be hard to port the worker init file feature to 0.20.0? If I'm seeing things correctly, it's not in there. Sadly we're on RSpec 1.x and Rails 2.x.

Thanks!