mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2026-11-25 21:21:37 +00:00
fix(config): reject channel properties of the wrong type
- ptree::get(key, default) returns the default also for a value that does not convert, so a typo (e.g. sndBufSize=big) silently gave the default value - Use the default only for a missing key; throw ParserError with the key and the value for a value of the wrong type - Rethrow parser errors in the config plugin: before, the device logged the error and continued without its channel configuration - Enable JSONParser and SuboptParser RejectsValuesOfTheWrongType - Update the documentation pages that described the defect, and the source line links into the changed files Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -44,7 +44,8 @@ Config::Config(const string& name, Plugin::Version version, const string& mainta
|
||||
LOG(info) << "fair::mq::plugins::Config: no channels configuration provided via --mq-config or --channel-config";
|
||||
}
|
||||
} catch (exception& e) {
|
||||
LOG(error) << e.what();
|
||||
LOG(error) << "Invalid channel configuration: " << e.what();
|
||||
throw;
|
||||
}
|
||||
} else {
|
||||
LOG(warn) << "No device ID or config-key provided for the configuration parser.";
|
||||
|
||||
Reference in New Issue
Block a user