cleanup and reenable db caching