@Override
    public boolean modifyGroupOffset(Set<String> groups,
            List<Tuple3<String, Integer, Long>> topicPartOffsets,
            String modifier) {
        long oldOffset;
        boolean changed = false;
        String offsetCacheKey;
        StringBuilder strBuff = new StringBuilder(512);
        // set offset by group
        for (String group : groups) {
            for (Tuple3<String, Integer, Long> tuple3 : topicPartOffsets) {
                if (tuple3 == null
                        || tuple3.getF0() == null
                        || tuple3.getF1() == null
                        || tuple3.getF2() == null) {
                    continue;
                }
                // set offset value
                offsetCacheKey = OffsetStgInfo.buildOffsetKey(tuple3.getF0(), tuple3.getF1());
                getAndResetTmpOffset(group, offsetCacheKey);
                OffsetStorageInfo regInfo = loadOrCreateOffset(group,
                        tuple3.getF0(), tuple3.getF1(), offsetCacheKey, 0);
                oldOffset = regInfo.getAndSetOffset(tuple3.getF2());
                changed = true;
                logger.info(strBuff
                        .append("[Offset Manager] Update offset by modifier=")
                        .append(modifier).append(",resetOffset=").append(tuple3.getF2())
                        .append(",loadedOffset=").append(oldOffset)
                        .append(",currentOffset=").append(regInfo.getOffset())
                        .append(",group=").append(group)
                        .append(",topic-part=").append(offsetCacheKey).toString());
                strBuff.delete(0, strBuff.length());
            }
        }
        return changed;
    }
Reset offset.

@param groups              the groups to reset offset
@param topicPartOffsets    the reset offset information
@param modifier            the modifier
@return at least one record modified
inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/broker/offset/DefaultOffsetManager.java