Fix Neutron plugin XTRACE handling

The various Neutron plugin files need to have unique variables for the
xtrace state as they are sometimes nested more than two levels deep
and MY_XTRACE is getting stomped.  This gives each of the neutron_plugin
and neutron_thirdparty include files a unique XTRACE state variable.

I don't think this is a problem with any of the other plugin include
files (yet) so this just handles Neutron for now.

Change-Id: I7c272a48e7974edecaff5f431ff7443dd6622588
This commit is contained in:
Dean Troyer 2014-03-28 12:40:56 -05:00
parent 4c0e728780
commit e3a9160c0d
26 changed files with 52 additions and 52 deletions

View File

@ -2,7 +2,7 @@
# ------------------------------------ # ------------------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) BS_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -74,4 +74,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $BS_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) CISCO_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
# Scecify the VSM parameters # Scecify the VSM parameters
@ -324,4 +324,4 @@ function neutron_plugin_setup_interface_driver {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $CISCO_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) EMBR_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/openvswitch source $TOP_DIR/lib/neutron_plugins/openvswitch
@ -37,4 +37,4 @@ function neutron_plugin_configure_service {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $EMBR_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) IBM_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -130,4 +130,4 @@ function neutron_ovs_base_cleanup {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $IBM_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) LBRIDGE_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/linuxbridge_agent source $TOP_DIR/lib/neutron_plugins/linuxbridge_agent
@ -53,4 +53,4 @@ function has_neutron_plugin_security_group {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $LBRIDGE_XTRACE

View File

@ -6,7 +6,7 @@ MIDONET_API_PORT=${MIDONET_API_PORT:-8080}
MIDONET_API_URL=${MIDONET_API_URL:-http://localhost:$MIDONET_API_PORT/midonet-api} MIDONET_API_URL=${MIDONET_API_URL:-http://localhost:$MIDONET_API_PORT/midonet-api}
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) MN_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
function is_neutron_ovs_base_plugin { function is_neutron_ovs_base_plugin {
@ -84,4 +84,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $MN_XTRACE

View File

@ -2,7 +2,7 @@
# ------------------------------ # ------------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) ML2_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
# Enable this to simply and quickly enable tunneling with ML2. # Enable this to simply and quickly enable tunneling with ML2.
@ -119,4 +119,4 @@ function has_neutron_plugin_security_group {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $ML2_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) NEC_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
# Configuration parameters # Configuration parameters
@ -127,4 +127,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $NEC_XTRACE

View File

@ -2,7 +2,7 @@
# ---------------------- # ----------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) NU_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
function neutron_plugin_create_nova_conf { function neutron_plugin_create_nova_conf {
@ -66,4 +66,4 @@ function has_neutron_plugin_security_group {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $NU_XTRACE

View File

@ -2,7 +2,7 @@
# ---------------------- # ----------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) OFA_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -91,4 +91,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $OFA_XTRACE

View File

@ -1,7 +1,7 @@
# Neutron One Convergence plugin # Neutron One Convergence plugin
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) OC_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -73,4 +73,4 @@ function neutron_plugin_create_nova_conf {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $OC_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) OVS_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/openvswitch_agent source $TOP_DIR/lib/neutron_plugins/openvswitch_agent
@ -57,4 +57,4 @@ function has_neutron_plugin_security_group {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $OVS_XTRACE

View File

@ -2,7 +2,7 @@
# ----------------------------- # -----------------------------
# Save trace setting # Save trace setting
PLUGIN_XTRACE=$(set +o | grep xtrace) OVSA_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -128,4 +128,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$PLUGIN_XTRACE $OVSA_XTRACE

View File

@ -2,7 +2,7 @@
# ------------------------------------- # -------------------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) OVSB_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
OVS_BRIDGE=${OVS_BRIDGE:-br-int} OVS_BRIDGE=${OVS_BRIDGE:-br-int}
@ -77,4 +77,4 @@ function _neutron_ovs_base_configure_nova_vif_driver {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $OVSB_XTRACE

View File

@ -3,7 +3,7 @@
# ------------------------------------ # ------------------------------------
# Save trace settings # Save trace settings
MY_XTRACE=$(set +o | grep xtrace) PG_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
function neutron_plugin_create_nova_conf { function neutron_plugin_create_nova_conf {
@ -52,4 +52,4 @@ function neutron_plugin_check_adv_test_requirements {
is_service_enabled q-agt && is_service_enabled q-dhcp && return 0 is_service_enabled q-agt && is_service_enabled q-dhcp && return 0
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $PG_XTRACE

View File

@ -2,7 +2,7 @@
# ------------------ # ------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) RYU_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -77,4 +77,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $RYU_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) FW_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
FWAAS_PLUGIN=neutron.services.firewall.fwaas_plugin.FirewallPlugin FWAAS_PLUGIN=neutron.services.firewall.fwaas_plugin.FirewallPlugin
@ -24,4 +24,4 @@ function neutron_fwaas_stop {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $FW_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) LB_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
@ -48,4 +48,4 @@ function neutron_lbaas_stop {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $LB_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) METER_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
@ -27,4 +27,4 @@ function neutron_metering_stop {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $METER_XTRACE

View File

@ -2,7 +2,7 @@
# --------------------------- # ---------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) VPN_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
@ -30,4 +30,4 @@ function neutron_vpn_stop {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $VPN_XTRACE

View File

@ -2,7 +2,7 @@
# ------------------------- # -------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) NSX_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
source $TOP_DIR/lib/neutron_plugins/ovs_base source $TOP_DIR/lib/neutron_plugins/ovs_base
@ -146,4 +146,4 @@ function neutron_plugin_check_adv_test_requirements {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $NSX_XTRACE

View File

@ -2,7 +2,7 @@
# ------------------------------------------ # ------------------------------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) BS3_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
BS_FL_CONTROLLERS_PORT=${BS_FL_CONTROLLERS_PORT:-localhost:80} BS_FL_CONTROLLERS_PORT=${BS_FL_CONTROLLERS_PORT:-localhost:80}
@ -49,4 +49,4 @@ function check_bigswitch_floodlight {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $BS3_XTRACE

View File

@ -17,7 +17,7 @@ MIDONET_CLIENT_BRANCH=${MIDONET_CLIENT_BRANCH:-master}
MIDONET_CLIENT_DIR=${MIDONET_CLIENT_DIR:-$MIDONET_DIR/python-midonetclient} MIDONET_CLIENT_DIR=${MIDONET_CLIENT_DIR:-$MIDONET_DIR/python-midonetclient}
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) MN3_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
function configure_midonet { function configure_midonet {
@ -46,4 +46,4 @@ function check_midonet {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $MN3_XTRACE

View File

@ -2,7 +2,7 @@
# ----------------------- # -----------------------
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) RYU3_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
@ -75,4 +75,4 @@ function check_ryu {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $RYU3_XTRACE

View File

@ -13,7 +13,7 @@ TREMA_APPS_REPO=${TREMA_APPS_REPO:-https://github.com/trema/apps.git}
TREMA_APPS_BRANCH=${TREMA_APPS_BRANCH:-master} TREMA_APPS_BRANCH=${TREMA_APPS_BRANCH:-master}
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) TREMA3_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
TREMA_DIR=${TREMA_DIR:-$DEST/trema} TREMA_DIR=${TREMA_DIR:-$DEST/trema}
@ -114,4 +114,4 @@ function check_trema {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $TREMA3_XTRACE

View File

@ -11,7 +11,7 @@
# * NSX_GATEWAY_NETWORK_CIDR --> CIDR to configure br-ex, e.g. 172.24.4.211/24 # * NSX_GATEWAY_NETWORK_CIDR --> CIDR to configure br-ex, e.g. 172.24.4.211/24
# Save trace setting # Save trace setting
MY_XTRACE=$(set +o | grep xtrace) NSX3_XTRACE=$(set +o | grep xtrace)
set +o xtrace set +o xtrace
# This is the interface that connects the Devstack instance # This is the interface that connects the Devstack instance
@ -83,4 +83,4 @@ function check_vmware_nsx {
} }
# Restore xtrace # Restore xtrace
$MY_XTRACE $NSX3_XTRACE