basic working prototype with db enabled