jack-moseley commented on a change in pull request #3083:
URL: https://github.com/apache/incubator-gobblin/pull/3083#discussion_r471842017



##########
File path: 
gobblin-service/src/main/java/org/apache/gobblin/service/modules/core/GitFlowGraphMonitor.java
##########
@@ -184,10 +184,13 @@ private void addDataNode(DiffEntry change) {
     if (checkFilePath(change.getNewPath(), NODE_FILE_DEPTH)) {
       Path nodeFilePath = new Path(this.repositoryDir, change.getNewPath());
       try {
-        Config config = loadNodeFileWithOverrides(nodeFilePath);
-        Class dataNodeClass = Class.forName(ConfigUtils.getString(config, 
FlowGraphConfigurationKeys.DATA_NODE_CLASS,
+        // Temporarily resolve the data node config when constructing it, but 
leave it unresolved after to allow overriding
+        Config unresolvedConfig = loadNodeFileWithOverrides(nodeFilePath);
+        Config resolvedConfig = unresolvedConfig.resolve();

Review comment:
       I would have done that, but for example the fs URI check happens in 
`FileSystemDataNode`, not `BaseDataNode`. I did it this way to avoid needing to 
add this resolution into the constructor of every child data node.




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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to