logging.basicConfig(format=FORMAT)
    log = logging.getLogger()
    log.setLevel(logging.DEBUG)

    """
    *********************
    Wishful ShowCase 3
    Experiment Controller
    *********************
    We can use this in alternately of bash script or OML/OMF architecture
    """

    log.warning('*********** WISHFUL SC3 *************')
    log.warning('*********** starting Experiment Controller **********************')

    mytestbed = TestbedTopology("SC3",log)
    mytestbed.initializeTestbedTopology()       # discovery and allocate nodes
    mytestbed.initializeTestbedFunctions()      # set nodes rule: create network and association

    register_traffic(1, '0')
    register_traffic(2, '0')
    register_traffic(3, '0')

    """
    Managed traffic
    """
    log.warning('*********** START TRAFFIC **********************')

    serverApp0 = start_iperf_server_application(mytestbed.ap1, log, mytestbed)
    log.warn('IERF server started')
コード例 #2
0
    Init WiSHFUL framework
    """
    FORMAT = '> %(asctime)-15s %(message)s'    #FORMAT = "[%(asctime)-15s - %(filename)s:%(lineno)s - %(funcName)20s() ] %(message)s"
    logging.basicConfig(format=FORMAT)
    log = logging.getLogger()
    log.setLevel(logging.DEBUG)

    log.warning('*********** WISHFUL SC3 *************')
    log.warning('*********** starting global WiSHFUL controller **********************')

    """
    *********************
    Start framework and get information from Experiment Controller
    *********************
    """
    mytestbed = TestbedTopology("SC3",log)
    mytestbed.initializeTestbedTopology()       # discovery and allocate nodes

    """
    *********************
    Wishful Controller
    *********************
    We implement here the controller logic to get measuerements and set node capabilities
    """

    """
    Start WiSHFUL controller measurement collector
    """
    meas_collector = MeasurementCollector(mytestbed, log)
    nodes_NIC_info = []
    for node in mytestbed.nodes: