public void buildRecordInfo(StringBuilder strBuff, long dataTime) {
        long lastTime;
        int itemCnt = 0;
        strBuff.append("{\"dt\":").append(dataTime)
                .append(",\"bId\":").append(brokerId)
                .append(",\"ver\":").append(TBaseConstants.OFFSET_HISTORY_RECORD_VERSION_3)
                .append(",\"group\":\"").append(groupName)
                .append("\",\"on\":").append(isOnLine ? 1 : 0)
                .append(",\"flt\":").append(isFilterCsm ? 1 : 0)
                .append(",\"clients\":[");
        for (Map.Entry<String, Tuple2<Integer, Long>> entry : clientMap.entrySet()) {
            if (entry == null || entry.getKey() == null || entry.getValue() == null) {
                continue;
            }
            if (itemCnt++ > 0) {
                strBuff.append(",");
            }
            lastTime = 0L;
            if (entry.getValue().getF1() != null) {
                lastTime = entry.getValue().getF1();
            }
            strBuff.append("{\"recId\":").append(entry.getValue().getF0())
                    .append(",\"cltId\":\"").append(entry.getKey()).append("\",\"lstTm\":")
                    .append(lastTime).append("}");
        }
        itemCnt = 0;
        strBuff.append("],\"records\":[");
        for (Map.Entry<String, Map<Integer, OffsetCsmRecord>> entry : histOffsetMap.entrySet()) {
            if (entry == null || entry.getKey() == null || entry.getValue() == null) {
                continue;
            }
            if (itemCnt++ > 0) {
                strBuff.append(",");
            }
            int recordCnt = 0;
            strBuff.append("{\"topic\":\"").append(entry.getKey()).append("\",\"offsets\":[");
            Map<Integer, OffsetCsmRecord> csmOffsetRecordMap = entry.getValue();
            for (OffsetCsmRecord offsetRecord : csmOffsetRecordMap.values()) {
                if (offsetRecord == null) {
                    continue;
                }
                if (recordCnt++ > 0) {
                    strBuff.append(",");
                }
                strBuff.append("{\"storeId\":").append(offsetRecord.storeId)
                        .append(",\"iMin\":").append(offsetRecord.offsetMin)
                        .append(",\"iMax\":").append(offsetRecord.offsetMax)
                        .append(",\"dMin\":").append(offsetRecord.dataMin)
                        .append(",\"dMax\":").append(offsetRecord.dataMax)
                        .append(",\"parts\":[");
                int partCnt = 0;
                for (OffsetCsmItem csmOffsetItem : offsetRecord.partitionCsmMap.values()) {
                    if (csmOffsetItem == null) {
                        continue;
                    }
                    if (partCnt++ > 0) {
                        strBuff.append(",");
                    }
                    if (csmOffsetItem.clientRecId == -1) {
                        strBuff.append("{\"partId\":").append(csmOffsetItem.partitionId)
                                .append(",\"iCfm\":").append(csmOffsetItem.cfmOffset)
                                .append(",\"iFlt\":").append(csmOffsetItem.inflightOffset)
                                .append("}");
                    } else {
                        strBuff.append("{\"partId\":").append(csmOffsetItem.partitionId)
                                .append(",\"iCfm\":").append(csmOffsetItem.cfmOffset)
                                .append(",\"iFlt\":").append(csmOffsetItem.inflightOffset)
                                .append(",\"recId\":").append(csmOffsetItem.clientRecId)
                                .append("}");
                    }
                }
                strBuff.append("]}");
            }
            strBuff.append("]}");
        }
        strBuff.append("]}");
    }
Build brief consumption offset information in string format

@param strBuff     string buffer
@param dataTime    record build time
inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/broker/offset/OffsetHistoryInfo.java