4 | | == What is it? == |
| 4 | == How do I configure OML measurement collection via nodehandler? == |
| 5 | OML supports TIME or SAMPLE based measurement collection. Depending on the the method used, either every ''X'' seconds or every ''Y'' samples, one can apply data filters to the measurements. There are two default filters included with the oml client : sum and mean. OML has the ability to apply user-defined filters to the collected data. (Details on how to do that will be posted soon). |
| 6 | The collection and filtering of application generated data is defined in the prototypes used in your experiment. |
| 7 | Let's look at 2 example prototype definitions to see how this works : |
| 8 | |
| 9 | Example I: |
| 10 | |
| 11 | {{{ |
| 12 | 1. otg.addMeasurement('senderport', Filter::TIME, |
| 13 | 2. {Filter::SAMPLE_SIZE => 1}, |
| 14 | 3. [ |
| 15 | 4. ['pkt_seqno'], |
| 16 | 5. ['pkt_size', Filter::SUM] |
| 17 | 6. ] |
| 18 | 7. ) |
| 19 | }}} |
| 20 | |
| 21 | The "Filter" you see here is a nodehandler reference to the OML measurement collection and filtering mechanism. This definition is processed by the nodehandler and based on that it creates an xml file which acts as input to the oml client at runtime. |
| 22 | |
| 23 | * On line 1, we are defining a Time-based filtering scheme on the data being generated by the application. (in this case otg) |
| 24 | * Line 2 sets the trigger for this collection in seconds. So 0.5 would indicate 0.5 seconds and so on. In the above example the oml client will collect measurements coming from the application and will process them every 1 seconds. |
| 25 | * On line 5 we instruct the oml client through nodehandler to apply the SUM filter on the "pkt_size" data. |
| 26 | |
| 27 | To summarize, every one second the oml-client would send the following filtered values to the collection server : |
| 28 | * The first seq_no collected in this time period (since no summarizing filter was applied only the first value is sent) |
| 29 | * The sum of all pkt_size metrics collected during this timer period. |
| 30 | |
| 31 | |
| 32 | Example II : |
| 33 | {{{ |
| 34 | 1. otg.addMeasurement('senderport', Filter::SAMPLE, |
| 35 | 2. {Filter::SAMPLE_SIZE => 20}, |
| 36 | 3. [ |
| 37 | 4. ['pkt_seqno'], |
| 38 | 5. ['pkt_size', Filter::MEAN] |
| 39 | 6. ] |
| 40 | 7. ) |
| 41 | }}} |
| 42 | |
| 43 | In example II, the trigger for applying the filtering is 20 samples collected from the application. So every 20 samples later a summary will be sent to collection server with pkt_seqno and mean of the 20 pkt_sizes collected. |
| 44 | [[BR]] |
| 45 | |
| 46 | Take a look at some example prototype definitions here : |
| 47 | http://www.orbit-lab.org/userdoc/wiki/OTG/ScriptsRepository |