EventHandler: Use telemetry framework for EventHandler.call_count

Put the IntCounter into a std::optional rather than initializing
it at EventHandler construction time as that will currently expose
a time series per event handler through the Prometheus API.
This commit is contained in:
Arne Welzel 2023-02-15 18:04:21 +01:00
parent a40025b82d
commit 56a8b99965
4 changed files with 42 additions and 3 deletions

View file

@ -0,0 +1,4 @@
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
zeek, event-handler-invocations, [zeek_init], 1
zeek, event-handler-invocations, [connection_state_remove], 500
zeek, event-handler-invocations, [zeek_done], 1