lnbest0707-uber commented on code in PR #16494:
URL: https://github.com/apache/pinot/pull/16494#discussion_r2283698971
##########
pinot-common/src/main/java/org/apache/pinot/common/utils/LLCSegmentName.java:
##########
@@ -94,17 +129,34 @@ public static boolean isLowLevelConsumerSegmentName(String
segmentName) {
* Returns the sequence number of the given segment name.
*/
public static int getSequenceNumber(String segmentName) {
- return Integer.parseInt(StringUtils.splitByWholeSeparator(segmentName,
SEPARATOR)[2]);
+ String[] parts = StringUtils.splitByWholeSeparator(segmentName, SEPARATOR);
+ if (parts.length == 4) {
+ return Integer.parseInt(parts[2]);
+ } else {
+ return Integer.parseInt(parts[3]);
+ }
}
public String getTableName() {
return _tableName;
}
+ public String getTopicName() {
+ return _topicName;
+ }
+
public int getPartitionGroupId() {
return _partitionGroupId;
}
+ public String getPartitionGroupInfo() {
Review Comment:
Change the function name to make it more intuitive
--
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]