Copilot commented on code in PR #14088:
URL: https://github.com/apache/trafficserver/pull/14088#discussion_r4585877836
##########
src/proxy/logging/LogConfig.cc:
##########
@@ -455,6 +455,10 @@ LogConfig::register_config_callbacks()
"proxy.config.log.auto_delete_rolled_files",
"proxy.config.log.rolling_max_count",
"proxy.config.log.rolling_allow_empty",
+ "proxy.config.log.rolling_min_count",
+ "proxy.config.diags.logfile.rolling_min_count",
+ "proxy.config.output.logfile.rolling_min_count",
+ "proxy.config.log.log_fast_buffer",
Review Comment:
Changing `log_fast_buffer` from 1 to 0 now triggers a reload that can crash
with configured access logs. The reload flushes the old fast-mode objects
through `force_new_buffer()` and `_checkout_write()`, which dereferences a
shared buffer that fast-mode objects never allocate. Make reload flushing and
object retirement handle thread-local fast buffers safely, or make this setting
restart-only instead of adding this callback.
##########
src/proxy/logging/LogConfig.cc:
##########
@@ -470,7 +474,7 @@ LogConfig::register_config_callbacks()
config::ConfigSource::FileOnly);
for (unsigned i = 0; i < countof(names); ++i) {
- registry.attach("logging", names[i]);
+ ink_assert(0 == registry.attach("logging", names[i]));
Review Comment:
This assertion aborts logging initialization in debug/assert-enabled builds
because `names[]` still contains `proxy.config.log.error_log_filename` at line
447. The registered record is `proxy.config.error.logfile.filename`
(`RecordsConfig.cc:265`), so attaching the current name returns -1. Correct
that callback entry before asserting attachment success.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]