major refactor. moved roles, hosts and global into own db collection, made keys '_id'