implement node addition and removal events