Add clarifying comments to SamplePerformanceService (#30296)

* Add clarifying comment

* Make jsonrpc docs more explicit
This commit is contained in:
Tyera 2023-02-15 10:02:53 -07:00 committed by GitHub
parent beb3cd5ed9
commit a020f3eb60
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 4 deletions

View File

@ -66,6 +66,10 @@ impl SamplePerformanceService {
snapshot = new_snapshot;
let perf_sample = PerfSampleV2 {
// Note: since num_slots is computed from the highest slot and not the bank
// slot, this value should not be used in conjunction with num_transactions or
// num_non_vote_transactions to draw any conclusions about number of
// transactions per slot.
num_slots,
num_transactions,
num_non_vote_transactions,

View File

@ -31,11 +31,11 @@ number of samples to return (maximum 720)
An array of `RpcPerfSample<object>` with the following fields:
- `slot: <u64>` - Slot in which sample was taken at
- `numTransactions: <u64>` - Number of transactions in sample
- `numSlots: <u64>` - Number of slots in sample
- `numTransactions: <u64>` - Number of transactions processed during the sample period
- `numSlots: <u64>` - Number of slots completed during the sample period
- `samplePeriodSecs: <u16>` - Number of seconds in a sample window
- `numNonVoteTransaction: <u64>` - Number of non-vote transactions in
sample.
- `numNonVoteTransaction: <u64>` - Number of non-vote transactions processed during the
sample period.
:::info
`numNonVoteTransaction` is present starting with v1.15.