Skip to content

Commit

Permalink
Add rally hook to neutron devstack plugin
Browse files Browse the repository at this point in the history
This allows us to configure neutron when running the rally job in
the gate. This effort stems from patch [1]. Blame Kevin for not
wanting to squash the two together.

[1] I12aaf6121b677e9696131601b3539a7091e2858c
Change-Id: I006957784ac7900021bcfee57cbc83b5a6c533c4
  • Loading branch information
armando-migliaccio committed Nov 10, 2016
1 parent efe8715 commit f5e30ab
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 0 deletions.
13 changes: 13 additions & 0 deletions TESTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,19 @@ http://docs.openstack.org/developer/tempest/field_guide/scenario.html
Scenario tests, like API tests, are split between the Tempest and Neutron
repositories according to the Neutron API the test is targeting.

Rally Tests
~~~~~~~~~~~

Rally tests (rally-jobs/plugins) use the `rally <http://rally.readthedocs.io/>`_
infrastructure to exercise a neutron deployment. Guidelines for writing a
good rally test can be found in the `rally plugin documentation <http://rally.readthedocs.io/en/latest/plugins.html>`_.
There are also some examples in tree; the process for adding rally plugins to
neutron requires three steps: 1) write a plugin and place it under rally-jobs/plugins/.
This is your rally scenario; 2) (optional) add a setup file under rally-jobs/extra/.
This is any devstack configuration required to make sure your environment can
successfully process your scenario requests; 3) edit neutron-neutron.yaml. This
is your scenario 'contract' or SLA.

Development Process
-------------------

Expand Down
13 changes: 13 additions & 0 deletions devstack/lib/rally
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash

RALLY_EXTRA_DIR="$DEST/neutron/rally-jobs/extra"

# If rally has been configured, .setup files can be sourced to control the
# neutron configuration required to run the scenario plugins.
if [[ "$DEVSTACK_PLUGINS" =~ "rally" ]];
then
for file in $(ls $RALLY_EXTRA_DIR/*.setup);
do
source $file
done
fi
1 change: 1 addition & 0 deletions devstack/plugin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ source $LIBDIR/l2_agent_sriovnicswitch
source $LIBDIR/ml2
source $LIBDIR/qos
source $LIBDIR/ovs
source $LIBDIR/rally
source $LIBDIR/trunk

Q_BUILD_OVS_FROM_GIT=$(trueorfalse False Q_BUILD_OVS_FROM_GIT)
Expand Down
1 change: 1 addition & 0 deletions rally-jobs/extra/trunk_scenario.setup
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
enable_service q-trunk

0 comments on commit f5e30ab

Please sign in to comment.