trace2: Capture child_start and child_exit events
Git allows a caller to receive metrics and events through GIT_TRACE
and
relatives; this has been around for a while. If needed, one could enable
these before this change with GIT_TRACE=1 ./gitaly
on boot. While this
works for debugging, it logs a lot of events and thus is not enabled on
production system.
This change introduces a mechanism to enable the second iteration of the tracing from Git. Again Git exposes a lot of events and metrics, though now the there's improvements like setting a custom sink, exposing JSON over unstructured text, and better context among lines emitted.
This merge request is a small iteration capturing just 2 events and log those to the usual infrastructure. This allows the rollout to start much quicker, and allows us to add new messages later.