udpate omti.worker_pool while updating cpu_count config.
This commit is contained in:
		| @ -327,6 +327,7 @@ int ObServerReloadConfig::operator()() | |||||||
|   share::ObTaskController::get().set_log_rate_limit(GCONF.syslog_io_bandwidth_limit.get_value()); |   share::ObTaskController::get().set_log_rate_limit(GCONF.syslog_io_bandwidth_limit.get_value()); | ||||||
|  |  | ||||||
|   if (nullptr != GCTX.omt_) { |   if (nullptr != GCTX.omt_) { | ||||||
|  |     GCTX.omt_->set_node_quota(common::get_cpu_count()); | ||||||
|     GCTX.omt_->set_workers_per_cpu(GCONF.workers_per_cpu_quota.get_value()); |     GCTX.omt_->set_workers_per_cpu(GCONF.workers_per_cpu_quota.get_value()); | ||||||
|   } |   } | ||||||
|  |  | ||||||
|  | |||||||
| @ -744,6 +744,11 @@ void ObMultiTenant::set_workers_per_cpu(int64_t v) | |||||||
|   LOG_INFO("set max workers", K(max_workers_cnt)); |   LOG_INFO("set max workers", K(max_workers_cnt)); | ||||||
| } | } | ||||||
|  |  | ||||||
|  | void ObMultiTenant::set_node_quota(double node_quota) | ||||||
|  | { | ||||||
|  |   node_quota_ = node_quota; | ||||||
|  | } | ||||||
|  |  | ||||||
| void ObMultiTenant::run1() | void ObMultiTenant::run1() | ||||||
| { | { | ||||||
|   lib::set_thread_name("MultiTenant"); |   lib::set_thread_name("MultiTenant"); | ||||||
|  | |||||||
| @ -117,6 +117,7 @@ public: | |||||||
|   inline bool has_synced() const; |   inline bool has_synced() const; | ||||||
|  |  | ||||||
|   void set_workers_per_cpu(int64_t v); |   void set_workers_per_cpu(int64_t v); | ||||||
|  |   void set_node_quota(double node_quota); | ||||||
|  |  | ||||||
| protected: | protected: | ||||||
|   void run1(); |   void run1(); | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user
	 hnwyllmm
					hnwyllmm