[ 
https://issues.apache.org/jira/browse/GOBBLIN-1533?focusedWorklogId=648144&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-648144
 ]

ASF GitHub Bot logged work on GOBBLIN-1533:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 08/Sep/21 18:32
            Start Date: 08/Sep/21 18:32
    Worklog Time Spent: 10m 
      Work Description: ZihanLi58 commented on a change in pull request #3385:
URL: https://github.com/apache/gobblin/pull/3385#discussion_r704674398



##########
File path: 
gobblin-iceberg/src/main/java/org/apache/gobblin/iceberg/writer/IcebergMetadataWriter.java
##########
@@ -616,23 +689,75 @@ protected void addFiles(GobblinMetadataChangeEvent gmce, 
Map<String, Collection<
   /**
    * Method to get dataFiles with metrics information
    * This method is used to get files to be added to iceberg
+   * if completeness is enabled a new field (late) is added to table schema 
and partition spec
+   * computed based on datepartition and completion watermark
    * This method will call method {IcebergUtils.getIcebergDataFileWithMetric} 
to get DataFile for specific file path
    */
-  private Set<DataFile> 
getIcebergDataFilesToBeAdded(List<org.apache.gobblin.metadata.DataFile> files,
+  private Set<DataFile> getIcebergDataFilesToBeAdded(Table table, 
TableMetadata tableMetadata, GobblinMetadataChangeEvent gmce, 
List<org.apache.gobblin.metadata.DataFile> files,
       PartitionSpec partitionSpec, Map<String, Collection<HiveSpec>> 
newSpecsMap, Map<Integer, Integer> schemaIdMap) {
     Set<DataFile> dataFiles = new HashSet<>();
     for (org.apache.gobblin.metadata.DataFile file : files) {
       try {
-        StructLike partition = getIcebergPartitionVal(newSpecsMap.get(new 
Path(file.getFilePath()).getParent().toString()),
-            file.getFilePath(), partitionSpec);
-        dataFiles.add(IcebergUtils.getIcebergDataFileWithMetric(file, 
partitionSpec, partition, conf, schemaIdMap));
+        Collection<HiveSpec> hiveSpecs = newSpecsMap.get(new 
Path(file.getFilePath()).getParent().toString());

Review comment:
       Yeah, just want to avoid confusing people when reading through the code. 
Can you create a follow up ticket to refactor the class?




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


Issue Time Tracking
-------------------

    Worklog Id:     (was: 648144)
    Time Spent: 3h  (was: 2h 50m)

> Add Completeness watermark to iceberg table
> -------------------------------------------
>
>                 Key: GOBBLIN-1533
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-1533
>             Project: Apache Gobblin
>          Issue Type: Improvement
>            Reporter: Vikram Bohra
>            Priority: Major
>          Time Spent: 3h
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to