Decouple db require