Skip to content

Commit 817a817

Browse files
authored
feat(errorno): add new error no for transaction producer (#201)
1 parent 0846f30 commit 817a817

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

include/CCommon.h

+3-1
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ typedef enum _CStatus_ {
3838
PRODUCER_SEND_ORDERLY_FAILED = 13,
3939
PRODUCER_SEND_ASYNC_FAILED = 14,
4040
PRODUCER_SEND_ORDERLYASYNC_FAILED = 15,
41+
PRODUCER_SEND_TRANSACTION_FAILED = 16,
4142

4243
PUSHCONSUMER_ERROR_CODE_START = 20,
4344
PUSHCONSUMER_START_FAILED = 20,
@@ -47,7 +48,8 @@ typedef enum _CStatus_ {
4748
PULLCONSUMER_FETCH_MQ_FAILED = 31,
4849
PULLCONSUMER_FETCH_MESSAGE_FAILED = 32,
4950

50-
Not_Support = 500
51+
Not_Support = 500,
52+
NOT_SUPPORT_NOW = -1
5153
} CStatus;
5254

5355
typedef enum _CLogLevel_ {

src/extern/CProducer.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -595,7 +595,7 @@ int SendMessageTransaction(CProducer* producer,
595595
result->msgId[MAX_MESSAGE_ID_LENGTH - 1] = 0;
596596
} catch (exception& e) {
597597
MQClientErrorContainer::setErr(string(e.what()));
598-
return PRODUCER_SEND_SYNC_FAILED;
598+
return PRODUCER_SEND_TRANSACTION_FAILED;
599599
}
600600
return OK;
601601
}

0 commit comments

Comments
 (0)