Add typed events and metrics to the metadata module #88
Labels
enhancement
New feature or request
metadata
Metadata Module
nice-to-have
Features not required in upcoming milestone
Milestone
Summary
Implement Typed Events for Metadata Module
Problem Definition
Typed Event Conversion
The SDK recently added support for typed events and deprecated the existing style of kv event attributes. This issue is for refactoring the existing events into proto messages and wiring up typed events to replace the existing ones.
Metric Publishing
Tracking the volume of information being handled on chain and the duration of requests is an important part of monitoring the health of the blockchain. Metrics were add. Along with ensuring proper events are published the associated metrics should also be put in place. These two efforts are linked because they typically are inserted at the same point in the code for similar reasons.
defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker)
defer telemetry.MeasureSince(time.Now(), "metadata", "validation|scope|specification", "get|set|validate|etc")
defer telemetry.IncrCounter(1, "new", "scope|record|specification")
Example Metric and Events from staking module msg_server
For Admin Use
The text was updated successfully, but these errors were encountered: