Added DB support to the repowatch module