Rich Lane | c9fc57d | 2013-05-16 16:39:12 -0700 | [diff] [blame] | 1 | -- binary |
| 2 | 04 13 # version, type |
| 3 | 00 80 # length |
| 4 | 12 34 56 78 # xid |
| 5 | 00 06 # stats_type |
| 6 | 00 00 # flags |
| 7 | 00 00 00 00 # pad |
| 8 | 00 48 # entries[0].length |
| 9 | 00 00 # pad |
| 10 | 00 00 00 01 # entries[0].group_id |
| 11 | 00 00 00 08 # entries[0].ref_count |
| 12 | 00 00 00 00 # pad |
| 13 | 00 00 00 00 00 00 00 10 # entries[0].packet_count |
| 14 | 00 00 00 00 00 00 00 20 # entries[0].byte_count |
| 15 | 00 00 00 14 # entries[0].duration_sec |
| 16 | 00 00 00 64 # entries[0].duration_nsec |
| 17 | 00 00 00 00 00 00 00 01 # entries[0].bucket_stats[0].packet_count |
| 18 | 00 00 00 00 00 00 00 02 # entries[0].bucket_stats[0].byte_count |
| 19 | 00 00 00 00 00 00 00 03 # entries[0].bucket_stats[1].packet_count |
| 20 | 00 00 00 00 00 00 00 04 # entries[0].bucket_stats[1].byte_count |
| 21 | 00 28 # entries[0].length |
| 22 | 00 00 # pad |
| 23 | 00 00 00 01 # entries[0].group_id |
| 24 | 00 00 00 08 # entries[0].ref_count |
| 25 | 00 00 00 00 # pad |
| 26 | 00 00 00 00 00 00 00 10 # entries[0].packet_count |
| 27 | 00 00 00 00 00 00 00 20 # entries[0].byte_count |
| 28 | 00 00 00 14 # entries[0].duration_sec |
| 29 | 00 00 00 64 # entries[0].duration_nsec |
| 30 | -- python |
| 31 | ofp.message.group_stats_reply( |
| 32 | xid=0x12345678, |
| 33 | flags=0, |
| 34 | entries=[ |
| 35 | ofp.group_stats_entry( |
| 36 | group_id=1, |
| 37 | ref_count=8, |
| 38 | packet_count=16, |
| 39 | byte_count=32, |
| 40 | duration_sec=20, |
| 41 | duration_nsec=100, |
| 42 | bucket_stats=[ |
| 43 | ofp.bucket_counter(packet_count=1, byte_count=2), |
| 44 | ofp.bucket_counter(packet_count=3, byte_count=4)]), |
| 45 | ofp.group_stats_entry( |
| 46 | group_id=1, |
| 47 | ref_count=8, |
| 48 | packet_count=16, |
| 49 | byte_count=32, |
| 50 | duration_sec=20, |
| 51 | duration_nsec=100, |
| 52 | bucket_stats=[])]) |