Couple minor improvemts to the launch loop and db calls