public static boolean parseRecordInfo(String topicName,
            int curNumStores, int curNumParts,
            String jsonData, ProcessResult result) {
        JsonObject jsonObject;
        // parse record
        try {
            jsonObject = JsonParser.parseString(jsonData).getAsJsonObject();
        } catch (Throwable e1) {
            result.setFailResult(String.format(
                    "Parse topic %s offset value failure, reason is %s", topicName, e1.getMessage()));
            return result.isSuccess();
        }
        // check record
        if (jsonObject == null) {
            result.setFailResult(String.format(
                    "Parse error, topic %s offset value must be valid json format!", topicName));
            return result.isSuccess();
        }
        if (!isFieldExist(jsonObject, topicName, "ver", result)
                || !isFieldExist(jsonObject, topicName, "dt", result)
                || !isFieldExist(jsonObject, topicName, "offsets", result)
                || !isFieldExist(jsonObject, topicName, "topic", result)) {
            return result.isSuccess();
        }
        int verValue = jsonObject.get("ver").getAsInt();
        if (verValue != TBaseConstants.OFFSET_TOPIC_PUBLISH_RECORD_VERSION_1) {
            result.setFailResult(String.format(
                    "Un-support %d version in %s's offset value!", verValue, topicName));
            return result.isSuccess();
        }
        long dataTime = jsonObject.get("dt").getAsLong();
        String targetTopic = jsonObject.get("topic").getAsString();
        if (!topicName.equals(targetTopic)) {
            result.setFailResult(String.format(
                    "FIELD topic value %s not equals required value %s!", targetTopic, topicName));
            return result.isSuccess();
        }
        // get offsets
        int storeId;
        int baseValue;
        long offsetVal;
        JsonObject itemInfo;
        JsonArray records = jsonObject.get("offsets").getAsJsonArray();
        List<Tuple4<Long, String, Integer, Long>> resetOffsets = new ArrayList<>();
        for (int i = 0; i < records.size(); i++) {
            itemInfo = records.get(i).getAsJsonObject();
            if (itemInfo == null) {
                continue;
            }
            storeId = itemInfo.get("storeId").getAsInt();
            offsetVal = itemInfo.get("iMax").getAsLong();
            baseValue = storeId * TBaseConstants.META_STORE_INS_BASE;
            for (int j = 0; j < curNumParts; j++) {
                resetOffsets.add(new Tuple4<>(dataTime, topicName, baseValue + j, offsetVal));
            }
        }
        for (int i = records.size(); i < curNumStores; i++) {
            baseValue = i * TBaseConstants.META_STORE_INS_BASE;
            for (int j = 0; j < curNumParts; j++) {
                resetOffsets.add(new Tuple4<>(dataTime, topicName, baseValue + j, 0L));
            }
        }
        result.setSuccResult(resetOffsets);
        return result.isSuccess();
    }
Parse produce offset record info

@param jsonData  string offset information
@param result    process result
inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/broker/offset/topicpub/TopicPubInfo.java