implemented relation events

Closes #87