added new entities and fixed transaction handling