set gems and database