Murat Parlakisik | f95672c | 2016-12-05 00:53:17 -0800 | [diff] [blame] | 1 | -- binary |
| 2 | 06 13 # version, type |
| 3 | 00 68 # length |
| 4 | 12 34 56 78 # xid |
| 5 | 00 01 # multipart message type (OFPMP_FLOW_DESC) -- old name is OFPMP_FLOW for spec 1.3.1, 1.4.0, 1.4.1 |
| 6 | 00 01 # flags |
| 7 | 00 00 00 00 # pad |
| 8 | |
| 9 | 00 58 # length |
| 10 | 00 00 # pad |
| 11 | 01 # table_id |
| 12 | 00 # pad |
| 13 | 00 01 # priority |
| 14 | 00 10 # idle_timeout |
| 15 | 00 60 # hard_timeout |
| 16 | 00 01 # flags (OFPFF_SEND_FLOW_REM) Send flow removed message when flow expires or is deleted |
| 17 | 00 01 # importance |
| 18 | fe dc ba 98 76 54 32 10 # cookie |
| 19 | |
| 20 | 00 01 # match.type |
| 21 | 00 10 # match.length |
| 22 | 80 00 01 08 # match.oxm_list[0].type_len - IN_PORT |
| 23 | 00 00 00 04 # match.oxm_list[0].value |
| 24 | 00 00 00 05 # match.oxm_list[0].mask |
| 25 | 00 00 # match.pad |
| 26 | |
| 27 | |
| 28 | 00 1c # stats.length |
| 29 | 80 02 00 08 # stats.oxs_list[0].type_len - DURATION |
| 30 | 00 00 00 00 00 00 00 04 # stats.oxs_list[0].value |
| 31 | 80 02 02 08 # stats.oxs_list[1].type_len - IDLE_TIME (8002 -> Openflow_basic oxs class and 02 -> 0000 0010 -> oxs_field width 7, oxs_reserved width 1 and 08 is length) |
| 32 | 00 00 00 00 00 00 00 06 # stats.oxs_list[1].value |
| 33 | 00 00 00 00 # stats.pad |
| 34 | |
| 35 | 00 01 # instructions[0].type |
| 36 | 00 08 # instructions[0].length |
| 37 | 04 # instructions[0].table_id |
| 38 | 00 00 00 # pad |
| 39 | |
| 40 | 00 01 # instructions[1].type |
| 41 | 00 08 # instructions[1].length |
| 42 | 07 # instructions[1].table_id |
| 43 | 00 00 00 # pad |
| 44 | |
| 45 | --java |
| 46 | builder |
| 47 | .setXid(0x12345678) |
| 48 | .setFlags(ImmutableSet.<OFStatsReplyFlags>of(OFStatsReplyFlags.REPLY_MORE)) |
| 49 | .setEntries(ImmutableList.<OFFlowStatsEntry>of( |
| 50 | factory.buildFlowStatsEntry().setTableId(TableId.of(1)) |
| 51 | .setPriority(1) |
| 52 | .setIdleTimeout(16) |
| 53 | .setHardTimeout(96) |
| 54 | .setFlags(ImmutableSet.<OFFlowModFlags>of(OFFlowModFlags.SEND_FLOW_REM)) |
| 55 | .setImportance(1) |
| 56 | .setCookie(U64.parseHex("FEDCBA9876543210")) |
| 57 | .setMatch(factory.buildMatch() |
| 58 | .setMasked(MatchField.IN_PORT, OFPort.of(4), OFPort.of(5)) |
| 59 | .build()) |
| 60 | .setStats(factory.buildStatV6() |
| 61 | .setOxsFields(OFOxsList.of(factory.oxss().buildDuration().setValue(U64.of(4)).build(), |
| 62 | factory.oxss().buildIdleTime().setValue(U64.of(6)).build())) |
| 63 | .build()) |
| 64 | .setInstructions(ImmutableList.<OFInstruction>of( |
| 65 | factory.instructions().gotoTable(TableId.of(4)), |
| 66 | factory.instructions().gotoTable(TableId.of(7)))) |
| 67 | .build() )) |
| 68 | .build() |