szlta commented on a change in pull request #2619:
URL: https://github.com/apache/hive/pull/2619#discussion_r703308035
##########
File path:
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/txn/CompactionInfo.java
##########
@@ -277,6 +277,6 @@ public static CompactionInfo
optionalCompactionInfoStructToInfo(OptionalCompacti
public void setWriteIds(Set<Long> writeIds) {
this.writeIds = writeIds;
- isSetWriteIds = true;
+ isSetWriteIds = !writeIds.isEmpty();
Review comment:
Why do we maintain 2 states for this anyway?
We could have a method instead:
public boolean isSetWriteIds() { return !writeIds.isEmpty(); }
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]