minors
authorHanoh Haim <[email protected]>
Wed, 9 Mar 2016 13:43:59 +0000 (15:43 +0200)
committerHanoh Haim <[email protected]>
Wed, 9 Mar 2016 13:43:59 +0000 (15:43 +0200)
draft_trex_stateless.asciidoc

index 15fa713..0a6f7d3 100644 (file)
@@ -1953,9 +1953,11 @@ In some cases there is a need to split the streams to thread in a way that speci
 In the above figure we would like to that stream S3 will start on all the thread after S2 was finished by all the threads 
 
 
-==== Tutorial: Pcap file to *one* stream 
+==== Tutorial: Pcap file to one stream 
 
-There is a way to load *one* packet data into a stream. There is an assumption  that this pcap. only the first packet from this pcap is taken.
+*Goal*:: Load stream template packet from pcap file instaed of scapy.
+
+There is an assumption that this pcap has one packet. In case it has more only the first packet is loaded.
 
 *file*:: link:{github_stl_path}/udp_1pkt_pcap.py[stl/udp_1pkt_pcap.py]
 
@@ -1985,9 +1987,9 @@ There is a way to load *one* packet data into a stream. There is an assumption
 ----
 <1> packet is taken from pcap file relative to *profile* file location
 
-==== Tutorial: Pcap file to many streams 
+==== Tutorial: Pcap file conversion to many streams
 
-The following example demonstrates a way to load pcap with *number* of packets and for each packet create a stream with burst of 1. 
+*Goal*:: Demonstrates a way to load pcap with *number* of packets and for each packet create a stream with burst of 1. the ISG for each stream is the inter packet gap (IPG) 
 
 *file*:: link:{github_stl_path}/pcap.py[pcap.py]
 
@@ -2003,16 +2005,15 @@ The following example demonstrates a way to load pcap with *number* of packets a
 ----
 <1> The inter stream gap in usec
 <2> How many times to loop
-<3> the pcap file 
-
+<3> The input pcap file 
 
 image::images/stl_tut_pcap_file1.png[title="pcap file",align="left",width=300, link="images/stl_tut_pcap_file1.png"]
 
-This figure illustrates how the streams look like for pcap file with 3 packet.
+This figure illustrates how the streams look like for pcap file with 3 packets.
 * Each stream is configured to burst with one packet 
 * Each stream point to the next stream. 
 * The last stream point to the first with action_loop=loop_count in case it was asked (>1)
-The profile will run on only one DP thread because it has burst with one packet (see Split example)
+The profile will run on one DP thread because it has burst with one packet (Split can work in this case)
 
 Running this example
 
@@ -2122,11 +2123,10 @@ $./stl-sim -f stl/pcap.py --yaml
       instructions: []
       split_by_var: ''
 ----
-<1> each stream point to the next stream
-<2> last point to the first 
-<3> the number of loop is given in `action_count: 1`
-<4> self_start is disabled for all the streams except the first one
-
+<1> Each stream point to the next stream
+<2> Last point to the first 
+<3> The number of loop is given in `action_count: 1`
+<4> Self_start is disabled for all the streams except the first one
 
 ==== Tutorial: Pcap file to many streams and Field Engine 
 
@@ -2246,7 +2246,7 @@ The following example demonstrates creating IPv6 packet inside IPv4 packet and c
 
 ==== Tutorial: Mask instruction 
 
-The STLVmWrMaskFlowVar is a handy command. The pseudocode is a folow 
+The STLVmWrMaskFlowVar is a handy instruction. The pseudocode is as follows:
 
 .Pseudocode 
 [source,bash]
@@ -2268,7 +2268,7 @@ The STLVmWrMaskFlowVar is a handy command. The pseudocode is a folow
 ----
 
 
-===== Example 1
+*Example 1*::
 
 [source,python]
 ----
@@ -2287,7 +2287,7 @@ The STLVmWrMaskFlowVar is a handy command. The pseudocode is a folow
 
 This will cast stream variable with 2 byte to be 1 byte 
 
-===== Example 2
+*Example 2*::
 
 [source,python]
 ----
@@ -2316,7 +2316,7 @@ The output will be shift by 8
  0x0300 
 |=================
 
-===== Example 3
+*Example 3*::
 
 [source,python]
 ----
@@ -2350,11 +2350,9 @@ value
  0x01 
 |=================
 
-
 ==== Tutorial: Advance traffic profile - platform  [TODO]
 
-
-===== Direction
+*Direction*::
 
 To make the traffic profile more usable, the traffic profile support per direction/interface. 
 
@@ -2391,7 +2389,7 @@ interfaces 1/3 is direction 1
  
 So rate will be changed accordingly. 
 
-===== Per Interface
+*Per Interface*::
  
 In this case there is a different  profile base on interface ID 
  
@@ -2453,7 +2451,7 @@ def create_streams (self, direction = 0, **args):
 The Console will give the port/direction and will get the right stream in each interface
  
 
-===== Tunable
+*Tunable*::
  
 [source,python]
 ----
@@ -2523,13 +2521,12 @@ class STLS1(object):
 
 
 
-=== Tutorials HLT profile 
+==== Tutorial: HLT traffic profile 
 
-HLTAPI is a Cisco standard API for traffic generation.IXIA and Spirent support this standard.  traffic_config API has set of arguments  for specifying  the packet, how to send it and what field to change while sending it. 
-We created a Python module that you can specify the traffic profile in HLT like format and load it as native profile for smooth transition .
+traffic_config API has set of arguments for specifying stream. In particular the packet template and which field and how to send it.
+It is possible to define a  traffic profile using HTTAPI arguments .
 Under the hood there is a compiler that converts it to native scapy/field engine instruction
-The support is limited to [TBD] this argument.
-
+The support is limited, see  xref:altapi-support[here].
 
 *file*:: link:{github_stl_path}/hlt/hlt_udp_inc_dec_len_9k.py[stl/hlt/hlt_udp_inc_dec_len_9k.py]
 
@@ -2642,8 +2639,6 @@ def register():
 ----    
 
 
-
-
 to run it using using the TRex Console 
 
 [source,bash]
@@ -2651,7 +2646,6 @@ to run it using using the TRex Console
 TRex>start -f stl/hlt/hlt_udp_inc_dec_len_9k.py -m 10mbps -a     
 ----
 
-
 more profiles and example can be found in `stl/hlt` folder 
 
 
@@ -2698,7 +2692,7 @@ Some guidelines:
                                            |   WORK (pause) -> PAUSE (resume )---
                                            |                                     | 
                                            |                                     |
-                                        ------------------------------------                                    
+                                           --------------------------------------                                    
 
 -----
 
@@ -3040,7 +3034,7 @@ get keyboard
 === Appendix
 
 
-==== HLT supported Arguments 
+==== HLT supported Arguments anchor:altapi-support[]
 
 
 [source,python]