@@ -147,6 +147,12 @@ static ErrCode fetchMetaConfigs() {
147147 submitPropGetRequest (MAX_RESOURCES_PER_REQUEST , resultBuffer, " 5" );
148148 UrmSettings::metaConfigs.mMaxResourcesPerRequest = (uint32_t )std::stol (resultBuffer);
149149
150+ submitPropGetRequest (THREAD_POOL_DESIRED_CAPACITY , resultBuffer, " 5" );
151+ UrmSettings::metaConfigs.mDesiredThreadCount = (uint32_t )std::stol (resultBuffer);
152+
153+ submitPropGetRequest (THREAD_POOL_MAX_SCALING_CAPACITY , resultBuffer, " 10" );
154+ UrmSettings::metaConfigs.mMaxScalingCapacity = (uint32_t )std::stol (resultBuffer);
155+
150156 submitPropGetRequest (PULSE_MONITOR_DURATION , resultBuffer, " 60000" );
151157 UrmSettings::metaConfigs.mPulseDuration = (uint32_t )std::stol (resultBuffer);
152158
@@ -165,6 +171,17 @@ static ErrCode fetchMetaConfigs() {
165171 submitPropGetRequest (RATE_LIMITER_REWARD_FACTOR , resultBuffer, " 0.4" );
166172 UrmSettings::metaConfigs.mRewardFactor = std::stod (resultBuffer);
167173
174+ submitPropGetRequest (URM_MAX_PLUGIN_COUNT , resultBuffer, " 3" );
175+ UrmSettings::metaConfigs.mPluginCount = (uint32_t )std::stol (resultBuffer);
176+
177+ if (UrmSettings::metaConfigs.mDesiredThreadCount < 1 ) {
178+ UrmSettings::metaConfigs.mDesiredThreadCount = 5 ; // Reset to default
179+ }
180+
181+ if (UrmSettings::metaConfigs.mMaxScalingCapacity > 100 ) {
182+ UrmSettings::metaConfigs.mMaxScalingCapacity = 100 ;
183+ }
184+
168185 } catch (const std::invalid_argument& e) {
169186 TYPELOGV (META_CONFIG_PARSE_FAILURE , e.what ());
170187 return RC_PROP_PARSING_ERROR ;
@@ -406,8 +423,8 @@ static ErrCode fetchPerAppConfigs() {
406423
407424// Initialize Request and Timer ThreadPools
408425static ErrCode preAllocateWorkers () {
409- int32_t desiredThreadCapacity = UrmSettings::desiredThreadCount ;
410- int32_t maxScalingCapacity = UrmSettings::maxScalingCapacity ;
426+ uint32_t desiredThreadCapacity = UrmSettings::metaConfigs. mDesiredThreadCount ;
427+ uint32_t maxScalingCapacity = UrmSettings::metaConfigs. mMaxScalingCapacity ;
411428
412429 try {
413430 RequestReceiver::mRequestsThreadPool = new ThreadPool (desiredThreadCapacity,
0 commit comments