lordgamez commented on code in PR #2063:
URL: https://github.com/apache/nifi-minifi-cpp/pull/2063#discussion_r2518683757


##########
core-framework/include/core/VariableRegistry.h:
##########
@@ -40,53 +44,37 @@ class VariableRegistryImpl : public virtual 
VariableRegistry {
 
   ~VariableRegistryImpl() override = default;
 
-  bool getConfigurationProperty(const std::string &property, std::string 
&value) const override {
-    auto prop = variable_registry_.find(property);
-    if (prop != variable_registry_.end()) {
-      value = prop->second;
-      return true;
+  [[nodiscard]] std::optional<std::string> getConfigurationProperty(const 
std::string_view key) const override {
+    const auto it = variable_registry_.find(key);
+    if (it == variable_registry_.end()) {
+      return std::nullopt;
     }
-    return false;
+    return it->second;
   }
 
  protected:
   void loadVariableRegistry() {
-    std::string registry_values;
-
-    auto options = configuration_->getConfiguredKeys();
-    std::string white_list_opt = "minifi.variable.registry.whitelist", 
white_list;
-    std::string black_list_opt = "minifi.variable.registry.blacklist", 
black_list;
+    gsl_Assert(configuration_);
+    auto options = configuration_->get("minifi.variable.registry.whitelist")

Review Comment:
   I think the `minifi.variable.registry.whitelist` constant should be moved to 
the `minifi::Configuration::CONFIGURATION_PROPERTIES` to be available on the C2 
server for property update



-- 
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]

Reply via email to