Allow lazily connecting to the database
We really need a backlog for this sort of thing, but the module
shouldn't fail to initialize if the database happens to be
offline while it loads up, since it sometimes takes a little
while for the database engine to start properly.
This makes sure the module attempts to reconnect to the database
in case the connection dies. When we merge the reports-module
with merlin, this problem will largely go away as merlin already
handles these cases properly.
Signed-off-by: Andreas Ericsson <ae@op5.se>