Bugfix: A handled message is recorded with one write
Description
A message with several handlers wrote one row per handler and read the handlers it had already recorded twice. It now writes the rows of all its handlers in one statement and reads the recorded handlers once. A message reaches each handler once, as before.
Impact
The workers need fewer database statements per message; nothing to do.