added relation management that i stole from upstream. Added Roles