added DB class and registry