Replace sql database with persistant cache db