Skip to content

Add round number to verdicts #5281

@rautenrieth-da

Description

@rautenrieth-da

We want to associate verdicts and/or traffic summaries with rounds. Among others, this would allow the /v0/events endpoint to include the round even if there is no featured app party involved. Right now, the round is only included in the app_activity_records field which is null if there is no activity record.

See also the following comment from a user:

Hi Team, I start seeing the traffic_summary and app_activity_records on the mainnet. Here are two samples (the envelops details are omitted for simplicity).
sample 1
"traffic_summary": {
"total_traffic_cost": 7858,
..
},
"app_activity_records": null
},sample 2
"traffic_summary": {
"total_traffic_cost": 3200,
..
},
"app_activity_records": {
"round_number": 92814,
"records": [
{
"party": "raven-validator-1::1220e45c6287ebe1d4cf3ffd6dd50bbe50da74e71ddfdaf256979d615ed679991350",
"weight": 3200
}
]
}
}
I guess in the sample 1 there are no featured parties confirming this txn and therefore it is empty, while in the sample 2 the only featured party got all the 3200 bytes.

My understanding is that the round is recorded for the rewarding, and that's why it's in the app_activity_records. Is there a way to record the round number in the sample 1 case? That is I know in which round this txn is recorded though there are not featured parties confirming it?

The idea behind is I wish to calculate the total traffic for a given round. Ideally it is also reported in the traffic_summary or somewhere. Thanks.

TODO:

  • Add a round_number column to scan_verdict_store, and populate it when ingesting verdicts.
  • Change /v0/events and /v0/events/{event_id} to include the round number even if there are no activity records

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions