Mostly fix a bug with the JOIN bundler trigger

It was adding a new trigger each time it saw a JOIN of
any kind, which would never have been cleaned up.

Considering some kind of timestamp to warn on old
triggers.
Mass refactoring