added some db infastructure