defApplication('iperf') do |app|
	        app.path = "/usr/bin/oml2-iperf"
	        app.version(2,0,5)
	        app.shortDescription = "Iperf traffic generator and bandwidth measurement tool"
	        app.description = %{
	Iperf is a traffic generator and bandwidth measurement tool. It provides
	generators producing various forms of packet streams and port for sending
	these packets via various transports, such as TCP and UDP.
	        }
	       
	        app.defProperty('interval', 'pause n seconds between periodic bandwidth reports',
	                        'i', {:type => :integer, :dynamic => false})
	    app.defProperty('len', 'set length read/write buffer to n (default KB)',
	                'l', {:type => :string, :dynamic => false})
	    app.defProperty('print_mss', 'print TCP maximum segment size (MTU - TCP/IP header)',
	                        'm', {:type => :boolean, :dynamic => false})
	    app.defProperty('output', 'output the report or error message to this specified file',
	                        'o', {:type => :string, :dynamic => false})
	    app.defProperty('port', 'set server port to listen on/connect to to n (default)',
	                        'p', {:type => :integer, :dynamic => false})
	    app.defProperty('udp', 'use UDP rather than TCP',
	                        'u', {:order => 2, :type => :boolean, :dynamic => false})
	    app.defProperty('window', 'TCP window size (socket buffer size)',
	                        'w', {:type => :integer, :dynamic => false})
	    app.defProperty('bind', 'bind to <host>, an interface or multicast address',
	                        'B', {:type => :string, :dynamic => false})
	    app.defProperty('compatibility', 'for use with older versions does not sent extra msgs',
	                       'C', {:type => :boolean, :dynamic => false})
	    app.defProperty('mss', 'set TCP maximum segment size (MTU - bytes)',
	                        'M', {:type => :integer, :dynamic => false})
	    app.defProperty('nodelay', 'set TCP no delay, disabling Nagle\'s Algorithm',
	                'N', {:type => :boolean, :dynamic => false})
	    app.defProperty('IPvVersion', 'set the domain to IPv',
	                'V', {:type => :boolean, :dynamic => false})
	    app.defProperty('reportexclude', '[CDMSV]   exclude C(connection) D(data) M(multicast) S(settings) V(server) reports',
	                        'x', {:type => :string, :dynamic => false})
	    app.defProperty('reportstyle', 'C or c for CSV report, O or o for OML',
	                'y', {:type => :string, :dynamic => false})
	       
	    app.defProperty('server', 'run in server mode',
	                        's', {:type => :boolean, :dynamic => false})
	       
	    app.defProperty('bandwidth', 'set target bandwidth to n bits/sec (default Mbit/sec)',
	                        'b', {:type => :string, :dynamic => false})
	    app.defProperty('client', 'run in client mode, connecting to <host>',
	                        'c', {:order => 1, :type => :string, :dynamic => false})
	    app.defProperty('dualtest', 'do a bidirectional test simultaneously',
	                       'd', {:type => :boolean, :dynamic => false})
	    app.defProperty('num', 'number of bytes to transmit (instead of -t)', 
	                        'n', {:type => :integer, :dynamic => false})
	    app.defProperty('tradeoff', 'do a bidirectional test individually',
	                        'r', {:type => :boolean, :dynamic => false})
	    app.defProperty('time', 'time in seconds to transmit for (default secs)',
	                        't', {:type => :integer, :dynamic => false})
	    app.defProperty('fileinput', 'input the data to be transmitted from a file',
	                        'F', {:type => :string, :dynamic => false})
	    app.defProperty('stdin', 'input the data to be transmitted from stdin',
	                       'I', {:type => :boolean, :dynamic => false})
	    app.defProperty('listenport', 'port to recieve bidirectional tests back on',
	                        'L', {:type => :integer, :dynamic => false})
	    app.defProperty('parallel', 'number of parallel client threads to run',
	                        'P', {:type => :integer, :dynamic => false})
	    app.defProperty('ttl', 'time-to-live, for multicast (default)',
	                        'T', {:type => :integer, :dynamic => false})
	    app.defProperty('linux-congestion', 'set TCP congestion control algorithm (Linux only)',
	                        'Z', {:type => :boolean, :dynamic => false})
	                                       
	    app.defMeasurement("application"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('version', :string, 'Iperf version')
	            m.defMetric('cmdline', :string, 'Iperf invocation command line')
	            m.defMetric('starttime_s', :long, 'Time the application was received (s)')
	            m.defMetric('starttime_us', :long, 'Time the application was received (us)')
	          }
	       
	    app.defMeasurement("settings"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('server_mode', :long, ' if in server mode, otherwise')
	            m.defMetric('bind_address', :string, 'Address to bind')
	            m.defMetric('multicast', :long, ' if listening to a Multicast group')
	            m.defMetric('multicast_ttl', :long, 'Multicast TTL if relevant')
	            m.defMetric('transport_protocol', :long, 'Transport protocol (IANA number)')
	            m.defMetric('window_size', :long, 'TCP window size')
	            m.defMetric('buffer_size', :long, 'UDP buffer size')
	          }
	       
	    app.defMeasurement("connection"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('connection_id', :long, 'Connection identifier (socket)')
	            m.defMetric('local_address', :string, 'Local network address')
	            m.defMetric('local_port', :long, 'Local port')
	            m.defMetric('foreign_address', :string, 'Remote network address')
	            m.defMetric('foreign_port', :long, 'Remote port')
	          }
	       
	    app.defMeasurement("transfer"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('connection_id', :long, 'Connection identifier (socket)')
	            m.defMetric('begin_interval', :float, 'Start of the averaging interval (Iperf timestamp)')
	            m.defMetric('end_interval', :float, 'End of the averaging interval (Iperf timestamp)')
	            m.defMetric('size', :long, 'Amount of transmitted data [Bytes]')
	          }
	       
	    app.defMeasurement("losses"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('connection_id', :long, 'Connection identifier (socket)')
	            m.defMetric('begin_interval', :float, 'Start of the averaging interval (Iperf timestamp)')
	            m.defMetric('end_interval', :float, 'End of the averaging interval (Iperf timestamp)')
	            m.defMetric('total_datagrams', :long, 'Total number of datagrams')
	            m.defMetric('lost_datagrams', :long, 'Number of lost datagrams')
	          }
	       
	    app.defMeasurement("jitter"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('connection_id', :long, 'Connection identifier (socket)')
	            m.defMetric('begin_interval', :float, 'Start of the averaging interval (Iperf timestamp)')
	            m.defMetric('end_interval', :float, 'End of the averaging interval (Iperf timestamp)')
	            m.defMetric('jitter', :float, 'Average jitter [ms]')
	          }
	       
	    app.defMeasurement("packets"){ |m|
	            m.defMetric('pid', :long, 'Main process identifier')
	            m.defMetric('connection_id', :long, 'Connection identifier (socket)')
	            m.defMetric('packet_id', :long, 'Packet sequence number for datagram-oriented protocols')
	            m.defMetric('packet_size', :long, 'Packet size')
	            m.defMetric('packet_time_s', :long, 'Time the packet was processed (s)')
	            m.defMetric('packet_time_us', :long, 'Time the packet was processed (us)')
	            m.defMetric('packet_sent_time_s', :long, 'Time the packet was sent (s) for datagram-oriented protocols')
	            m.defMetric('packet_sent_time_us', :long, 'Time the packet was sent (us) for datagram-oriented protocols')
	          }
            app.defMeasurement("TCP_Info"){ |m|
                    m.defMetric('ID', :long)
                    m.defMetric('Begin_interval', :float)
                    m.defMetric('End_interval', :float)
                    m.defMetric('Transfer', :float)
                    m.defMetric('Bandwidth', :float)
                  }

	       
	    app.defMeasurement("UDP_Rich_Info"){ |m|
	            m.defMetric('ID', :long)
	            m.defMetric('Begin_interval', :float)
	            m.defMetric('End_interval', :float)
	            m.defMetric('Transfer', :float)
	            m.defMetric('Bandwidth', :float)
	            m.defMetric('Jitter', :float)
	            m.defMetric('Packet_Lost', :long)
	            m.defMetric('Total_Packet', :long)
	            m.defMetric('PLR', :float)
	          }
	       
	end
