From fd75850f1286ebaef3b49cc7b7bdfcd2a7f3d8ca Mon Sep 17 00:00:00 2001 From: Matheus Guilhermino Date: Tue, 15 Aug 2023 16:57:21 -0300 Subject: [PATCH] Deployment Optimizations: SM throttling disable The SM throttling is a feature that limits the number of parallel service-enabling processes at a time. The SM throttling mechanism is always ON, during and after startup. Whenever SM controlled services transition to enabled status, it takes part of the process. By default, the SM throttling allows a maximum of 2 parallel service enabling processes at a time, but the throttling size is configurable, by means of the field ENABLING_THROTTLE from the CONFIGURATION table in the SM-DB database. Hence, it is possible to disable the SM throttling by increasing the throttling size to a reasonable big enough value, such way to enable full capacity of parallel service enabling. This commit improves system performance by disabling the SM throttling for AIO-SX systems, while still keeping the SM throttling mechanism, should it ever be needed as a fallback, for robustness reasons. In order to evaluate the SM throttling feature, and its costs in terms of performance, the throttling size was modified such way to disable the feature, from value 2 to 1000, and a series of tests were conducted to evaluate stability and performance benefits. Test Plan: - Fresh Install and bootstrap (PASS) - Lock/Unlock (PASS) - Restart SM service (PASS) Story: 2010802 Task: 48312 Change-Id: Ie96115293049e9939bc43feb2ad11432dd318323 Signed-off-by: Matheus Guilhermino --- service-mgmt/sm/src/sm_service_enable.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/service-mgmt/sm/src/sm_service_enable.c b/service-mgmt/sm/src/sm_service_enable.c index 10a02ecc..42cd6285 100644 --- a/service-mgmt/sm/src/sm_service_enable.c +++ b/service-mgmt/sm/src/sm_service_enable.c @@ -582,19 +582,19 @@ static int _get_num_csv_file(const char* filename) // =========================== static int get_initial_throttle() { - bool is_aio; + bool is_aio_duplex; SmErrorT error; - error = sm_node_utils_is_aio(&is_aio); + error = sm_node_utils_is_aio_duplex(&is_aio_duplex); if(SM_OKAY != error) { - DPRINTFE( "Failed to determine if it is AIO, " + DPRINTFE( "Failed to determine if it is AIO-DX, " "error=%s.", sm_error_str(error) ); // prepare for the worst - is_aio = true; + is_aio_duplex = true; } #define MAX_SERVICE_EXPECTED 1000 - if( !is_aio ) + if( !is_aio_duplex ) { return MAX_SERVICE_EXPECTED; }