MCPcopy Create free account
hub / github.com/ClickHouse/ClickHouse / parseConfig

Method parseConfig

programs/keeper-bench/StorageRunner.cpp:92–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

90}
91
92void StorageRunner::parseConfig(const Poco::Util::AbstractConfiguration & config)
93{
94 concurrency = config.getUInt("concurrency", 4);
95 max_time = config.getDouble("timelimit", 0.0);
96 report_delay = config.getDouble("report_delay", 1.0);
97 max_iterations = config.getUInt64("iterations", 0);
98 continue_on_error = config.getBool("continue_on_error", false);
99
100 writes_per_read_batch = config.getUInt64("storage.writes_per_read_batch", 10);
101 snapshot_toggle_periods = config.getUInt64("storage.snapshot_toggle_periods", 0);
102 preprocess_commit_queue_size = config.getUInt64("storage.preprocess_commit_queue_size", 32);
103 input_queue_size = config.getUInt64("storage.input_queue_size", 2048);
104 tick_time_ms = config.getInt64("storage.tick_time_ms", 500);
105
106 if (writes_per_read_batch == 0)
107 throw DB::Exception(DB::ErrorCodes::BAD_ARGUMENTS, "storage.writes_per_read_batch must be >= 1");
108 if (preprocess_commit_queue_size < 2)
109 throw DB::Exception(DB::ErrorCodes::BAD_ARGUMENTS, "storage.preprocess_commit_queue_size must be >= 2");
110 if (input_queue_size < 2)
111 throw DB::Exception(DB::ErrorCodes::BAD_ARGUMENTS, "storage.input_queue_size must be >= 2");
112
113 benchmark_context.initializeFromConfig(config);
114}
115
116size_t StorageRunner::opIndex(Coordination::OpNum op_num)
117{

Callers 2

mainMethod · 0.45
tryInitPathMethod · 0.45

Calls 7

initializeFromConfigMethod · 0.80
ExceptionClass · 0.50
getUIntMethod · 0.45
getDoubleMethod · 0.45
getUInt64Method · 0.45
getBoolMethod · 0.45
getInt64Method · 0.45

Tested by

no test coverage detected