kSchemasThroughputPeriodSetting#
Fully qualified name: omni::structuredlog::kSchemasThroughputPeriodSetting
Defined in omni/structuredlog/StructuredLogSettingsUtils.h
-
constexpr const char *omni::structuredlog::kSchemasThroughputPeriodSetting = "/structuredLog/limits/throughputPeriod"#
This is the path for settings tree that contains the set of schemas or wildcards to set the time period (in milliseconds) for the throughput limits defined by kSchemasThroughputLimitsSetting.
Rate limiting is done where the sum of one second worth of time windows cannot exceed the rate limit. For example, assuming the throughput limit is 64KiB bytes and the period is 1000ms, if 64KiB is sent in the first 100ms, all messages will be discarded for the next 900ms. If the period was instead 250ms, messages would be discarded for the next 150ms, then each 250ms window would allow an additional 16KiB to be sent. This allows the throughput over 1 second to exceed the limit (up to 2x in the most extreme case), but the average over a long period of time will be below the limit.
Because structuredlog flushes messages asynchronously, setting a very small period may not have an effect. By default structuredlog flushes messages every 100ms unless the queue is heavily loaded, so window sizes below 100ms may effectively act as 100ms windows.
This must be between 1ms and 1000ms. The default value is 100ms.
structuredLog.limits.period = [ "omni.other_schema = 200", # set omni.other_schema to use a 200ms period. "carb.* = 500" # set carb schemas to a 500ms period. ]