X-Git-Url: http://git.onelab.eu/?p=distributedratelimiting.git;a=blobdiff_plain;f=drl%2Fcommon_accounting.h;h=fc8e75e52aeb416be149353922f87b85aa7a9733;hp=d656d8aa59598fd724ece4d20dd04e595e2e07d0;hb=9891ed21bcd3ff9f72a92e867ac7e8e0b9abb533;hpb=0be9704d6b24d09ebd55beedec52758cb88c570b diff --git a/drl/common_accounting.h b/drl/common_accounting.h index d656d8a..fc8e75e 100644 --- a/drl/common_accounting.h +++ b/drl/common_accounting.h @@ -74,6 +74,29 @@ typedef struct { /** The number of bytes sent since the last_update time. */ uint32_t bytes_since; + /* Statistics below. */ + + /** The current number of flows. */ + uint32_t num_flows; + + /** The number of flows sending above 5KB/s. */ + uint32_t num_flows_5k; + + /** The number of flows sending above 10KB/s. */ + uint32_t num_flows_10k; + + /** The number of flows sending above 20KB/s. */ + uint32_t num_flows_20k; + + /** The number of flows sending above 50KB/s. */ + uint32_t num_flows_50k; + + /** The average flow rate. */ + uint32_t avg_rate; + + /** The hash of the flow whose rate is the max_flow_rate. */ + uint32_t max_flow_rate_flow_hash; + } common_accounting_t; /** Determines the difference between two timeval structs (in seconds, with