default DB & password

When using an specific DB or a password, the retry mecanism doesn't change DB or reauth after reconnecting.
Made a quick patch + unit test to correct this.