alibaba/canal · error · CanalClientException
mq get/ack not support concurrent & async ack
Error message
mq get/ack not support concurrent & async ack
What it means
Error "mq get/ack not support concurrent & async ack" thrown in alibaba/canal.
Source
Thrown at client/src/main/java/com/alibaba/otter/canal/client/rabbitmq/RabbitMQCanalConnector.java:196
public void rollback(long batchId) throws CanalClientException {
throw new CanalClientException("mq not support this method");
}
@Override
public List<Message> getList(Long timeout, TimeUnit unit) throws CanalClientException {
List<Message> messages = getListWithoutAck(timeout, unit);
if (messages != null && !messages.isEmpty()) {
ack();
}
return messages;
}
@Override
public List<Message> getListWithoutAck(Long timeout, TimeUnit unit) throws CanalClientException {
try {
if (this.lastGetBatchMessage != null) {
throw new CanalClientException("mq get/ack not support concurrent & async ack");
}
ConsumerBatchMessage batchMessage = messageBlockingQueue.poll(timeout, unit);
if (batchMessage != null) {
this.lastGetBatchMessage = batchMessage;
return batchMessage.getData();
}
} catch (InterruptedException ex) {
logger.warn("Get message timeout", ex);
throw new CanalClientException("Failed to fetch the data after: " + timeout);
}
return Lists.newArrayList();
}
@Override
public List<FlatMessage> getFlatList(Long timeout, TimeUnit unit) throws CanalClientException {
List<FlatMessage> messages = getFlatListWithoutAck(timeout, unit);
if (messages != null && !messages.isEmpty()) {View on GitHub (pinned to 87be50e876)
Solutions
- Disable concurrent/async ack for the RabbitMQ connector; process and ack batches sequentially.
- Use getWithoutAck with manual ack only from a single consumer thread.
When it happens
Trigger: Thrown at client/src/main/java/com/alibaba/otter/canal/client/rabbitmq/RabbitMQCanalConnector.java:196 when the library encounters an invalid state.
Common situations: Concurrent async ack on RabbitMQ connector. Serialize acks per batch; concurrent acknowledgements on one channel are not supported by the client.
AI-assisted analysis of alibaba/canal@87be50e876 (2026-08-14).
Data as JSON: /api/errors/42154fb2c738caf0.
Report an issue: GitHub.