laforge has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-bsc/+/18767 )

Change subject: vty: add 'mscpool roundrobin next' for ttcn3 tests
......................................................................

vty: add 'mscpool roundrobin next' for ttcn3 tests

In the ttcn3 tests, the MSC round robin algorithm is affected by what tests ran
before, so an osmo-bsc test needs this to reset the round robin to get
predictable behavior to test against.

Change-Id: I2155d906505a26744966f442ffb1e87a6a9b494c
---
M src/osmo-bsc/osmo_bsc_vty.c
1 file changed, 13 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  daniel: Looks good to me, approved
  pespin: Looks good to me, but someone else must approve



diff --git a/src/osmo-bsc/osmo_bsc_vty.c b/src/osmo-bsc/osmo_bsc_vty.c
index 5c624dd..a1cfe4f 100644
--- a/src/osmo-bsc/osmo_bsc_vty.c
+++ b/src/osmo-bsc/osmo_bsc_vty.c
@@ -938,6 +938,18 @@
        return CMD_SUCCESS;
 }

+DEFUN(mscpool_roundrobin_next, mscpool_roundrobin_next_cmd,
+      "mscpool roundrobin next " MSC_NR_RANGE,
+      "MSC pooling: load balancing across multiple MSCs.\n"
+      "Adjust current state of the MSC round-robin algorithm (for testing).\n"
+      "Set the MSC nr to direct the next new subscriber to (for testing).\n"
+      "MSC number, as in the config file; if the number does not exist,"
+      " the round-robin continues to the next valid number.\n")
+{
+       bsc_gsmnet->mscs_round_robin_next_nr = atoi(argv[0]);
+       return CMD_SUCCESS;
+}
+
 int bsc_vty_init_extra(void)
 {
        struct gsm_network *net = bsc_gsmnet;
@@ -1004,6 +1016,7 @@
        install_element_ve(&show_nri_cmd);

        install_element(ENABLE_NODE, &gen_position_trap_cmd);
+       install_element(ENABLE_NODE, &mscpool_roundrobin_next_cmd);

        install_element(CFG_LOG_NODE, &logging_fltr_imsi_cmd);


--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/18767
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I2155d906505a26744966f442ffb1e87a6a9b494c
Gerrit-Change-Number: 18767
Gerrit-PatchSet: 8
Gerrit-Owner: neels <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <[email protected]>
Gerrit-Reviewer: dexter <[email protected]>
Gerrit-Reviewer: laforge <[email protected]>
Gerrit-Reviewer: neels <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>
Gerrit-MessageType: merged

Reply via email to