private void asyncSendByMessageSender(MsgSendCallback cb,
            List<byte[]> bodyList, String groupId, String streamId, long dataTime, String msgUUID,
            Map<String, String> extraAttrMap, boolean isProxySend) throws Exception {
        boolean isSuccess;
        ProcessResult procResult = new ProcessResult();
        int index = (int) Math.abs(senderIndex.getAndAdd(1) % maxSenderPerGroup);
        if (isProxySend) {
            isSuccess = senders.get(index)
                    .asyncSendMsgWithSinkAck(new TcpEventInfo(
                            groupId, streamId, dataTime, msgUUID, extraAttrMap, bodyList), cb, procResult);
        } else {
            isSuccess =
                    senders.get(index).asyncSendMessage(new TcpEventInfo(
                            groupId, streamId, dataTime, msgUUID, extraAttrMap, bodyList), cb, procResult);
        }
        if (!isSuccess) {
            throw new ProxySdkException("Send message failure, " + procResult);
        }
    }
Send message to proxy by batch, use message cache.
inlong-agent/agent-plugins/src/main/java/org/apache/inlong/agent/plugin/sinks/dataproxy/Sender.java