From: Ondrej Lichtner olichtne@redhat.com
What follows is a big patch set that is the result of my work to port the phase3/ovs_dpdk_pvp recipe to python. The recipe should be ported in almost complete support of everything that the old recipe did (except for result evaluation) and includes a significant refactoring of the code.
Instead of working with a hackish ssh tunnel to manipulate the guest the patch set also introduces a new feature allowing the tester to connect to a LNST Slave during test execution. This significantly improves working with the guest since we can now safely wrap the testpmd process into a test module and have a comfortable interface for it. This removes the python paramiko library dependency of the recipe.
Another significant improvement is a better way to wrap the TRex generator into test modules that avoids the use of a tmux session we've used previously this means that the recipe no longer has this dependency.
Finally the patchset also includes a new feature of being able to synchronize and use arbitrary classes in the lnst.RecipeCommon package into any slave. This gives the tester a very nice interface to use for extending the slave functionality. In the OvS_DPDK_PvP recipe this is used to interface with libvirt on the slave machine. This means that the controller can now run on any machine and be able to work with libvirt on any other slave instead of the confusing forced binding we've had before.
On top of these new features, the patch set also includes other smaller features, a lot of bug fixes and refactoring of some classes.
-Ondrej
Ondrej Lichtner (40): lnst.Common.DeviceError: define the DeviceReadOnly exception lnst.Devices.RemoteDevice: add caching capability lnst.Slave.NetTestSlave: refactor names of dev_*attr methods lnst.Device.Device: improve cleanup data storage lnst.Device.Device: raise DeviceDeleted exception on netlink updates lnst.Device.Device: add bus_info property lnst.Slave.Job: catch all exceptions from Test Modules lnst.Slave.Job: cleanup kill only running jobs move lnst.Common.TestModule to lnst.Tests.BaseTestModule, add wait_for_interrupt lnst.Common.Parameters: allow deletions for the Parameters class lnst.Controller.MachineMapper: sort interfaces in machine descriptions lnst.Controller.Machine: add mapped boolean lnst.Controller.MessageDispatcher: refactor wait_* methods lnst.Controller.Machine: expose init_connection as public method lnst.Controller.SlavePoolManager: enable machines without interfaces lnst.Controller.Machine: split set_recipe into prepare_machine and start_recipe lnst.Controller.Machine: move VirtualDevice cleanup to Controller lnst.Controller.Machine: refactor sending classes to Slaves lnst.Slave.NetTestSlave: track dynamic classes by module name as well lnst.Slave.NetTestSlave: create the dynamic RecipeCommon module lnst.Slave.NetTestSlave: support objects from dynamically received classes add lnst.Controller.SlaveObject add lnst.Controller.RecipeControl lnst.Controller.Host: expose the map_device api to the tester lnst.Controller.Requirements: add RecipeParam class lnst.Controller.RunSummaryFormatter: change format for list items lnst.Controller.Machine: small refactoring lnst.Slave.InterfaceManager: fix deleted device handling lnst.RecipeCommon.PerfResult: fix standard deviation calculation lnst.RecipeCommon.PerfResult: override std_deviation of PerfInterval and add string descrition lnst.RecipeCommon.Ping: add parameters to PingConf lnst.RecipeCommon.Perf: minor refactoring setup.py: use setuptools instead of distutils and improve package management add lnst.RecipeCommon.LibvirtControl add lnst.Tests.TRex add lnst.Tests.TestPMD add lnst.RecipeCommon.TRexMeasurementTool add lnst.Recipes.ENRT.OvS_DPDK_PvP lnst.Recipes.ENRT.BaseEnrtRecipe: fix indentation lnst.Slave.InterfaceManager: disable bulk mode after device creation
lnst/Common/DeviceError.py | 3 + lnst/Common/Parameters.py | 3 + lnst/Controller/Controller.py | 41 +- lnst/Controller/Host.py | 8 +- lnst/Controller/Job.py | 2 +- lnst/Controller/Machine.py | 159 +++---- lnst/Controller/MachineMapper.py | 2 +- lnst/Controller/MessageDispatcher.py | 116 +++-- lnst/Controller/Recipe.py | 13 +- lnst/Controller/RecipeControl.py | 64 +++ lnst/Controller/Requirements.py | 47 ++- lnst/Controller/RunSummaryFormatter.py | 14 +- lnst/Controller/SlaveObject.py | 41 ++ lnst/Controller/SlavePoolManager.py | 7 +- lnst/Controller/__init__.py | 2 +- lnst/Devices/Device.py | 48 ++- lnst/Devices/RemoteDevice.py | 36 +- lnst/RecipeCommon/LibvirtControl.py | 41 ++ lnst/RecipeCommon/Perf.py | 90 ++-- lnst/RecipeCommon/PerfResult.py | 10 +- lnst/RecipeCommon/Ping.py | 35 +- lnst/RecipeCommon/TRexMeasurementTool.py | 87 ++++ lnst/Recipes/ENRT/BaseEnrtRecipe.py | 14 +- lnst/Recipes/ENRT/OvS_DPDK_PvP.py | 399 ++++++++++++++++++ lnst/Slave/InterfaceManager.py | 14 +- lnst/Slave/Job.py | 6 +- lnst/Slave/NetTestSlave.py | 81 +++- .../TestModule.py => Tests/BaseTestModule.py} | 20 + lnst/Tests/Iperf.py | 2 +- lnst/Tests/Netperf.py | 3 +- lnst/Tests/Ping.py | 2 +- lnst/Tests/TRex.py | 159 +++++++ lnst/Tests/TestPMD.py | 47 +++ setup.py | 6 +- 34 files changed, 1356 insertions(+), 266 deletions(-) create mode 100644 lnst/Controller/RecipeControl.py create mode 100644 lnst/Controller/SlaveObject.py create mode 100644 lnst/RecipeCommon/LibvirtControl.py create mode 100644 lnst/RecipeCommon/TRexMeasurementTool.py create mode 100644 lnst/Recipes/ENRT/OvS_DPDK_PvP.py rename lnst/{Common/TestModule.py => Tests/BaseTestModule.py} (85%) create mode 100644 lnst/Tests/TRex.py create mode 100644 lnst/Tests/TestPMD.py