o bugfix: move sync db and encpool creation to api.