This was an epically long change, and a terrible idea, but it compiles.
This was essentially a cascade that came about because I can't blend jet
and bob in the same transaction. In for a penny, I guess...
This involved moving a lot of stuff to the platform layer since I don't
want event interfaces leaking out.
Also this includes a fix to the user authentication which I had
previously broken by making a platform-layer user object independent of
the database layer.