Github user phrocker commented on a diff in the pull request:

    https://github.com/apache/nifi-minifi-cpp/pull/90#discussion_r114745591
  
    --- Diff: libminifi/src/core/yaml/YamlConfiguration.cpp ---
    @@ -417,29 +405,27 @@ void YamlConfiguration::parseConnectionYaml(
     
     
             // Configure connection source
    -        auto rawRelationship = connectionNode["source relationship name"]
    -            .as<std::string>();
    +        checkRequiredField(&connectionNode, "source relationship name", 
CONFIG_YAML_CONNECTIONS_KEY);
    +        auto rawRelationship = connectionNode["source relationship 
name"].as<std::string>();
             core::Relationship relationship(rawRelationship, "");
    -        logger_->log_debug(
    -            "parseConnection: relationship => [%s]", rawRelationship);
    +        logger_->log_debug("parseConnection: relationship => [%s]", 
rawRelationship);
             if (connection) {
               connection->setRelationship(relationship);
             }
     
             uuid_t srcUUID;
    -        std::string connectionSrcProcName = connectionNode["source name"]
    -            .as<std::string>();
    +
             if (connectionNode["source id"]) {
    -          std::string connectionSrcProcId = connectionNode["source id"]
    -              .as<std::string>();
    +          std::string connectionSrcProcId = connectionNode["source 
id"].as<std::string>();
     
               uuid_parse(connectionSrcProcId.c_str(), srcUUID);
             } else {
               // if we don't have a source id, try harder to resolve the 
source processor.
               // config schema v2 will make this unnecessary
    +          checkRequiredField(&connectionNode, "source name", 
CONFIG_YAML_CONNECTIONS_KEY);
    --- End diff --
    
    @kevdoran I like that you documented your assumption. Could you augment 
that comment with a log message affirming the decision of the code so that we 
could better debug "how and why?"


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to