phet commented on code in PR #4078:
URL: https://github.com/apache/gobblin/pull/4078#discussion_r1876806190


##########
gobblin-temporal/src/main/java/org/apache/gobblin/temporal/ddm/work/CommitStats.java:
##########
@@ -34,11 +36,13 @@
 @Data
 @NoArgsConstructor // IMPORTANT: for jackson (de)serialization
 @RequiredArgsConstructor
+@Accessors(chain = true)
 public class CommitStats {
   @NonNull private Map<String, DatasetStats> datasetStats;
   @NonNull private int numCommittedWorkUnits;
+  @NonNull private Optional<Exception> optFailure;

Review Comment:
   let's treat these `@Data` POJOs as immutable and construct them 
fully/finally initialized.
   
   in fact, all these fields would have been `private final`, but that doesn't 
play well w/ jackson's JSON deserialization, so they're forced to be `@NonNull 
private` instead.  let's continue w/ the original intent that they're immutable 
`@Data` objects.  (hence no `@Accessors`)



-- 
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: dev-unsubscr...@gobblin.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to