esnet / esnet/iperf

Get test Data/Results API through callback

Open
#807 0 comments 2 reactions 0 assignees View on GitHub
Dominant language
C
Stars
8.8k
Forks
1.5k
PR merge metrics
No merged PRs in 30d

Description

# Enhancement Request

* Current behaviour : There is no way to get a callback each time a result is printed as as structured data-structure by callback.

* Desired behaviour : Register a callback that would fire each time there is a result:

`void iperf_set_intermediate_result_cb(void* callback);`
`void* iperf_get_intermediate_result();`

Proposed iperf_result_t structure:
Highly based on the JSON structure.
```
typedef struct {
int64_t start; // Milliseconds
int64_t end; // Milliseconds
int64_t milliseconds; // Milliseconds
uint64_t bytes;
double bits_per_second;
double jitter_ms;
uint64_t 5;
uint64_t packets;
double lost_percent;
bool omitted;
} iperf_result_t;
```

and at the end of the test a global result:
`void iperf_set_result_cb(void* callback);`
`void* iperf_get_result_cb();`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.