stellar / stellar-core

Reference implementation for the peer-to-peer agent that manages the Stellar network.
https://www.stellar.org
Other
3.11k stars 962 forks source link

Add missing events as to make it possible to better analyze network activity #4245

Open MonsieurNicolas opened 4 months ago

MonsieurNicolas commented 4 months ago

https://github.com/stellar/stellar-core/pull/3847 took a first pass at this for transaction level metrics.

Goal: make it possible to run queries in BigQuery (based off the meta) as to surface information needed to help support decisions when making network settings changes or quantify impact of certain protocol changes.

Design principle: reduce coupling between systems by avoiding duplicating complex logic between core and downstream systems (like complex formulas, or subtle protocol behavior).

In particular understanding of:

At the ledger level:

At the transaction level:

MonsieurNicolas commented 4 months ago

@sydneynotthecity tagging you here

MonsieurNicolas commented 4 months ago

Also related to this: it may be worth standardizing (SEPs?) on certain types of diagnostic events so that we can ensure some level of stability over time on structure/semantics so that downstream processors can consume them. Note that in general diagnostic events are likely aggregated/parsed by downstream, we want to be able to provide better/more accurate events over time and not be tied up to specific traces: imagine if we have a diagnostic event that gives information when entering/leaving some "scope" (the stable concept), then the runtime could emit events when the scope is as coarse as a "VM" or as granular as method/host function.

sydneynotthecity commented 4 months ago

➕ Yes, I agree that diagnostic events should be standardized where applicable. Otherwise the code to parse and aggregate events will be brittle and the maintenance burden will be high.