Add "report" framework for collecting library diagnostics.

And adapt some code to now emit warning/error report messages.

The reporting makes use of the abstractions already provided by broker:
the report manager is an endpoint created by broker and report messages
get collected in queues attached to that endpoint or its peers.
Messages are sent with a topic of "broker.report.<level>.<subtopic>" if
one is interested in only a subset of the reports.