in reply to Re^2: Dancer app losing DB connection
in thread Dancer app losing DB connection

That would make some sense. If the connection info was going out of scope, why only the password (since user and dbname were fine)?
Debugging this is going to be difficult I think...