/src/tdengine/include/common/tmsg.h
Line | Count | Source |
1 | | /* |
2 | | * Copyright (c) 2019 TAOS Data, Inc. <jhtao@taosdata.com> |
3 | | * |
4 | | * SPDX-License-Identifier: AGPL-3.0-or-later |
5 | | * |
6 | | * This program is free software: you can use, redistribute, and/or modify |
7 | | * it under the terms of the GNU Affero General Public License, version 3 |
8 | | * or later ("AGPL"), as published by the Free Software Foundation. |
9 | | * |
10 | | * This program is distributed in the hope that it will be useful, but WITHOUT |
11 | | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
12 | | * FITNESS FOR A PARTICULAR PURPOSE. |
13 | | * |
14 | | * You should have received a copy of the GNU Affero General Public License |
15 | | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
16 | | */ |
17 | | |
18 | | #ifndef _TD_COMMON_TAOS_MSG_H_ |
19 | | #define _TD_COMMON_TAOS_MSG_H_ |
20 | | |
21 | | #include <stdint.h> |
22 | | #include "taosdef.h" |
23 | | #include "taoserror.h" |
24 | | #include "tarray.h" |
25 | | #include "tcoding.h" |
26 | | #include "tcol.h" |
27 | | #include "tencode.h" |
28 | | #include "thash.h" |
29 | | #include "tlist.h" |
30 | | #include "tname.h" |
31 | | #include "tpriv.h" |
32 | | #include "trow.h" |
33 | | #include "tsimplehash.h" |
34 | | #include "tuuid.h" |
35 | | |
36 | | // Forward declaration - full definition in libs/nodes/nodes.h |
37 | | typedef struct SNode SNode; |
38 | | |
39 | | #ifdef __cplusplus |
40 | | extern "C" { |
41 | | #endif |
42 | | |
43 | | /* ------------------------ MESSAGE DEFINITIONS ------------------------ */ |
44 | | |
45 | | #define TD_MSG_NUMBER_ |
46 | | #undef TD_MSG_DICT_ |
47 | | #undef TD_MSG_INFO_ |
48 | | #undef TD_MSG_TYPE_INFO_ |
49 | | #undef TD_MSG_RANGE_CODE_ |
50 | | #undef TD_MSG_SEG_CODE_ |
51 | | #include "tmsgdef.h" |
52 | | |
53 | | #undef TD_MSG_NUMBER_ |
54 | | #undef TD_MSG_DICT_ |
55 | | #undef TD_MSG_INFO_ |
56 | | #undef TD_MSG_TYPE_INFO_ |
57 | | #undef TD_MSG_RANGE_CODE_ |
58 | | #define TD_MSG_SEG_CODE_ |
59 | | #include "tmsgdef.h" |
60 | | |
61 | | #undef TD_MSG_NUMBER_ |
62 | | #undef TD_MSG_DICT_ |
63 | | #undef TD_MSG_INFO_ |
64 | | #undef TD_MSG_TYPE_INFO_ |
65 | | #undef TD_MSG_SEG_CODE_ |
66 | | #undef TD_MSG_RANGE_CODE_ |
67 | | #include "tmsgdef.h" |
68 | | |
69 | | extern char* tMsgInfo[]; |
70 | | extern int32_t tMsgDict[]; |
71 | | extern int32_t tMsgRangeDict[]; |
72 | | |
73 | | typedef uint16_t tmsg_t; |
74 | | |
75 | 0 | #define TMSG_SEG_CODE(TYPE) (((TYPE) & 0xff00) >> 8) |
76 | 0 | #define TMSG_SEG_SEQ(TYPE) ((TYPE) & 0xff) |
77 | 0 | #define TMSG_INDEX(TYPE) (tMsgDict[TMSG_SEG_CODE(TYPE)] + TMSG_SEG_SEQ(TYPE)) |
78 | | |
79 | | #define DECODESQL() \ |
80 | 0 | do { \ |
81 | 0 | if (!tDecodeIsEnd(&decoder)) { \ |
82 | 0 | TAOS_CHECK_EXIT(tDecodeI32(&decoder, &pReq->sqlLen)); \ |
83 | 0 | if (pReq->sqlLen > 0) { \ |
84 | 0 | TAOS_CHECK_EXIT(tDecodeBinaryAlloc(&decoder, (void**)&pReq->sql, NULL)); \ |
85 | 0 | } \ |
86 | 0 | } \ |
87 | 0 | } while (0) |
88 | | |
89 | | #define ENCODESQL() \ |
90 | 0 | do { \ |
91 | 0 | TAOS_CHECK_EXIT(tEncodeI32(&encoder, pReq->sqlLen)); \ |
92 | 0 | if (pReq->sqlLen > 0) { \ |
93 | 0 | TAOS_CHECK_EXIT(tEncodeBinary(&encoder, (const uint8_t*)pReq->sql, pReq->sqlLen)); \ |
94 | 0 | } \ |
95 | 0 | } while (0) |
96 | | |
97 | | #define FREESQL() \ |
98 | 0 | do { \ |
99 | 0 | if (pReq->sql != NULL) { \ |
100 | 0 | taosMemoryFree(pReq->sql); \ |
101 | 0 | } \ |
102 | 0 | pReq->sql = NULL; \ |
103 | 0 | } while (0) |
104 | | |
105 | 0 | static inline bool tmsgIsValid(tmsg_t type) { |
106 | | // static int8_t sz = sizeof(tMsgRangeDict) / sizeof(tMsgRangeDict[0]); |
107 | 0 | int8_t maxSegIdx = TMSG_SEG_CODE(TDMT_MAX_MSG_MIN); |
108 | 0 | int segIdx = TMSG_SEG_CODE(type); |
109 | 0 | if (segIdx >= 0 && segIdx < maxSegIdx) { |
110 | 0 | return type < tMsgRangeDict[segIdx]; |
111 | 0 | } |
112 | 0 | return false; |
113 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tmsgIsValid Unexecuted instantiation: parser.c:tmsgIsValid Unexecuted instantiation: parTranslater.c:tmsgIsValid Unexecuted instantiation: parUtil.c:tmsgIsValid Unexecuted instantiation: parAstParser.c:tmsgIsValid Unexecuted instantiation: parAuthenticator.c:tmsgIsValid Unexecuted instantiation: parCalcConst.c:tmsgIsValid Unexecuted instantiation: parInsertSql.c:tmsgIsValid Unexecuted instantiation: parInsertUtil.c:tmsgIsValid Unexecuted instantiation: taos_lemon_sql.tab.c:tmsgIsValid Unexecuted instantiation: parAstCreater.c:tmsgIsValid Unexecuted instantiation: parInsertSml.c:tmsgIsValid Unexecuted instantiation: planner.c:tmsgIsValid Unexecuted instantiation: planLogicCreater.c:tmsgIsValid Unexecuted instantiation: planOptimizer.c:tmsgIsValid Unexecuted instantiation: planPhysiCreater.c:tmsgIsValid Unexecuted instantiation: planScaleOut.c:tmsgIsValid Unexecuted instantiation: planSpliter.c:tmsgIsValid Unexecuted instantiation: planUtil.c:tmsgIsValid Unexecuted instantiation: planValidator.c:tmsgIsValid Unexecuted instantiation: catalog.c:tmsgIsValid Unexecuted instantiation: ctgAsync.c:tmsgIsValid Unexecuted instantiation: ctgCache.c:tmsgIsValid Unexecuted instantiation: ctgDbg.c:tmsgIsValid Unexecuted instantiation: ctgRemote.c:tmsgIsValid Unexecuted instantiation: ctgRent.c:tmsgIsValid Unexecuted instantiation: ctgUtil.c:tmsgIsValid Unexecuted instantiation: extConnector.c:tmsgIsValid Unexecuted instantiation: extDialect.c:tmsgIsValid Unexecuted instantiation: extDialectDefaults.c:tmsgIsValid Unexecuted instantiation: functionMgt.c:tmsgIsValid Unexecuted instantiation: tudf.c:tmsgIsValid Unexecuted instantiation: builtins.c:tmsgIsValid Unexecuted instantiation: builtinsimpl.c:tmsgIsValid Unexecuted instantiation: spillDistinctSet.c:tmsgIsValid Unexecuted instantiation: thistogram.c:tmsgIsValid Unexecuted instantiation: tpercentile.c:tmsgIsValid Unexecuted instantiation: tavgfunction.c:tmsgIsValid Unexecuted instantiation: tminmax.c:tmsgIsValid Unexecuted instantiation: tminmaxavx.c:tmsgIsValid Unexecuted instantiation: filter.c:tmsgIsValid Unexecuted instantiation: scalar.c:tmsgIsValid Unexecuted instantiation: sclfunc.c:tmsgIsValid Unexecuted instantiation: sclvector.c:tmsgIsValid Unexecuted instantiation: nodesCloneFuncs.c:tmsgIsValid Unexecuted instantiation: nodesCodeFuncs.c:tmsgIsValid Unexecuted instantiation: nodesEqualFuncs.c:tmsgIsValid Unexecuted instantiation: nodesMatchFuncs.c:tmsgIsValid Unexecuted instantiation: nodesMsgFuncs.c:tmsgIsValid Unexecuted instantiation: nodesRemotePlanToSQL.c:tmsgIsValid Unexecuted instantiation: nodesToSQLFuncs.c:tmsgIsValid Unexecuted instantiation: nodesTraverseFuncs.c:tmsgIsValid Unexecuted instantiation: nodesUtilFuncs.c:tmsgIsValid Unexecuted instantiation: extTypeMap.c:tmsgIsValid Unexecuted instantiation: queryUtil.c:tmsgIsValid Unexecuted instantiation: querymsg.c:tmsgIsValid Unexecuted instantiation: trans.c:tmsgIsValid Unexecuted instantiation: transCli.c:tmsgIsValid Unexecuted instantiation: transComm.c:tmsgIsValid Unexecuted instantiation: transSasl.c:tmsgIsValid Unexecuted instantiation: transSvr.c:tmsgIsValid Unexecuted instantiation: transTLS.c:tmsgIsValid Unexecuted instantiation: thttp.c:tmsgIsValid Unexecuted instantiation: geomFunc.c:tmsgIsValid Unexecuted instantiation: tconfig.c:tmsgIsValid Unexecuted instantiation: tdigest.c:tmsgIsValid Unexecuted instantiation: tlog.c:tmsgIsValid Unexecuted instantiation: tmempool.c:tmsgIsValid Unexecuted instantiation: tpagedbuf.c:tmsgIsValid Unexecuted instantiation: mpDirect.c:tmsgIsValid Unexecuted instantiation: extCapability.c:tmsgIsValid Unexecuted instantiation: systable.c:tmsgIsValid Unexecuted instantiation: tanalytics.c:tmsgIsValid Unexecuted instantiation: tdatablock.c:tmsgIsValid Unexecuted instantiation: tdataformat.c:tmsgIsValid Unexecuted instantiation: tglobal.c:tmsgIsValid Unexecuted instantiation: tmisce.c:tmsgIsValid Unexecuted instantiation: tname.c:tmsgIsValid Unexecuted instantiation: tpriv.c:tmsgIsValid Unexecuted instantiation: ttime.c:tmsgIsValid Unexecuted instantiation: tvariant.c:tmsgIsValid Unexecuted instantiation: streamMsg.c:tmsgIsValid Unexecuted instantiation: streamWindowPlan.c:tmsgIsValid Unexecuted instantiation: tmsg.c:tmsgIsValid Unexecuted instantiation: xnode.c:tmsgIsValid Unexecuted instantiation: tencrypt.c:tmsgIsValid Unexecuted instantiation: streamJson.c:tmsgIsValid Unexecuted instantiation: crypt.c:tmsgIsValid |
114 | | |
115 | | #define TMSG_INFO(type) (tmsgIsValid(type) ? tMsgInfo[TMSG_INDEX(type)] : "unKnown") |
116 | | |
117 | 0 | static inline bool vnodeIsMsgBlock(tmsg_t type) { |
118 | 0 | return (type == TDMT_VND_CREATE_TABLE) || (type == TDMT_VND_ALTER_TABLE) || (type == TDMT_VND_DROP_TABLE) || |
119 | 0 | (type == TDMT_VND_UPDATE_TAG_VAL) || (type == TDMT_VND_ALTER_CONFIRM) || (type == TDMT_VND_COMMIT) || |
120 | 0 | (type == TDMT_SYNC_CONFIG_CHANGE) || (type == TDMT_VND_SYNC_COMMIT); |
121 | 0 | } Unexecuted instantiation: sql-fuzzer.c:vnodeIsMsgBlock Unexecuted instantiation: parser.c:vnodeIsMsgBlock Unexecuted instantiation: parTranslater.c:vnodeIsMsgBlock Unexecuted instantiation: parUtil.c:vnodeIsMsgBlock Unexecuted instantiation: parAstParser.c:vnodeIsMsgBlock Unexecuted instantiation: parAuthenticator.c:vnodeIsMsgBlock Unexecuted instantiation: parCalcConst.c:vnodeIsMsgBlock Unexecuted instantiation: parInsertSql.c:vnodeIsMsgBlock Unexecuted instantiation: parInsertUtil.c:vnodeIsMsgBlock Unexecuted instantiation: taos_lemon_sql.tab.c:vnodeIsMsgBlock Unexecuted instantiation: parAstCreater.c:vnodeIsMsgBlock Unexecuted instantiation: parInsertSml.c:vnodeIsMsgBlock Unexecuted instantiation: planner.c:vnodeIsMsgBlock Unexecuted instantiation: planLogicCreater.c:vnodeIsMsgBlock Unexecuted instantiation: planOptimizer.c:vnodeIsMsgBlock Unexecuted instantiation: planPhysiCreater.c:vnodeIsMsgBlock Unexecuted instantiation: planScaleOut.c:vnodeIsMsgBlock Unexecuted instantiation: planSpliter.c:vnodeIsMsgBlock Unexecuted instantiation: planUtil.c:vnodeIsMsgBlock Unexecuted instantiation: planValidator.c:vnodeIsMsgBlock Unexecuted instantiation: catalog.c:vnodeIsMsgBlock Unexecuted instantiation: ctgAsync.c:vnodeIsMsgBlock Unexecuted instantiation: ctgCache.c:vnodeIsMsgBlock Unexecuted instantiation: ctgDbg.c:vnodeIsMsgBlock Unexecuted instantiation: ctgRemote.c:vnodeIsMsgBlock Unexecuted instantiation: ctgRent.c:vnodeIsMsgBlock Unexecuted instantiation: ctgUtil.c:vnodeIsMsgBlock Unexecuted instantiation: extConnector.c:vnodeIsMsgBlock Unexecuted instantiation: extDialect.c:vnodeIsMsgBlock Unexecuted instantiation: extDialectDefaults.c:vnodeIsMsgBlock Unexecuted instantiation: functionMgt.c:vnodeIsMsgBlock Unexecuted instantiation: tudf.c:vnodeIsMsgBlock Unexecuted instantiation: builtins.c:vnodeIsMsgBlock Unexecuted instantiation: builtinsimpl.c:vnodeIsMsgBlock Unexecuted instantiation: spillDistinctSet.c:vnodeIsMsgBlock Unexecuted instantiation: thistogram.c:vnodeIsMsgBlock Unexecuted instantiation: tpercentile.c:vnodeIsMsgBlock Unexecuted instantiation: tavgfunction.c:vnodeIsMsgBlock Unexecuted instantiation: tminmax.c:vnodeIsMsgBlock Unexecuted instantiation: tminmaxavx.c:vnodeIsMsgBlock Unexecuted instantiation: filter.c:vnodeIsMsgBlock Unexecuted instantiation: scalar.c:vnodeIsMsgBlock Unexecuted instantiation: sclfunc.c:vnodeIsMsgBlock Unexecuted instantiation: sclvector.c:vnodeIsMsgBlock Unexecuted instantiation: nodesCloneFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesCodeFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesEqualFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesMatchFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesMsgFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesRemotePlanToSQL.c:vnodeIsMsgBlock Unexecuted instantiation: nodesToSQLFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesTraverseFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: nodesUtilFuncs.c:vnodeIsMsgBlock Unexecuted instantiation: extTypeMap.c:vnodeIsMsgBlock Unexecuted instantiation: queryUtil.c:vnodeIsMsgBlock Unexecuted instantiation: querymsg.c:vnodeIsMsgBlock Unexecuted instantiation: trans.c:vnodeIsMsgBlock Unexecuted instantiation: transCli.c:vnodeIsMsgBlock Unexecuted instantiation: transComm.c:vnodeIsMsgBlock Unexecuted instantiation: transSasl.c:vnodeIsMsgBlock Unexecuted instantiation: transSvr.c:vnodeIsMsgBlock Unexecuted instantiation: transTLS.c:vnodeIsMsgBlock Unexecuted instantiation: thttp.c:vnodeIsMsgBlock Unexecuted instantiation: geomFunc.c:vnodeIsMsgBlock Unexecuted instantiation: tconfig.c:vnodeIsMsgBlock Unexecuted instantiation: tdigest.c:vnodeIsMsgBlock Unexecuted instantiation: tlog.c:vnodeIsMsgBlock Unexecuted instantiation: tmempool.c:vnodeIsMsgBlock Unexecuted instantiation: tpagedbuf.c:vnodeIsMsgBlock Unexecuted instantiation: mpDirect.c:vnodeIsMsgBlock Unexecuted instantiation: extCapability.c:vnodeIsMsgBlock Unexecuted instantiation: systable.c:vnodeIsMsgBlock Unexecuted instantiation: tanalytics.c:vnodeIsMsgBlock Unexecuted instantiation: tdatablock.c:vnodeIsMsgBlock Unexecuted instantiation: tdataformat.c:vnodeIsMsgBlock Unexecuted instantiation: tglobal.c:vnodeIsMsgBlock Unexecuted instantiation: tmisce.c:vnodeIsMsgBlock Unexecuted instantiation: tname.c:vnodeIsMsgBlock Unexecuted instantiation: tpriv.c:vnodeIsMsgBlock Unexecuted instantiation: ttime.c:vnodeIsMsgBlock Unexecuted instantiation: tvariant.c:vnodeIsMsgBlock Unexecuted instantiation: streamMsg.c:vnodeIsMsgBlock Unexecuted instantiation: streamWindowPlan.c:vnodeIsMsgBlock Unexecuted instantiation: tmsg.c:vnodeIsMsgBlock Unexecuted instantiation: xnode.c:vnodeIsMsgBlock Unexecuted instantiation: tencrypt.c:vnodeIsMsgBlock Unexecuted instantiation: streamJson.c:vnodeIsMsgBlock Unexecuted instantiation: crypt.c:vnodeIsMsgBlock |
122 | | |
123 | 0 | static inline bool syncUtilUserCommit(tmsg_t msgType) { |
124 | 0 | return msgType != TDMT_SYNC_NOOP && msgType != TDMT_SYNC_LEADER_TRANSFER; |
125 | 0 | } Unexecuted instantiation: sql-fuzzer.c:syncUtilUserCommit Unexecuted instantiation: parser.c:syncUtilUserCommit Unexecuted instantiation: parTranslater.c:syncUtilUserCommit Unexecuted instantiation: parUtil.c:syncUtilUserCommit Unexecuted instantiation: parAstParser.c:syncUtilUserCommit Unexecuted instantiation: parAuthenticator.c:syncUtilUserCommit Unexecuted instantiation: parCalcConst.c:syncUtilUserCommit Unexecuted instantiation: parInsertSql.c:syncUtilUserCommit Unexecuted instantiation: parInsertUtil.c:syncUtilUserCommit Unexecuted instantiation: taos_lemon_sql.tab.c:syncUtilUserCommit Unexecuted instantiation: parAstCreater.c:syncUtilUserCommit Unexecuted instantiation: parInsertSml.c:syncUtilUserCommit Unexecuted instantiation: planner.c:syncUtilUserCommit Unexecuted instantiation: planLogicCreater.c:syncUtilUserCommit Unexecuted instantiation: planOptimizer.c:syncUtilUserCommit Unexecuted instantiation: planPhysiCreater.c:syncUtilUserCommit Unexecuted instantiation: planScaleOut.c:syncUtilUserCommit Unexecuted instantiation: planSpliter.c:syncUtilUserCommit Unexecuted instantiation: planUtil.c:syncUtilUserCommit Unexecuted instantiation: planValidator.c:syncUtilUserCommit Unexecuted instantiation: catalog.c:syncUtilUserCommit Unexecuted instantiation: ctgAsync.c:syncUtilUserCommit Unexecuted instantiation: ctgCache.c:syncUtilUserCommit Unexecuted instantiation: ctgDbg.c:syncUtilUserCommit Unexecuted instantiation: ctgRemote.c:syncUtilUserCommit Unexecuted instantiation: ctgRent.c:syncUtilUserCommit Unexecuted instantiation: ctgUtil.c:syncUtilUserCommit Unexecuted instantiation: extConnector.c:syncUtilUserCommit Unexecuted instantiation: extDialect.c:syncUtilUserCommit Unexecuted instantiation: extDialectDefaults.c:syncUtilUserCommit Unexecuted instantiation: functionMgt.c:syncUtilUserCommit Unexecuted instantiation: tudf.c:syncUtilUserCommit Unexecuted instantiation: builtins.c:syncUtilUserCommit Unexecuted instantiation: builtinsimpl.c:syncUtilUserCommit Unexecuted instantiation: spillDistinctSet.c:syncUtilUserCommit Unexecuted instantiation: thistogram.c:syncUtilUserCommit Unexecuted instantiation: tpercentile.c:syncUtilUserCommit Unexecuted instantiation: tavgfunction.c:syncUtilUserCommit Unexecuted instantiation: tminmax.c:syncUtilUserCommit Unexecuted instantiation: tminmaxavx.c:syncUtilUserCommit Unexecuted instantiation: filter.c:syncUtilUserCommit Unexecuted instantiation: scalar.c:syncUtilUserCommit Unexecuted instantiation: sclfunc.c:syncUtilUserCommit Unexecuted instantiation: sclvector.c:syncUtilUserCommit Unexecuted instantiation: nodesCloneFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesCodeFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesEqualFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesMatchFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesMsgFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesRemotePlanToSQL.c:syncUtilUserCommit Unexecuted instantiation: nodesToSQLFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesTraverseFuncs.c:syncUtilUserCommit Unexecuted instantiation: nodesUtilFuncs.c:syncUtilUserCommit Unexecuted instantiation: extTypeMap.c:syncUtilUserCommit Unexecuted instantiation: queryUtil.c:syncUtilUserCommit Unexecuted instantiation: querymsg.c:syncUtilUserCommit Unexecuted instantiation: trans.c:syncUtilUserCommit Unexecuted instantiation: transCli.c:syncUtilUserCommit Unexecuted instantiation: transComm.c:syncUtilUserCommit Unexecuted instantiation: transSasl.c:syncUtilUserCommit Unexecuted instantiation: transSvr.c:syncUtilUserCommit Unexecuted instantiation: transTLS.c:syncUtilUserCommit Unexecuted instantiation: thttp.c:syncUtilUserCommit Unexecuted instantiation: geomFunc.c:syncUtilUserCommit Unexecuted instantiation: tconfig.c:syncUtilUserCommit Unexecuted instantiation: tdigest.c:syncUtilUserCommit Unexecuted instantiation: tlog.c:syncUtilUserCommit Unexecuted instantiation: tmempool.c:syncUtilUserCommit Unexecuted instantiation: tpagedbuf.c:syncUtilUserCommit Unexecuted instantiation: mpDirect.c:syncUtilUserCommit Unexecuted instantiation: extCapability.c:syncUtilUserCommit Unexecuted instantiation: systable.c:syncUtilUserCommit Unexecuted instantiation: tanalytics.c:syncUtilUserCommit Unexecuted instantiation: tdatablock.c:syncUtilUserCommit Unexecuted instantiation: tdataformat.c:syncUtilUserCommit Unexecuted instantiation: tglobal.c:syncUtilUserCommit Unexecuted instantiation: tmisce.c:syncUtilUserCommit Unexecuted instantiation: tname.c:syncUtilUserCommit Unexecuted instantiation: tpriv.c:syncUtilUserCommit Unexecuted instantiation: ttime.c:syncUtilUserCommit Unexecuted instantiation: tvariant.c:syncUtilUserCommit Unexecuted instantiation: streamMsg.c:syncUtilUserCommit Unexecuted instantiation: streamWindowPlan.c:syncUtilUserCommit Unexecuted instantiation: tmsg.c:syncUtilUserCommit Unexecuted instantiation: xnode.c:syncUtilUserCommit Unexecuted instantiation: tencrypt.c:syncUtilUserCommit Unexecuted instantiation: streamJson.c:syncUtilUserCommit Unexecuted instantiation: crypt.c:syncUtilUserCommit |
126 | | |
127 | | /* ------------------------ OTHER DEFINITIONS ------------------------ */ |
128 | | // IE type |
129 | | #define TSDB_IE_TYPE_SEC 1 |
130 | | #define TSDB_IE_TYPE_META 2 |
131 | | #define TSDB_IE_TYPE_MGMT_IP 3 |
132 | | #define TSDB_IE_TYPE_DNODE_CFG 4 |
133 | | #define TSDB_IE_TYPE_NEW_VERSION 5 |
134 | | #define TSDB_IE_TYPE_DNODE_EXT 6 |
135 | | #define TSDB_IE_TYPE_DNODE_STATE 7 |
136 | | |
137 | | enum { |
138 | | CONN_TYPE__QUERY = 1, |
139 | | CONN_TYPE__TMQ, |
140 | | CONN_TYPE__UDFD, |
141 | | CONN_TYPE__AUTH_TEST, // only for test authentication |
142 | | CONN_TYPE__MAX, |
143 | | }; |
144 | | |
145 | | enum { |
146 | | HEARTBEAT_KEY_USER_AUTHINFO = 1, |
147 | | HEARTBEAT_KEY_DBINFO, |
148 | | HEARTBEAT_KEY_STBINFO, |
149 | | HEARTBEAT_KEY_TMQ, |
150 | | HEARTBEAT_KEY_DYN_VIEW, |
151 | | HEARTBEAT_KEY_VIEWINFO, |
152 | | HEARTBEAT_KEY_TSMA, |
153 | | HEARTBEAT_KEY_TXN_KEEPALIVE, |
154 | | HEARTBEAT_KEY_TXN_KILLED, // MNode -> client: txn was forcibly rolled back due to inactivity timeout |
155 | | HEARTBEAT_KEY_EXTSOURCE, // federated query: external source change notifications |
156 | | }; |
157 | | |
158 | | typedef enum _mgmt_table { |
159 | | TSDB_MGMT_TABLE_START, |
160 | | TSDB_MGMT_TABLE_DNODE, |
161 | | TSDB_MGMT_TABLE_MNODE, |
162 | | TSDB_MGMT_TABLE_MODULE, |
163 | | TSDB_MGMT_TABLE_QNODE, |
164 | | TSDB_MGMT_TABLE_SNODE, |
165 | | TSDB_MGMT_TABLE_BACKUP_NODE, // no longer used |
166 | | TSDB_MGMT_TABLE_CLUSTER, |
167 | | TSDB_MGMT_TABLE_DB, |
168 | | TSDB_MGMT_TABLE_FUNC, |
169 | | TSDB_MGMT_TABLE_INDEX, |
170 | | TSDB_MGMT_TABLE_STB, |
171 | | TSDB_MGMT_TABLE_STREAMS, |
172 | | TSDB_MGMT_TABLE_TABLE, |
173 | | TSDB_MGMT_TABLE_TAG, |
174 | | TSDB_MGMT_TABLE_COL, |
175 | | TSDB_MGMT_TABLE_USER, |
176 | | TSDB_MGMT_TABLE_GRANTS, |
177 | | TSDB_MGMT_TABLE_VGROUP, |
178 | | TSDB_MGMT_TABLE_TOPICS, |
179 | | TSDB_MGMT_TABLE_CONSUMERS, |
180 | | TSDB_MGMT_TABLE_SUBSCRIPTIONS, |
181 | | TSDB_MGMT_TABLE_TRANS, |
182 | | TSDB_MGMT_TABLE_SMAS, |
183 | | TSDB_MGMT_TABLE_CONFIGS, |
184 | | TSDB_MGMT_TABLE_CONNS, |
185 | | TSDB_MGMT_TABLE_QUERIES, |
186 | | TSDB_MGMT_TABLE_VNODES, |
187 | | TSDB_MGMT_TABLE_APPS, |
188 | | TSDB_MGMT_TABLE_STREAM_TASKS, |
189 | | TSDB_MGMT_TABLE_STREAM_RECALCULATES, |
190 | | TSDB_MGMT_TABLE_PRIVILEGES, |
191 | | TSDB_MGMT_TABLE_VIEWS, |
192 | | TSDB_MGMT_TABLE_TSMAS, |
193 | | TSDB_MGMT_TABLE_COMPACT, |
194 | | TSDB_MGMT_TABLE_COMPACT_DETAIL, |
195 | | TSDB_MGMT_TABLE_GRANTS_FULL, |
196 | | TSDB_MGMT_TABLE_GRANTS_LOGS, |
197 | | TSDB_MGMT_TABLE_MACHINES, |
198 | | TSDB_MGMT_TABLE_ARBGROUP, |
199 | | TSDB_MGMT_TABLE_ENCRYPTIONS, |
200 | | TSDB_MGMT_TABLE_USER_FULL, |
201 | | TSDB_MGMT_TABLE_ANODE, |
202 | | TSDB_MGMT_TABLE_ANODE_FULL, |
203 | | TSDB_MGMT_TABLE_USAGE, |
204 | | TSDB_MGMT_TABLE_FILESETS, |
205 | | TSDB_MGMT_TABLE_TRANSACTION_DETAIL, |
206 | | TSDB_MGMT_TABLE_SNAP_SEND_VNODES, |
207 | | TSDB_MGMT_TABLE_SNAP_SEND_FILESETS, |
208 | | TSDB_MGMT_TABLE_VC_COL, |
209 | | TSDB_MGMT_TABLE_BNODE, |
210 | | TSDB_MGMT_TABLE_MOUNT, |
211 | | TSDB_MGMT_TABLE_SSMIGRATE, |
212 | | TSDB_MGMT_TABLE_SCAN, |
213 | | TSDB_MGMT_TABLE_SCAN_DETAIL, |
214 | | TSDB_MGMT_TABLE_RSMA, |
215 | | TSDB_MGMT_TABLE_RETENTION, |
216 | | TSDB_MGMT_TABLE_RETENTION_DETAIL, |
217 | | TSDB_MGMT_TABLE_INSTANCE, |
218 | | TSDB_MGMT_TABLE_ENCRYPT_ALGORITHMS, |
219 | | TSDB_MGMT_TABLE_TOKEN, |
220 | | TSDB_MGMT_TABLE_ENCRYPT_STATUS, |
221 | | TSDB_MGMT_TABLE_ROLE, |
222 | | TSDB_MGMT_TABLE_ROLE_PRIVILEGES, |
223 | | TSDB_MGMT_TABLE_ROLE_COL_PRIVILEGES, |
224 | | TSDB_MGMT_TABLE_XNODES, |
225 | | TSDB_MGMT_TABLE_XNODE_TASKS, |
226 | | TSDB_MGMT_TABLE_XNODE_AGENTS, |
227 | | TSDB_MGMT_TABLE_XNODE_JOBS, |
228 | | TSDB_MGMT_TABLE_XNODE_FULL, |
229 | | TSDB_MGMT_TABLE_VIRTUAL_TABLES_REFERENCING, |
230 | | TSDB_MGMT_TABLE_SECURITY_POLICIES, |
231 | | TSDB_MGMT_TABLE_EXT_SOURCES, |
232 | | TSDB_MGMT_TABLE_TXN_LOG, |
233 | | TSDB_MGMT_TABLE_TXN_ORPHANS, |
234 | | TSDB_MGMT_TABLE_VSTABLE_INHERITS, |
235 | | TSDB_MGMT_TABLE_BACKUP, |
236 | | TSDB_MGMT_TABLE_MAX, |
237 | | } EShowType; |
238 | | |
239 | | typedef enum EExtSourceType { |
240 | | EXT_SOURCE_MYSQL = 0, |
241 | | EXT_SOURCE_POSTGRESQL = 1, |
242 | | EXT_SOURCE_INFLUXDB = 2, |
243 | | EXT_SOURCE_TDENGINE = 3, // reserved, not delivered in Phase 1 |
244 | | EXT_SOURCE_SQLSERVER = 4, // Microsoft SQL Server (ODBC); appended, never reorder/reuse |
245 | | } EExtSourceType; |
246 | | |
247 | | // Federated pushdown demotion granularity. |
248 | | typedef enum EExtCapDemoteKind { |
249 | | EXT_DEMOTE_KIND_NONE = 0, |
250 | | EXT_DEMOTE_KIND_FUNC, |
251 | | EXT_DEMOTE_KIND_OP, |
252 | | EXT_DEMOTE_KIND_CLAUSE, |
253 | | EXT_DEMOTE_KIND_TYPE, |
254 | | } EExtCapDemoteKind; |
255 | | |
256 | | typedef enum EExtDemoteReason { |
257 | | // Precise reasons (catalog-level demotion candidates) |
258 | | EXT_DEMOTE_REASON_REMOTE_FUNC_MISS = 1, |
259 | | EXT_DEMOTE_REASON_REMOTE_SYNTAX_PRECISE = 2, |
260 | | EXT_DEMOTE_REASON_REMOTE_TYPE_MISMATCH = 3, |
261 | | |
262 | | // Vague reasons (session overlay only) |
263 | | EXT_DEMOTE_REASON_REMOTE_SYNTAX_VAGUE = 10, |
264 | | EXT_DEMOTE_REASON_REMOTE_TIMEOUT, |
265 | | EXT_DEMOTE_REASON_REMOTE_INTERNAL, |
266 | | EXT_DEMOTE_REASON_REMOTE_NETWORK, |
267 | | EXT_DEMOTE_REASON_REMOTE_UNKNOWN, |
268 | | |
269 | | EXT_DEMOTE_REASON_RETRY_ESCALATION = 20, |
270 | | EXT_DEMOTE_REASON_DIALECT_BASELINE = 30, |
271 | | EXT_DEMOTE_REASON_USER_FORCED = 40, |
272 | | } EExtDemoteReason; |
273 | | |
274 | | #define EXT_REASON_IS_PRECISE(reasonCode) ((reasonCode) >= 1 && (reasonCode) <= 9) |
275 | | |
276 | | typedef enum EExtClauseKind { |
277 | | // -- GATE ------------------------------------------------------------------ |
278 | | // These 6 values participate in the full 3-level pushdown fallback: |
279 | | // * classifiable from remote error responses (via extResolveFuncClause / |
280 | | // extResolveOpClause escalation or explicit clause=N token in errors) |
281 | | // * support dynamic disable at runtime (catalog-level or session overlay) |
282 | | // * planner gates on each: a disabled GATE prevents pushdown of queries |
283 | | // that exercise that capability |
284 | | // * extCapShouldUseBaseline() checks all 6: if every GATE is disabled |
285 | | // the system falls back to TDengine-local execution (baseline mode) |
286 | | EXT_CLAUSE_FILTER = 0, // WHERE predicates (comparisons, LIKE, MATCH, ...) |
287 | | EXT_CLAUSE_PROJECTION, // SELECT expressions (scalar functions, casts, ...) |
288 | | EXT_CLAUSE_AGG, // GROUP BY / aggregate functions |
289 | | EXT_CLAUSE_ORDER, // ORDER BY |
290 | | EXT_CLAUSE_LIMIT, // LIMIT / FETCH FIRST |
291 | | EXT_CLAUSE_JOIN, // any join (coarse gate; covers all join subtypes) |
292 | | |
293 | | // -- STATIC ---------------------------------------------------------------- |
294 | | // These values are set only via dialect defaults (extLoadDialectDefaults) |
295 | | // or explicit manual SQL (ALTER EXTERNAL SOURCE ... DISABLE CLAUSE ...). |
296 | | // They are NOT produced by error classification and do NOT trigger the |
297 | | // pushdown fallback machinery. They serve as fine-grained capability |
298 | | // markers for display (SHOW EXTERNAL SOURCES) and for dialect-specific |
299 | | // default configurations. |
300 | | EXT_CLAUSE_GROUP_ROLLUP, // GROUP BY ROLLUP (dialect default) |
301 | | EXT_CLAUSE_HAVING, // HAVING clause (fine-grained AGG subtype) |
302 | | EXT_CLAUSE_ORDER_NULLS_FIRST, // NULLS FIRST ordering (MySQL default: disabled) |
303 | | EXT_CLAUSE_ORDER_NULLS_LAST, // NULLS LAST ordering (MySQL default: disabled) |
304 | | EXT_CLAUSE_OFFSET, // OFFSET keyword |
305 | | EXT_CLAUSE_DISTINCT, // SELECT DISTINCT |
306 | | // JOIN subtypes - dialect defaults only; disabling any subtype must also |
307 | | // explicitly disable the parent EXT_CLAUSE_JOIN gate in the defaults table. |
308 | | EXT_CLAUSE_INNER_JOIN, |
309 | | EXT_CLAUSE_LEFT_JOIN, |
310 | | EXT_CLAUSE_RIGHT_JOIN, |
311 | | EXT_CLAUSE_FULL_OUTER_JOIN, |
312 | | EXT_CLAUSE_SEMI_JOIN, |
313 | | EXT_CLAUSE_ANTI_JOIN, |
314 | | EXT_CLAUSE_FROM_SUBQUERY, // subquery in FROM (common default: disabled) |
315 | | EXT_CLAUSE_SCALAR_SUBQUERY, // scalar subquery in SELECT (common default: disabled) |
316 | | EXT_CLAUSE_INTERVAL_TUMBLING, // TDengine INTERVAL(...) tumbling window |
317 | | EXT_CLAUSE_INTERVAL_SLIDING, // TDengine INTERVAL(...) SLIDING window |
318 | | EXT_CLAUSE_PARTITION_TBNAME, // PARTITION BY tbname |
319 | | EXT_CLAUSE_PARTITION_COLUMN, // PARTITION BY <column> |
320 | | // SQL feature flags - set in common/dialect defaults; no error-based demote. |
321 | | EXT_CLAUSE_FEAT_CTE, // WITH (common table expressions; common default: disabled) |
322 | | EXT_CLAUSE_FEAT_WINDOW_FUNCTIONS, // window functions (common default: disabled) |
323 | | EXT_CLAUSE_FEAT_LARGE_IN_LIST, // remote handles large IN (v1,...,vN) lists (common default: disabled) |
324 | | // Subquery expression types - dialect defaults only. |
325 | | // EXISTS/NOT EXISTS are tracked at the operator layer (disabledOps). |
326 | | EXT_CLAUSE_IN_SUBQUERY, // IN/NOT IN (subquery) - InfluxDB default: disabled |
327 | | EXT_CLAUSE_ALL_ANY_SUBQUERY, // ALL/ANY/SOME subquery - InfluxDB default: disabled |
328 | | // Additional JOIN subtypes - always local for all current dialects. |
329 | | // Disabling these does not require disabling the parent EXT_CLAUSE_JOIN gate |
330 | | // because they are never pushed down regardless. |
331 | | EXT_CLAUSE_ASOF_JOIN, // ASOF Join - always local (common default: disabled) |
332 | | EXT_CLAUSE_WINDOW_JOIN, // Window Join - always local (common default: disabled) |
333 | | // TDengine-specific window types - always local for all current dialects. |
334 | | // (INTERVAL tumbling/sliding are above; state/session/event/count are below.) |
335 | | EXT_CLAUSE_STATE_WINDOW, // STATE_WINDOW - always local (common default: disabled) |
336 | | EXT_CLAUSE_SESSION_WINDOW, // SESSION - always local (common default: disabled) |
337 | | EXT_CLAUSE_EVENT_WINDOW, // EVENT_WINDOW - always local (common default: disabled) |
338 | | EXT_CLAUSE_COUNT_WINDOW, // COUNT_WINDOW - always local (common default: disabled) |
339 | | // TDengine-specific sub-clauses - always local for all current dialects. |
340 | | EXT_CLAUSE_FILL, // FILL clause (window fill) - always local (common default: disabled) |
341 | | EXT_CLAUSE_INTERP, // INTERP + RANGE/EVERY - always local (common default: disabled) |
342 | | EXT_CLAUSE_SLIMIT, // SLIMIT/SOFFSET (per-partition limit) - always local (common default: disabled) |
343 | | EXT_CLAUSE_EXISTS_SUBQUERY, // EXISTS/NOT EXISTS (subquery) - InfluxDB default: disabled |
344 | | |
345 | | EXT_CLAUSE_MAX, |
346 | | } EExtClauseKind; |
347 | | |
348 | | // FQ subquery render mode (v2 two-state pushdown model). Decided in the |
349 | | // collect phase, carried on each REMOTE_* node, consumed by nodesRemotePlanToSQL. |
350 | | // FQ_SUBQ_RENDER_DIRECT_SQL - clause directly pushable AND inner SELECT needs |
351 | | // no transform: inline the user's original SQL. |
352 | | // FQ_SUBQ_RENDER_ORIG_TYPE_2B - keep the original predicate form (IN/ALL/ANY/ |
353 | | // EXISTS) but render the inner SELECT with dialect |
354 | | // transforms (function mapping, federated-name -> |
355 | | // schema/db/remoteTableName translation). |
356 | | typedef enum EFqSubqRenderMode { |
357 | | FQ_SUBQ_RENDER_DIRECT_SQL = 0, |
358 | | FQ_SUBQ_RENDER_ORIG_TYPE_2B, |
359 | | } EFqSubqRenderMode; |
360 | | |
361 | | typedef struct SExtCapDisabledEntry { |
362 | | uint8_t reasonCode; |
363 | | uint16_t hitCount; |
364 | | int64_t firstHitMs; |
365 | | } SExtCapDisabledEntry; |
366 | | |
367 | | typedef struct SExtCapDemoteSpec { |
368 | | EExtCapDemoteKind kind; |
369 | | union { |
370 | | char funcName[TSDB_FUNC_NAME_LEN]; |
371 | | EOperatorType opType; |
372 | | EExtClauseKind clauseKind; |
373 | | int8_t tsdbTypeCode; |
374 | | } detail; |
375 | | uint8_t reasonCode; |
376 | | } SExtCapDemoteSpec; |
377 | | |
378 | | typedef struct SExtPushdownDiagnostic { |
379 | | int32_t classifiedCode; |
380 | | EExtDemoteReason reasonCode; |
381 | | EExtCapDemoteKind suggestedDemoteKind; |
382 | | union { |
383 | | char funcName[TSDB_FUNC_NAME_LEN]; |
384 | | EOperatorType opType; |
385 | | EExtClauseKind clauseKind; |
386 | | int8_t tsdbTypeCode; |
387 | | } detail; |
388 | | char remoteSqlState[8]; |
389 | | int32_t remoteCode; |
390 | | int32_t httpStatus; |
391 | | char remoteMessage[512]; |
392 | | char generatedSql[2048]; |
393 | | } SExtPushdownDiagnostic; |
394 | | |
395 | 0 | #define EXT_MAX_PUSHDOWN_ATTEMPTS 3 |
396 | | |
397 | | // Length constants for external source connection fields. |
398 | | // External source names follow the same rules as database names (globally unique, must not |
399 | | // conflict with local DB names), so the name length is capped at TSDB_DB_NAME_LEN (64 + NUL). |
400 | 0 | #define TSDB_EXT_SOURCE_NAME_LEN TSDB_DB_NAME_LEN // max external source name length (64 chars + NUL) |
401 | 0 | #define TSDB_EXT_SOURCE_HOST_LEN 257 // max hostname/IP length (256 chars + NUL) |
402 | | // External DB usernames can be longer than TDengine usernames (TSDB_USER_LEN=24). |
403 | | // MySQL max=32, PostgreSQL max=63; we use 128 for future-proofing. |
404 | 0 | #define TSDB_EXT_SOURCE_USER_LEN 129 // max external source username (128 chars + NUL) |
405 | | // External DB passwords are stored as plaintext on the wire then AES-encrypted at rest. |
406 | | // AES-CBC PKCS7: for 128-char plaintext, taes_encrypt_len(128)=144 (extra PKCS7 block). |
407 | 0 | #define TSDB_EXT_SOURCE_PASSWORD_LEN 129 // max plaintext password (128 chars + NUL, transport only) |
408 | 0 | #define TSDB_EXT_SOURCE_ENC_PASSWORD_LEN 144 // AES-CBC-encrypted password storage size |
409 | | // External DB names (database/schema): MySQL max=64, PG max=63; TSDB_DB_NAME_LEN=65 is sufficient. |
410 | 0 | #define TSDB_EXT_SOURCE_DATABASE_LEN TSDB_DB_NAME_LEN // max default database name (64 chars + NUL) |
411 | 0 | #define TSDB_EXT_SOURCE_SCHEMA_LEN TSDB_DB_NAME_LEN // max default schema name (64 chars + NUL) |
412 | | // OPTIONS key names (e.g. "tls_enabled", "api_token"): reuse column-name length (64 chars). |
413 | 0 | #define TSDB_EXT_SOURCE_OPTION_KEY_LEN TSDB_COL_NAME_LEN // max option key length (64 chars + NUL) |
414 | | // Full OPTIONS JSON storage budget (includes keys + values + JSON syntax chars). |
415 | 0 | #define TSDB_EXT_SOURCE_OPTIONS_LEN 8192 |
416 | | // A single option value budget (value length boundary remains 4095 chars). |
417 | 0 | #define TSDB_EXT_SOURCE_OPTION_VALUE_LEN 4096 |
418 | | |
419 | | // SExtSourceCapability - push-down ability flags for an external source. |
420 | | // Defined here (tmsg.h) so that SExtSourceInfo below and extConnector.h both |
421 | | // share the same declaration without a circular-include. |
422 | | typedef struct SExtSourceCapability { |
423 | | SHashObj* disabledFuncs; // key: lowercase function name |
424 | | SHashObj* disabledOps; // key: EOperatorType |
425 | | SHashObj* disabledTypes; // key: int8_t (TSDB_DATA_TYPE_*) |
426 | | SHashObj* disabledClauses; // key: EExtClauseKind |
427 | | int32_t dialect; |
428 | | int64_t loadedAtMs; |
429 | | } SExtSourceCapability; |
430 | | |
431 | | typedef struct SExtCapSessionOverlay { |
432 | | SHashObj* disabledFuncs; |
433 | | SHashObj* disabledOps; |
434 | | SHashObj* disabledTypes; |
435 | | SHashObj* disabledClauses; |
436 | | int32_t attemptCount; |
437 | | EExtCapDemoteKind lastDemoteKind; |
438 | | union { |
439 | | char funcName[TSDB_FUNC_NAME_LEN]; |
440 | | EOperatorType opType; |
441 | | EExtClauseKind clauseKind; |
442 | | int8_t tsdbTypeCode; |
443 | | } lastDemoteDetail; |
444 | | uint8_t repeatFailCount; |
445 | | } SExtCapSessionOverlay; |
446 | | |
447 | | int32_t extCapInit(SExtSourceCapability* pCap); |
448 | | void extCapDestroy(SExtSourceCapability* pCap); |
449 | | int32_t extCapClone(const SExtSourceCapability* pSrc, SExtSourceCapability* pDst); |
450 | | |
451 | | int32_t extCapSessionOverlayInit(SExtCapSessionOverlay* pOverlay); |
452 | | void extCapSessionOverlayDestroy(SExtCapSessionOverlay* pOverlay); |
453 | | int32_t extCapSessionOverlayClone(const SExtCapSessionOverlay* pSrc, SExtCapSessionOverlay* pDst); |
454 | | |
455 | | bool capDisabled(const SExtSourceCapability* pCap, const SExtCapSessionOverlay* pOverlay, |
456 | | EExtCapDemoteKind kind, const void* pKey); |
457 | | int32_t extCapDemoteApply(SExtSourceCapability* pCap, const SExtCapDemoteSpec* pSpec); |
458 | | int32_t extCapOverlayDemote(SExtCapSessionOverlay* pOverlay, const SExtCapDemoteSpec* pSpec); |
459 | | bool extCapOverlayTryEscalateOnRepeat(SExtCapSessionOverlay* pOverlay, const SExtCapDemoteSpec* pCurrent, |
460 | | SExtCapDemoteSpec* pEscalated); |
461 | | void extCapOverlayMarkAllCoarse(SExtCapSessionOverlay* pOverlay, uint8_t reasonCode); |
462 | | bool extCapShouldUseBaseline(const SExtSourceCapability* pCap, const SExtCapSessionOverlay* pOverlay); |
463 | | |
464 | | EExtClauseKind extResolveFuncClause(const char* funcName); |
465 | | EExtClauseKind extResolveOpClause(EOperatorType opType); |
466 | | bool extClauseIsGate(EExtClauseKind kind); |
467 | | |
468 | | int32_t tEncodeSExtPushdownDiagnostic(SEncoder* pEncoder, const SExtPushdownDiagnostic* pDiag); |
469 | | int32_t tDecodeSExtPushdownDiagnostic(SDecoder* pDecoder, SExtPushdownDiagnostic* pDiag); |
470 | | // EExtSQLDialect - SQL dialect selector for remote SQL generation. |
471 | | // Defined here (alongside EExtSourceType) so that nodes/plannodes.h can reference |
472 | | // it without including extConnector.h, breaking the nodes -> extconnector dependency. |
473 | | typedef enum EExtSQLDialect { |
474 | | EXT_SQL_DIALECT_MYSQL = 0, |
475 | | EXT_SQL_DIALECT_POSTGRES = 1, |
476 | | EXT_SQL_DIALECT_INFLUXQL = 2, |
477 | | EXT_SQL_DIALECT_SQLSERVER = 3, // appended, never reorder/reuse |
478 | | } EExtSQLDialect; |
479 | | |
480 | | // Declared width (in characters) used for InfluxDB tag columns, both when the |
481 | | // ext reader fetches tag values at runtime (streamReaderExt.c's |
482 | | // extInitInfluxTagPartition / fetchDataBatchInflux column-type mappings) and |
483 | | // when the stream parser auto-derives an output TAG from a PARTITION BY tag |
484 | | // column (parTranslater.c's createStreamReqSetDefaultTag). Keeping both sides |
485 | | // on this single constant prevents them drifting apart - InfluxDB tags have no |
486 | | // declared TDengine-side width, so the two call sites must agree on one. |
487 | 0 | #define EXT_INFLUX_TAG_NCHAR_CHARS (257 * TSDB_NCHAR_SIZE + VARSTR_HEADER_SIZE) |
488 | | #define EXT_INFLUX_KEY_NCHAR_CHARS ((TSDB_COL_NAME_LEN - 1) * TSDB_NCHAR_SIZE) |
489 | | #define EXT_INFLUX_KEY_NCHAR_CHARS_TOO_LONG (TSDB_COL_NAME_LEN * TSDB_NCHAR_SIZE) |
490 | | |
491 | | // -- FQ push-down capability bitmap ------------------------------------------ |
492 | | // uint16_t bitmap encoding: |
493 | | // bits [2:0] - default capability per dialect (0 = not pushable) |
494 | | // bits [5:3] - session-level override (1 = force-disable for that dialect) |
495 | | // |
496 | | // fqPushCap bitmap layout (uint16_t): |
497 | | // |
498 | | // Low byte (bits 0-7) - static/global capability defaults |
499 | | // High byte (bits 8-15) - session-level overrides (set to force-disable) |
500 | | // |
501 | | // The high byte mirrors the low byte: each bit in the high byte disables the |
502 | | // corresponding bit position in the low byte at session level. |
503 | | // |
504 | | // Low-byte layout: |
505 | | // bits 0-2 : main capability (MySQL=bit0, PG=bit1, Influx=bit2) |
506 | | // bits 3-5 : sub-cap 1: CAST(timestamp -> integer) |
507 | | // bit 6 : main capability - SQL Server (appended; see the note below) |
508 | | // bit 7 : reserved for future sub-capabilities |
509 | | // |
510 | | // High-byte layout (FQ_CAP_SESSION_SHIFT = 8): |
511 | | // bits 8-10 : session override for main capability |
512 | | // bits 11-13: session override for CAST(ts->int) sub-capability |
513 | | // bit 14 : session override for SQL Server |
514 | | // bit 15 : reserved |
515 | | // |
516 | | // SQL Server placement note: the 4th main-capability bit sits at bit 6, not at |
517 | | // bit 3, because bits 3-5 form the shift-derived CAST(ts->int) band shared by |
518 | | // the first three dialects; `fqDialectBit(SQLSERVER) << FQ_CAP_CAST_TS_INT_SHIFT` |
519 | | // (bit 9) would collide with the PG session-override bit. SQL Server therefore |
520 | | // does NOT take part in the shift-derived sub-capability band: code that derives |
521 | | // a sub-capability bit must special-case it (SQL Server has no such sub-capability |
522 | | // today; return FQ_CAP_NONE). |
523 | | |
524 | | // Main capability bits (low byte, bits 0-2): |
525 | 0 | #define FQ_CAP_MYSQL ((uint16_t)(1u << 0)) // MySQL / MariaDB |
526 | 0 | #define FQ_CAP_PG ((uint16_t)(1u << 1)) // PostgreSQL |
527 | 0 | #define FQ_CAP_INFLUX ((uint16_t)(1u << 2)) // InfluxDB v3 (DataFusion) |
528 | 0 | #define FQ_CAP_SQLSERVER ((uint16_t)(1u << 6)) // SQL Server (ODBC); appended, see layout note |
529 | | #define FQ_CAP_ALL ((uint16_t)(FQ_CAP_MYSQL | FQ_CAP_PG | FQ_CAP_INFLUX)) |
530 | | |
531 | | // Session-override band: high byte (shift = 8). |
532 | | // Set a bit here to force-disable the corresponding dialect at session level. |
533 | 0 | #define FQ_CAP_SESSION_SHIFT 8 |
534 | | #define FQ_CAP_SESSION_MYSQL ((uint16_t)(FQ_CAP_MYSQL << FQ_CAP_SESSION_SHIFT)) |
535 | | #define FQ_CAP_SESSION_PG ((uint16_t)(FQ_CAP_PG << FQ_CAP_SESSION_SHIFT)) |
536 | | #define FQ_CAP_SESSION_INFLUX ((uint16_t)(FQ_CAP_INFLUX << FQ_CAP_SESSION_SHIFT)) |
537 | | #define FQ_CAP_SESSION_SQLSERVER ((uint16_t)(FQ_CAP_SQLSERVER << FQ_CAP_SESSION_SHIFT)) |
538 | | |
539 | | // Convenience: the dialect combinations used in the capability tables |
540 | | #define FQ_CAP_PG_INFLUX ((uint16_t)(FQ_CAP_PG | FQ_CAP_INFLUX)) |
541 | | #define FQ_CAP_MYSQL_PG ((uint16_t)(FQ_CAP_MYSQL | FQ_CAP_PG)) |
542 | 0 | #define FQ_CAP_NONE ((uint16_t)0) |
543 | | |
544 | | // Sub-capability 1: CAST(timestamp AS integer/bigint/uint/ubigint) |
545 | | // default band : bits 3-5 (FQ_CAP_CAST_TS_INT_SHIFT = 3) |
546 | | // session band : bits 11-13 (= FQ_CAP_CAST_TS_INT_SHIFT + FQ_CAP_SESSION_SHIFT = 3+8) |
547 | | // |
548 | | // Only PostgreSQL supports CAST(timestamp -> integer) natively. |
549 | | // MySQL : binary protocol returns MYSQL_TIME for TIMESTAMP; connector cannot safely |
550 | | // reinterpret that as an integer epoch, so local conversion is required. |
551 | | // InfluxDB: DataFusion does not support CAST(timestamp AS BIGINT). |
552 | 0 | #define FQ_CAP_CAST_TS_INT_SHIFT 3 |
553 | | #define FQ_CAP_CAST_TS_INT_PG ((uint16_t)(FQ_CAP_PG << FQ_CAP_CAST_TS_INT_SHIFT)) |
554 | | // Session-level overrides for the CAST(ts->int) sub-capability: |
555 | | #define FQ_CAP_CAST_TS_INT_SESSION_MYSQL ((uint16_t)(FQ_CAP_MYSQL << (FQ_CAP_CAST_TS_INT_SHIFT + FQ_CAP_SESSION_SHIFT))) |
556 | | #define FQ_CAP_CAST_TS_INT_SESSION_PG ((uint16_t)(FQ_CAP_PG << (FQ_CAP_CAST_TS_INT_SHIFT + FQ_CAP_SESSION_SHIFT))) |
557 | | #define FQ_CAP_CAST_TS_INT_SESSION_INFLUX ((uint16_t)(FQ_CAP_INFLUX << (FQ_CAP_CAST_TS_INT_SHIFT + FQ_CAP_SESSION_SHIFT))) |
558 | | |
559 | | // Convert EExtSQLDialect to the corresponding FQ_CAP_* default bit. |
560 | | // Returns 0 for unknown dialects. |
561 | 0 | static inline uint16_t fqDialectBit(int32_t dialect) { |
562 | 0 | switch ((EExtSQLDialect)dialect) { |
563 | 0 | case EXT_SQL_DIALECT_MYSQL: return FQ_CAP_MYSQL; |
564 | 0 | case EXT_SQL_DIALECT_POSTGRES: return FQ_CAP_PG; |
565 | 0 | case EXT_SQL_DIALECT_INFLUXQL: return FQ_CAP_INFLUX; |
566 | 0 | case EXT_SQL_DIALECT_SQLSERVER: return FQ_CAP_SQLSERVER; |
567 | 0 | default: return 0; |
568 | 0 | } |
569 | 0 | } Unexecuted instantiation: sql-fuzzer.c:fqDialectBit Unexecuted instantiation: parser.c:fqDialectBit Unexecuted instantiation: parTranslater.c:fqDialectBit Unexecuted instantiation: parUtil.c:fqDialectBit Unexecuted instantiation: parAstParser.c:fqDialectBit Unexecuted instantiation: parAuthenticator.c:fqDialectBit Unexecuted instantiation: parCalcConst.c:fqDialectBit Unexecuted instantiation: parInsertSql.c:fqDialectBit Unexecuted instantiation: parInsertUtil.c:fqDialectBit Unexecuted instantiation: taos_lemon_sql.tab.c:fqDialectBit Unexecuted instantiation: parAstCreater.c:fqDialectBit Unexecuted instantiation: parInsertSml.c:fqDialectBit Unexecuted instantiation: planner.c:fqDialectBit Unexecuted instantiation: planLogicCreater.c:fqDialectBit Unexecuted instantiation: planOptimizer.c:fqDialectBit Unexecuted instantiation: planPhysiCreater.c:fqDialectBit Unexecuted instantiation: planScaleOut.c:fqDialectBit Unexecuted instantiation: planSpliter.c:fqDialectBit Unexecuted instantiation: planUtil.c:fqDialectBit Unexecuted instantiation: planValidator.c:fqDialectBit Unexecuted instantiation: catalog.c:fqDialectBit Unexecuted instantiation: ctgAsync.c:fqDialectBit Unexecuted instantiation: ctgCache.c:fqDialectBit Unexecuted instantiation: ctgDbg.c:fqDialectBit Unexecuted instantiation: ctgRemote.c:fqDialectBit Unexecuted instantiation: ctgRent.c:fqDialectBit Unexecuted instantiation: ctgUtil.c:fqDialectBit Unexecuted instantiation: extConnector.c:fqDialectBit Unexecuted instantiation: extDialect.c:fqDialectBit Unexecuted instantiation: extDialectDefaults.c:fqDialectBit Unexecuted instantiation: functionMgt.c:fqDialectBit Unexecuted instantiation: tudf.c:fqDialectBit Unexecuted instantiation: builtins.c:fqDialectBit Unexecuted instantiation: builtinsimpl.c:fqDialectBit Unexecuted instantiation: spillDistinctSet.c:fqDialectBit Unexecuted instantiation: thistogram.c:fqDialectBit Unexecuted instantiation: tpercentile.c:fqDialectBit Unexecuted instantiation: tavgfunction.c:fqDialectBit Unexecuted instantiation: tminmax.c:fqDialectBit Unexecuted instantiation: tminmaxavx.c:fqDialectBit Unexecuted instantiation: filter.c:fqDialectBit Unexecuted instantiation: scalar.c:fqDialectBit Unexecuted instantiation: sclfunc.c:fqDialectBit Unexecuted instantiation: sclvector.c:fqDialectBit Unexecuted instantiation: nodesCloneFuncs.c:fqDialectBit Unexecuted instantiation: nodesCodeFuncs.c:fqDialectBit Unexecuted instantiation: nodesEqualFuncs.c:fqDialectBit Unexecuted instantiation: nodesMatchFuncs.c:fqDialectBit Unexecuted instantiation: nodesMsgFuncs.c:fqDialectBit Unexecuted instantiation: nodesRemotePlanToSQL.c:fqDialectBit Unexecuted instantiation: nodesToSQLFuncs.c:fqDialectBit Unexecuted instantiation: nodesTraverseFuncs.c:fqDialectBit Unexecuted instantiation: nodesUtilFuncs.c:fqDialectBit Unexecuted instantiation: extTypeMap.c:fqDialectBit Unexecuted instantiation: queryUtil.c:fqDialectBit Unexecuted instantiation: querymsg.c:fqDialectBit Unexecuted instantiation: trans.c:fqDialectBit Unexecuted instantiation: transCli.c:fqDialectBit Unexecuted instantiation: transComm.c:fqDialectBit Unexecuted instantiation: transSasl.c:fqDialectBit Unexecuted instantiation: transSvr.c:fqDialectBit Unexecuted instantiation: transTLS.c:fqDialectBit Unexecuted instantiation: thttp.c:fqDialectBit Unexecuted instantiation: geomFunc.c:fqDialectBit Unexecuted instantiation: tconfig.c:fqDialectBit Unexecuted instantiation: tdigest.c:fqDialectBit Unexecuted instantiation: tlog.c:fqDialectBit Unexecuted instantiation: tmempool.c:fqDialectBit Unexecuted instantiation: tpagedbuf.c:fqDialectBit Unexecuted instantiation: mpDirect.c:fqDialectBit Unexecuted instantiation: extCapability.c:fqDialectBit Unexecuted instantiation: systable.c:fqDialectBit Unexecuted instantiation: tanalytics.c:fqDialectBit Unexecuted instantiation: tdatablock.c:fqDialectBit Unexecuted instantiation: tdataformat.c:fqDialectBit Unexecuted instantiation: tglobal.c:fqDialectBit Unexecuted instantiation: tmisce.c:fqDialectBit Unexecuted instantiation: tname.c:fqDialectBit Unexecuted instantiation: tpriv.c:fqDialectBit Unexecuted instantiation: ttime.c:fqDialectBit Unexecuted instantiation: tvariant.c:fqDialectBit Unexecuted instantiation: streamMsg.c:fqDialectBit Unexecuted instantiation: streamWindowPlan.c:fqDialectBit Unexecuted instantiation: tmsg.c:fqDialectBit Unexecuted instantiation: xnode.c:fqDialectBit Unexecuted instantiation: tencrypt.c:fqDialectBit Unexecuted instantiation: streamJson.c:fqDialectBit Unexecuted instantiation: crypt.c:fqDialectBit |
570 | | |
571 | | // Query whether a function (by funcId), operator (by EOperatorType), or |
572 | | // clause (by EExtClauseKind) is pushable for the given dialect, taking |
573 | | // session-level overrides into account. |
574 | | // |
575 | | // fqFuncCapBitmap - returns the uint16_t bitmap; FQ_CAP_NONE for UDFs/unknown. |
576 | | // fqFuncArg0NcharCapBitmap - returns the arg0==NCHAR-specific bitmap when |
577 | | // configured, otherwise inherits fqFuncCapBitmap(funcId). |
578 | | // fqOpCapBitmap - lookup in gFqOpCap[]; FQ_CAP_NONE for unmapped ops. |
579 | | // fqClauseCapBitmap - lookup in gFqClauseCap[]; FQ_CAP_NONE for unknown kinds. |
580 | | uint16_t fqFuncCapBitmap(int32_t funcId); |
581 | | uint16_t fqFuncArg0NcharCapBitmap(int32_t funcId); |
582 | | uint16_t fqOpCapBitmap(EOperatorType opType); |
583 | | uint16_t fqClauseCapBitmap(EExtClauseKind clauseKind); |
584 | | // Transform-pushdown capability bitmap for a subquery clause. |
585 | | // Current DS/product semantics do not ship transform-only subquery pushdown; |
586 | | // all entries are reserved and default to unsupported. |
587 | | uint16_t fqClauseTransformCapBitmap(EExtClauseKind clauseKind); |
588 | | |
589 | | // High-level pushability check: combines the static bitmap with any active |
590 | | // session-level override (pOverlay may be NULL). |
591 | | bool fqFuncIsPushable(int32_t funcId, int32_t dialect, |
592 | | const SExtCapSessionOverlay* pOverlay); |
593 | | bool fqFuncArg0NcharIsPushable(int32_t funcId, int32_t dialect, |
594 | | const SExtCapSessionOverlay* pOverlay); |
595 | | bool fqOpIsPushable(EOperatorType opType, int32_t dialect, |
596 | | const SExtCapSessionOverlay* pOverlay); |
597 | | bool fqClauseIsPushable(EExtClauseKind clauseKind, int32_t dialect, |
598 | | const SExtCapSessionOverlay* pOverlay); |
599 | | // Whether the dialect supports transform-pushdown of this clause. |
600 | | // Current implementation returns false for all shipped subquery clauses. |
601 | | bool fqClauseTransformIsPushable(EExtClauseKind clauseKind, int32_t dialect, |
602 | | const SExtCapSessionOverlay* pOverlay); |
603 | | |
604 | | // Sub-capability check: tests a specific sub-capability band within a function's |
605 | | // fqPushCap bitmap. subCapShift is the bit offset of the sub-capability's default |
606 | | // band in the low byte (e.g. FQ_CAP_CAST_TS_INT_SHIFT = 3). The session-override |
607 | | // band for the same sub-capability sits at (subCapShift + FQ_CAP_SESSION_SHIFT), |
608 | | // i.e. in the high byte at the same relative position. |
609 | | // |
610 | | // Returns true only when the default bit for `dialect` is set in the sub-cap band |
611 | | // AND the session-override bit is NOT set. |
612 | | bool fqFuncSubCapIsPushable(int32_t funcId, int32_t subCapShift, int32_t dialect, |
613 | | const SExtCapSessionOverlay* pOverlay); |
614 | | // SExtColumnDef / SExtTableMeta - external table metadata types. |
615 | | // Defined here so that nodes/querynodes.h and nodes source files can use them |
616 | | // without depending on extConnector.h, which would create a nodes -> extconnector |
617 | | // build dependency. |
618 | | typedef struct SExtColumnDef { |
619 | | char colName[TSDB_COL_NAME_LEN]; // connector-normalized column name |
620 | | char extTypeName[64]; // original type name from the external source |
621 | | // Charset / encoding for string columns: |
622 | | // MySQL: CHARACTER_SET_NAME from INFORMATION_SCHEMA.COLUMNS (e.g. "utf8mb4"). |
623 | | // PG: server_encoding (e.g. "UTF8"). InfluxDB: empty (always UTF-8). |
624 | | char extCharsetName[32]; |
625 | | bool nullable; |
626 | | bool isTag; // InfluxDB only |
627 | | bool isPrimaryKey; // true if this column maps to the TDengine primary key (timestamp) |
628 | | bool isRemotePrimaryKey; // original remote primary-key column |
629 | | } SExtColumnDef; |
630 | | |
631 | | typedef struct SExtTableMeta { |
632 | | SExtColumnDef *pCols; |
633 | | int32_t numOfCols; |
634 | | int8_t tableType; |
635 | | int8_t tsPrecision; // source-level timestamp precision for the primary-key column |
636 | | // (TSDB_TIME_PRECISION_MILLI/MICRO/NANO); 0 = unknown/not set |
637 | | SName name; // dbname + tname |
638 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
639 | | char schemaName[TSDB_EXT_SOURCE_SCHEMA_LEN]; |
640 | | int64_t fetched_at; // monotonic time of cache fill |
641 | | char remoteTableName[TSDB_TABLE_NAME_LEN]; // actual table name on remote (preserves case) |
642 | | } SExtTableMeta; |
643 | | |
644 | | typedef enum { |
645 | | TSDB_OPTR_NORMAL = 0, // default |
646 | | TSDB_OPTR_SSMIGRATE = 1, |
647 | | TSDB_OPTR_ROLLUP = 2, |
648 | | } ETsdbOpType; |
649 | | |
650 | | typedef enum { |
651 | | TSDB_TRIGGER_MANUAL = 0, // default |
652 | | TSDB_TRIGGER_AUTO = 1, |
653 | | } ETriggerType; |
654 | | |
655 | 0 | #define TSDB_ALTER_TABLE_ADD_TAG 1 |
656 | 0 | #define TSDB_ALTER_TABLE_DROP_TAG 2 |
657 | 0 | #define TSDB_ALTER_TABLE_UPDATE_TAG_NAME 3 |
658 | 0 | #define TSDB_ALTER_TABLE_UPDATE_TAG_VAL 4 // deprecated, kept for wire compatibility |
659 | 0 | #define TSDB_ALTER_TABLE_ADD_COLUMN 5 |
660 | 0 | #define TSDB_ALTER_TABLE_DROP_COLUMN 6 |
661 | 0 | #define TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES 7 |
662 | 0 | #define TSDB_ALTER_TABLE_UPDATE_TAG_BYTES 8 |
663 | 0 | #define TSDB_ALTER_TABLE_UPDATE_OPTIONS 9 |
664 | 0 | #define TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME 10 |
665 | | #define TSDB_ALTER_TABLE_ADD_TAG_INDEX 11 |
666 | | #define TSDB_ALTER_TABLE_DROP_TAG_INDEX 12 |
667 | 0 | #define TSDB_ALTER_TABLE_UPDATE_COLUMN_COMPRESS 13 |
668 | 0 | #define TSDB_ALTER_TABLE_ADD_COLUMN_WITH_COMPRESS_OPTION 14 |
669 | 0 | #define TSDB_ALTER_TABLE_UPDATE_MULTI_TAG_VAL 15 // deprecated, kept for wire compatibility |
670 | 0 | #define TSDB_ALTER_TABLE_ALTER_COLUMN_REF 16 |
671 | 0 | #define TSDB_ALTER_TABLE_REMOVE_COLUMN_REF 17 |
672 | 0 | #define TSDB_ALTER_TABLE_ADD_COLUMN_WITH_COLUMN_REF 18 |
673 | 0 | #define TSDB_ALTER_TABLE_UPDATE_MULTI_TABLE_TAG_VAL 19 // alter multiple tag values of multi tables |
674 | 0 | #define TSDB_ALTER_TABLE_UPDATE_CHILD_TABLE_TAG_VAL 20 // alter multiple tag values of the child tables of a stable |
675 | 0 | #define TSDB_ALTER_TABLE_ALTER_TAG_REF 21 // set/change tag reference for virtual child table |
676 | 0 | #define TSDB_ALTER_TABLE_ADD_SERIES 22 |
677 | 0 | #define TSDB_ALTER_TABLE_REMOVE_SERIES 23 |
678 | 0 | #define TSDB_ALTER_TABLE_ADD_BASE_ON 24 |
679 | 0 | #define TSDB_ALTER_TABLE_DROP_BASE_ON 25 |
680 | 0 | #define TSDB_ALTER_TABLE_ADD_TAG_WITH_TAG_REF 26 // add a tag reference to a virtual normal table |
681 | | |
682 | | #define TSDB_FILL_NONE 0 |
683 | | #define TSDB_FILL_NULL 1 |
684 | | #define TSDB_FILL_NULL_F 2 |
685 | | #define TSDB_FILL_SET_VALUE 3 |
686 | | #define TSDB_FILL_SET_VALUE_F 4 |
687 | | #define TSDB_FILL_LINEAR 5 |
688 | | #define TSDB_FILL_PREV 6 |
689 | | #define TSDB_FILL_NEXT 7 |
690 | | #define TSDB_FILL_NEAR 8 |
691 | | |
692 | | |
693 | 0 | #define TSDB_ALTER_USER_BASIC_INFO 1 |
694 | | // these definitions start from 5 is to keep compatible with old versions |
695 | | #define TSDB_ALTER_USER_ADD_PRIVILEGES 5 |
696 | | #define TSDB_ALTER_USER_DEL_PRIVILEGES 6 |
697 | | |
698 | | |
699 | 0 | #define TSDB_ALTER_ROLE_LOCK 0x1 |
700 | 0 | #define TSDB_ALTER_ROLE_ROLE 0x2 |
701 | 0 | #define TSDB_ALTER_ROLE_PRIVILEGES 0x3 |
702 | 0 | #define TSDB_ALTER_ROLE_MAX 0x4 // increase according to actual use |
703 | | |
704 | 0 | #define TSDB_ALTER_RSMA_FUNCTION 0x1 |
705 | | |
706 | | #define TSDB_KILL_MSG_LEN 30 |
707 | | |
708 | | #define TSDB_TABLE_NUM_UNIT 100000 |
709 | | |
710 | | #define TSDB_VN_READ_ACCCESS ((char)0x1) |
711 | | #define TSDB_VN_WRITE_ACCCESS ((char)0x2) |
712 | | #define TSDB_VN_ALL_ACCCESS (TSDB_VN_READ_ACCCESS | TSDB_VN_WRITE_ACCCESS) |
713 | | |
714 | | #define TSDB_COL_NORMAL 0x0u // the normal column of the table |
715 | | #define TSDB_COL_TAG 0x1u // the tag column type |
716 | | #define TSDB_COL_UDC 0x2u // the user specified normal string column, it is a dummy column |
717 | | #define TSDB_COL_TMP 0x4u // internal column generated by the previous operators |
718 | | #define TSDB_COL_NULL 0x8u // the column filter NULL or not |
719 | | |
720 | | #define TSDB_COL_IS_TAG(f) (((f & (~(TSDB_COL_NULL))) & TSDB_COL_TAG) != 0) |
721 | | #define TSDB_COL_IS_NORMAL_COL(f) ((f & (~(TSDB_COL_NULL))) == TSDB_COL_NORMAL) |
722 | | #define TSDB_COL_IS_UD_COL(f) ((f & (~(TSDB_COL_NULL))) == TSDB_COL_UDC) |
723 | | #define TSDB_COL_REQ_NULL(f) (((f) & TSDB_COL_NULL) != 0) |
724 | | |
725 | | #define TD_SUPER_TABLE TSDB_SUPER_TABLE |
726 | 0 | #define TD_CHILD_TABLE TSDB_CHILD_TABLE |
727 | 0 | #define TD_NORMAL_TABLE TSDB_NORMAL_TABLE |
728 | 0 | #define TD_VIRTUAL_NORMAL_TABLE TSDB_VIRTUAL_NORMAL_TABLE |
729 | 0 | #define TD_VIRTUAL_CHILD_TABLE TSDB_VIRTUAL_CHILD_TABLE |
730 | | |
731 | | typedef enum ENodeType { |
732 | | // Syntax nodes are used in parser and planner module, and some are also used in executor module, such as COLUMN, |
733 | | // VALUE, OPERATOR, FUNCTION and so on. |
734 | | QUERY_NODE_COLUMN = 1, |
735 | | QUERY_NODE_VALUE, |
736 | | QUERY_NODE_OPERATOR, |
737 | | QUERY_NODE_LOGIC_CONDITION, |
738 | | QUERY_NODE_FUNCTION, |
739 | | QUERY_NODE_REAL_TABLE, |
740 | | QUERY_NODE_TEMP_TABLE, |
741 | | QUERY_NODE_JOIN_TABLE, |
742 | | QUERY_NODE_GROUPING_SET, |
743 | | QUERY_NODE_ORDER_BY_EXPR, |
744 | | QUERY_NODE_LIMIT, |
745 | | QUERY_NODE_STATE_WINDOW, |
746 | | QUERY_NODE_SESSION_WINDOW, |
747 | | QUERY_NODE_INTERVAL_WINDOW, |
748 | | QUERY_NODE_NODE_LIST, |
749 | | QUERY_NODE_FILL, |
750 | | QUERY_NODE_RAW_EXPR, // Only be used in parser module. |
751 | | QUERY_NODE_TARGET, |
752 | | QUERY_NODE_DATABLOCK_DESC, |
753 | | QUERY_NODE_SLOT_DESC, |
754 | | QUERY_NODE_COLUMN_DEF, |
755 | | QUERY_NODE_DOWNSTREAM_SOURCE, |
756 | | QUERY_NODE_DATABASE_OPTIONS, |
757 | | QUERY_NODE_TABLE_OPTIONS, |
758 | | QUERY_NODE_INDEX_OPTIONS, |
759 | | QUERY_NODE_EXPLAIN_OPTIONS, |
760 | | QUERY_NODE_LEFT_VALUE, |
761 | | QUERY_NODE_COLUMN_REF, |
762 | | QUERY_NODE_WHEN_THEN, |
763 | | QUERY_NODE_CASE_WHEN, |
764 | | QUERY_NODE_EVENT_WINDOW, |
765 | | QUERY_NODE_HINT, |
766 | | QUERY_NODE_VIEW, |
767 | | QUERY_NODE_WINDOW_OFFSET, |
768 | | QUERY_NODE_SQL_WINDOW_SPEC, |
769 | | QUERY_NODE_SQL_WINDOW_FRAME, |
770 | | QUERY_NODE_SQL_NAMED_WINDOW, |
771 | | QUERY_NODE_COUNT_WINDOW, |
772 | | QUERY_NODE_COLUMN_OPTIONS, |
773 | | QUERY_NODE_TSMA_OPTIONS, |
774 | | QUERY_NODE_ANOMALY_WINDOW, |
775 | | QUERY_NODE_RANGE_AROUND, |
776 | | QUERY_NODE_STREAM_NOTIFY_OPTIONS, |
777 | | QUERY_NODE_VIRTUAL_TABLE, |
778 | | QUERY_NODE_SLIDING_WINDOW, |
779 | | QUERY_NODE_PERIOD_WINDOW, |
780 | | QUERY_NODE_STREAM_TRIGGER, |
781 | | QUERY_NODE_STREAM, |
782 | | QUERY_NODE_STREAM_TAG_DEF, |
783 | | QUERY_NODE_EXTERNAL_WINDOW, |
784 | | QUERY_NODE_STREAM_TRIGGER_OPTIONS, |
785 | | QUERY_NODE_PLACE_HOLDER_TABLE, |
786 | | QUERY_NODE_TIME_RANGE, |
787 | | QUERY_NODE_STREAM_OUT_TABLE, |
788 | | QUERY_NODE_STREAM_CALC_RANGE, |
789 | | QUERY_NODE_COUNT_WINDOW_ARGS, |
790 | | QUERY_NODE_BNODE_OPTIONS, |
791 | | QUERY_NODE_DATE_TIME_RANGE, |
792 | | QUERY_NODE_IP_RANGE, |
793 | | QUERY_NODE_USER_OPTIONS, |
794 | | QUERY_NODE_REMOTE_VALUE, |
795 | | QUERY_NODE_TOKEN_OPTIONS, |
796 | | QUERY_NODE_TRUE_FOR, |
797 | | QUERY_NODE_REMOTE_VALUE_LIST, |
798 | | QUERY_NODE_SURROUND, |
799 | | QUERY_NODE_REMOTE_ROW, |
800 | | QUERY_NODE_REMOTE_ZERO_ROWS, |
801 | | QUERY_NODE_UPDATE_TAG_VALUE, |
802 | | QUERY_NODE_ALTER_TABLE_UPDATE_TAG_VAL_CLAUSE, |
803 | | QUERY_NODE_REMOTE_TABLE, |
804 | | QUERY_NODE_FILE_TABLE, |
805 | | QUERY_NODE_TEXT_TABLE, |
806 | | QUERY_NODE_TAG_REF_COLUMN, |
807 | | QUERY_NODE_EXTERNAL_TABLE, // SExtTableNode: external table reference in FROM clause |
808 | | QUERY_NODE_EXT_OPTION, // helper: single OPTIONS key='val' pair node |
809 | | QUERY_NODE_EXT_ALTER_CLAUSE, // helper: one SET clause in ALTER EXTERNAL SOURCE |
810 | | QUERY_NODE_EVENT_START_LEAF, |
811 | | QUERY_NODE_STREAM_WINDOW_PLAN, |
812 | | QUERY_NODE_STREAM_WINDOW_LAYER, |
813 | | |
814 | | // Statement nodes are used in parser and planner module. |
815 | | QUERY_NODE_SET_OPERATOR = 100, |
816 | | QUERY_NODE_SELECT_STMT, |
817 | | QUERY_NODE_VNODE_MODIFY_STMT, |
818 | | QUERY_NODE_CREATE_DATABASE_STMT, |
819 | | QUERY_NODE_DROP_DATABASE_STMT, |
820 | | QUERY_NODE_ALTER_DATABASE_STMT, |
821 | | QUERY_NODE_FLUSH_DATABASE_STMT, |
822 | | QUERY_NODE_TRIM_DATABASE_STMT, |
823 | | QUERY_NODE_CREATE_TABLE_STMT, |
824 | | QUERY_NODE_CREATE_SUBTABLE_CLAUSE, |
825 | | QUERY_NODE_CREATE_MULTI_TABLES_STMT, |
826 | | QUERY_NODE_DROP_TABLE_CLAUSE, |
827 | | QUERY_NODE_DROP_TABLE_STMT, |
828 | | QUERY_NODE_DROP_SUPER_TABLE_STMT, |
829 | | QUERY_NODE_ALTER_TABLE_STMT, |
830 | | QUERY_NODE_ALTER_SUPER_TABLE_STMT, |
831 | | QUERY_NODE_CREATE_USER_STMT, |
832 | | QUERY_NODE_ALTER_USER_STMT, |
833 | | QUERY_NODE_DROP_USER_STMT, |
834 | | QUERY_NODE_USE_DATABASE_STMT, |
835 | | QUERY_NODE_USE_EXT_SOURCE_STMT, |
836 | | QUERY_NODE_CREATE_DNODE_STMT, |
837 | | QUERY_NODE_DROP_DNODE_STMT, |
838 | | QUERY_NODE_ALTER_DNODE_STMT, |
839 | | QUERY_NODE_CREATE_INDEX_STMT, |
840 | | QUERY_NODE_DROP_INDEX_STMT, |
841 | | QUERY_NODE_CREATE_QNODE_STMT, |
842 | | QUERY_NODE_DROP_QNODE_STMT, |
843 | | QUERY_NODE_CREATE_BACKUP_NODE_STMT, // no longer used |
844 | | QUERY_NODE_DROP_BACKUP_NODE_STMT, // no longer used |
845 | | QUERY_NODE_CREATE_SNODE_STMT, |
846 | | QUERY_NODE_DROP_SNODE_STMT, |
847 | | QUERY_NODE_CREATE_MNODE_STMT, |
848 | | QUERY_NODE_DROP_MNODE_STMT, |
849 | | QUERY_NODE_CREATE_TOPIC_STMT, |
850 | | QUERY_NODE_DROP_TOPIC_STMT, |
851 | | QUERY_NODE_DROP_CGROUP_STMT, |
852 | | QUERY_NODE_ALTER_LOCAL_STMT, |
853 | | QUERY_NODE_EXPLAIN_STMT, |
854 | | QUERY_NODE_DESCRIBE_STMT, |
855 | | QUERY_NODE_RESET_QUERY_CACHE_STMT, |
856 | | QUERY_NODE_COMPACT_DATABASE_STMT, |
857 | | QUERY_NODE_COMPACT_VGROUPS_STMT, |
858 | | QUERY_NODE_CREATE_FUNCTION_STMT, |
859 | | QUERY_NODE_DROP_FUNCTION_STMT, |
860 | | QUERY_NODE_CREATE_STREAM_STMT, |
861 | | QUERY_NODE_DROP_STREAM_STMT, |
862 | | QUERY_NODE_BALANCE_VGROUP_STMT, |
863 | | QUERY_NODE_MERGE_VGROUP_STMT, |
864 | | QUERY_NODE_REDISTRIBUTE_VGROUP_STMT, |
865 | | QUERY_NODE_SPLIT_VGROUP_STMT, |
866 | | QUERY_NODE_SYNCDB_STMT, |
867 | | QUERY_NODE_GRANT_STMT, |
868 | | QUERY_NODE_REVOKE_STMT, |
869 | | QUERY_NODE_ALTER_CLUSTER_STMT, |
870 | | QUERY_NODE_SSMIGRATE_DATABASE_STMT, |
871 | | QUERY_NODE_CREATE_TSMA_STMT, |
872 | | QUERY_NODE_DROP_TSMA_STMT, |
873 | | QUERY_NODE_CREATE_VIRTUAL_TABLE_STMT, |
874 | | QUERY_NODE_CREATE_VIRTUAL_SUBTABLE_STMT, |
875 | | QUERY_NODE_DROP_VIRTUAL_TABLE_STMT, |
876 | | QUERY_NODE_ALTER_VIRTUAL_TABLE_STMT, |
877 | | QUERY_NODE_CREATE_MOUNT_STMT, |
878 | | QUERY_NODE_DROP_MOUNT_STMT, |
879 | | QUERY_NODE_SCAN_DATABASE_STMT, |
880 | | QUERY_NODE_SCAN_VGROUPS_STMT, |
881 | | QUERY_NODE_TRIM_DATABASE_WAL_STMT, |
882 | | QUERY_NODE_ALTER_DNODES_RELOAD_TLS_STMT, |
883 | | QUERY_NODE_CREATE_TOKEN_STMT, |
884 | | QUERY_NODE_ALTER_TOKEN_STMT, |
885 | | QUERY_NODE_DROP_TOKEN_STMT, |
886 | | QUERY_NODE_ALTER_ENCRYPT_KEY_STMT, |
887 | | QUERY_NODE_CREATE_ROLE_STMT, |
888 | | QUERY_NODE_DROP_ROLE_STMT, |
889 | | QUERY_NODE_ALTER_ROLE_STMT, |
890 | | QUERY_NODE_CREATE_TOTP_SECRET_STMT, |
891 | | QUERY_NODE_DROP_TOTP_SECRET_STMT, |
892 | | QUERY_NODE_ALTER_KEY_EXPIRATION_STMT, |
893 | | QUERY_NODE_SET_TIMEZONE_STMT, |
894 | | QUERY_NODE_SET_FIRST_DAY_OF_WEEK_STMT, |
895 | | QUERY_NODE_CREATE_BACKUP_STMT, |
896 | | |
897 | | // show statement nodes |
898 | | QUERY_NODE_SHOW_CREATE_VIEW_STMT = 181, |
899 | | QUERY_NODE_SHOW_CREATE_DATABASE_STMT, |
900 | | QUERY_NODE_SHOW_CREATE_TABLE_STMT, |
901 | | QUERY_NODE_SHOW_CREATE_STABLE_STMT, |
902 | | QUERY_NODE_SHOW_TABLE_DISTRIBUTED_STMT, |
903 | | QUERY_NODE_SHOW_LOCAL_VARIABLES_STMT, |
904 | | QUERY_NODE_SHOW_SCORES_STMT, |
905 | | QUERY_NODE_SHOW_TABLE_TAGS_STMT, |
906 | | QUERY_NODE_KILL_CONNECTION_STMT, |
907 | | QUERY_NODE_KILL_QUERY_STMT, |
908 | | QUERY_NODE_KILL_TRANSACTION_STMT, |
909 | | QUERY_NODE_KILL_COMPACT_STMT, |
910 | | QUERY_NODE_DELETE_STMT, |
911 | | QUERY_NODE_INSERT_STMT, |
912 | | QUERY_NODE_QUERY, |
913 | | QUERY_NODE_SHOW_DB_ALIVE_STMT, |
914 | | QUERY_NODE_SHOW_CLUSTER_ALIVE_STMT, |
915 | | QUERY_NODE_BALANCE_VGROUP_LEADER_STMT, |
916 | | QUERY_NODE_BALANCE_VGROUP_LEADER_DATABASE_STMT, |
917 | | QUERY_NODE_RESTORE_DNODE_STMT, |
918 | | QUERY_NODE_RESTORE_QNODE_STMT, |
919 | | QUERY_NODE_RESTORE_MNODE_STMT, |
920 | | QUERY_NODE_RESTORE_VNODE_STMT, |
921 | | QUERY_NODE_PAUSE_STREAM_STMT, |
922 | | QUERY_NODE_RESUME_STREAM_STMT, |
923 | | QUERY_NODE_CREATE_VIEW_STMT, |
924 | | QUERY_NODE_DROP_VIEW_STMT, |
925 | | QUERY_NODE_CREATE_SUBTABLE_FROM_FILE_CLAUSE, |
926 | | QUERY_NODE_CREATE_ANODE_STMT, |
927 | | QUERY_NODE_DROP_ANODE_STMT, |
928 | | QUERY_NODE_UPDATE_ANODE_STMT, |
929 | | QUERY_NODE_ASSIGN_LEADER_STMT, |
930 | | QUERY_NODE_SHOW_CREATE_TSMA_STMT, |
931 | | QUERY_NODE_SHOW_CREATE_VTABLE_STMT, |
932 | | QUERY_NODE_RECALCULATE_STREAM_STMT, |
933 | | QUERY_NODE_CREATE_BNODE_STMT, |
934 | | QUERY_NODE_DROP_BNODE_STMT, |
935 | | QUERY_NODE_KILL_SSMIGRATE_STMT, |
936 | | QUERY_NODE_KILL_SCAN_STMT, |
937 | | QUERY_NODE_CREATE_RSMA_STMT, |
938 | | QUERY_NODE_DROP_RSMA_STMT, |
939 | | QUERY_NODE_ALTER_RSMA_STMT, |
940 | | QUERY_NODE_SHOW_CREATE_RSMA_STMT, |
941 | | QUERY_NODE_ROLLUP_DATABASE_STMT, |
942 | | QUERY_NODE_ROLLUP_VGROUPS_STMT, |
943 | | QUERY_NODE_KILL_RETENTION_STMT, |
944 | | QUERY_NODE_SET_VGROUP_KEEP_VERSION_STMT, |
945 | | QUERY_NODE_CREATE_ENCRYPT_ALGORITHMS_STMT, |
946 | | QUERY_NODE_DROP_ENCRYPT_ALGR_STMT, |
947 | | QUERY_NODE_SHOW_CREATE_STREAM_STMT, |
948 | | QUERY_NODE_KILL_BACKUP_STMT, |
949 | | |
950 | | // DDL statement nodes for federated query (external source) - 240-249 reserved |
951 | | QUERY_NODE_CREATE_EXT_SOURCE_STMT = 240, |
952 | | QUERY_NODE_ALTER_EXT_SOURCE_STMT, |
953 | | QUERY_NODE_DROP_EXT_SOURCE_STMT, |
954 | | QUERY_NODE_REFRESH_EXT_SOURCE_STMT, |
955 | | QUERY_NODE_SHOW_EXT_SOURCES_STMT, // SHOW EXTERNAL SOURCES |
956 | | QUERY_NODE_DESCRIBE_EXT_SOURCE_STMT, // DESCRIBE EXTERNAL SOURCE <name> |
957 | | QUERY_NODE_SHOW_EXT_SOURCE_CAPABILITY_STMT, // SHOW EXTERNAL SOURCE <name> CAPABILITY |
958 | | |
959 | | QUERY_NODE_BEGIN_TRANS_STMT = 250, |
960 | | QUERY_NODE_COMMIT_TRANS_STMT, |
961 | | QUERY_NODE_ROLLBACK_TRANS_STMT, |
962 | | QUERY_NODE_CLOSE_VNODE_STMT, |
963 | | QUERY_NODE_OPEN_VNODE_STMT, |
964 | | |
965 | | // show statement nodes |
966 | | // see 'sysTableShowAdapter', 'SYSTABLE_SHOW_TYPE_OFFSET' |
967 | | QUERY_NODE_SHOW_DNODES_STMT = 400, |
968 | | QUERY_NODE_SHOW_MNODES_STMT, |
969 | | QUERY_NODE_SHOW_MODULES_STMT, |
970 | | QUERY_NODE_SHOW_QNODES_STMT, |
971 | | QUERY_NODE_SHOW_SNODES_STMT, |
972 | | QUERY_NODE_SHOW_BACKUP_NODES_STMT, // no longer used |
973 | | QUERY_NODE_SHOW_ARBGROUPS_STMT, |
974 | | QUERY_NODE_SHOW_CLUSTER_STMT, |
975 | | QUERY_NODE_SHOW_DATABASES_STMT, |
976 | | QUERY_NODE_SHOW_FUNCTIONS_STMT, |
977 | | QUERY_NODE_SHOW_INDEXES_STMT, |
978 | | QUERY_NODE_SHOW_STABLES_STMT, |
979 | | QUERY_NODE_SHOW_STREAMS_STMT, |
980 | | QUERY_NODE_SHOW_TABLES_STMT, |
981 | | QUERY_NODE_SHOW_TAGS_STMT, |
982 | | QUERY_NODE_SHOW_USERS_STMT, |
983 | | QUERY_NODE_SHOW_USERS_FULL_STMT, |
984 | | QUERY_NODE_SHOW_LICENCES_STMT, |
985 | | QUERY_NODE_SHOW_VGROUPS_STMT, |
986 | | QUERY_NODE_SHOW_TOPICS_STMT, |
987 | | QUERY_NODE_SHOW_CONSUMERS_STMT, |
988 | | QUERY_NODE_SHOW_CONNECTIONS_STMT, |
989 | | QUERY_NODE_SHOW_QUERIES_STMT, |
990 | | QUERY_NODE_SHOW_APPS_STMT, |
991 | | QUERY_NODE_SHOW_VARIABLES_STMT, |
992 | | QUERY_NODE_SHOW_DNODE_VARIABLES_STMT, |
993 | | QUERY_NODE_SHOW_TRANSACTIONS_STMT, |
994 | | QUERY_NODE_SHOW_SUBSCRIPTIONS_STMT, |
995 | | QUERY_NODE_SHOW_VNODES_STMT, |
996 | | QUERY_NODE_SHOW_USER_PRIVILEGES_STMT, |
997 | | QUERY_NODE_SHOW_VIEWS_STMT, |
998 | | QUERY_NODE_SHOW_COMPACTS_STMT, |
999 | | QUERY_NODE_SHOW_COMPACT_DETAILS_STMT, |
1000 | | QUERY_NODE_SHOW_GRANTS_FULL_STMT, |
1001 | | QUERY_NODE_SHOW_GRANTS_LOGS_STMT, |
1002 | | QUERY_NODE_SHOW_CLUSTER_MACHINES_STMT, |
1003 | | QUERY_NODE_SHOW_ENCRYPTIONS_STMT, |
1004 | | QUERY_NODE_SHOW_TSMAS_STMT, |
1005 | | QUERY_NODE_SHOW_ANODES_STMT, |
1006 | | QUERY_NODE_SHOW_ANODES_FULL_STMT, |
1007 | | QUERY_NODE_SHOW_USAGE_STMT, |
1008 | | QUERY_NODE_SHOW_FILESETS_STMT, |
1009 | | QUERY_NODE_SHOW_TRANSACTION_DETAILS_STMT, |
1010 | | QUERY_NODE_SHOW_VTABLES_STMT, |
1011 | | QUERY_NODE_SHOW_BNODES_STMT, |
1012 | | QUERY_NODE_SHOW_MOUNTS_STMT, |
1013 | | QUERY_NODE_SHOW_SSMIGRATES_STMT, |
1014 | | QUERY_NODE_SHOW_SCANS_STMT, |
1015 | | QUERY_NODE_SHOW_SCAN_DETAILS_STMT, |
1016 | | QUERY_NODE_SHOW_RSMAS_STMT, |
1017 | | QUERY_NODE_SHOW_RETENTIONS_STMT, |
1018 | | QUERY_NODE_SHOW_RETENTION_DETAILS_STMT, |
1019 | | QUERY_NODE_SHOW_INSTANCES_STMT, |
1020 | | QUERY_NODE_SHOW_ENCRYPT_ALGORITHMS_STMT, |
1021 | | // the order of QUERY_NODE_SHOW_* must be aligned with the order of `sysTableShowAdapter` defines. |
1022 | | QUERY_NODE_SHOW_TOKENS_STMT, |
1023 | | QUERY_NODE_SHOW_ENCRYPT_STATUS_STMT, |
1024 | | QUERY_NODE_SHOW_ROLES_STMT, |
1025 | | QUERY_NODE_SHOW_ROLE_PRIVILEGES_STMT, |
1026 | | QUERY_NODE_SHOW_ROLE_COL_PRIVILEGES_STMT, |
1027 | | QUERY_NODE_SHOW_XNODES_STMT, |
1028 | | QUERY_NODE_SHOW_XNODE_TASKS_STMT, |
1029 | | QUERY_NODE_SHOW_XNODE_AGENTS_STMT, |
1030 | | QUERY_NODE_SHOW_XNODE_JOBS_STMT, |
1031 | | QUERY_NODE_SHOW_VALIDATE_VTABLE_STMT, |
1032 | | QUERY_NODE_SHOW_SECURITY_POLICIES_STMT, |
1033 | | QUERY_NODE_SHOW_CPU_ALLOCATION_STMT, |
1034 | | QUERY_NODE_SHOW_TRANSACTION_LOGS_STMT, |
1035 | | QUERY_NODE_SHOW_TRANSACTION_ORPHANS_STMT, |
1036 | | // VST inheritance (BASE ON): appended at the end to preserve existing enum values. |
1037 | | QUERY_NODE_SHOW_VSTABLE_INHERITS_STMT, |
1038 | | QUERY_NODE_SHOW_BACKUPS_STMT, |
1039 | | |
1040 | | // logic plan node |
1041 | | QUERY_NODE_LOGIC_PLAN_SCAN = 1000, |
1042 | | QUERY_NODE_LOGIC_PLAN_JOIN, |
1043 | | QUERY_NODE_LOGIC_PLAN_AGG, |
1044 | | QUERY_NODE_LOGIC_PLAN_PROJECT, |
1045 | | QUERY_NODE_LOGIC_PLAN_VNODE_MODIFY, |
1046 | | QUERY_NODE_LOGIC_PLAN_EXCHANGE, |
1047 | | QUERY_NODE_LOGIC_PLAN_MERGE, |
1048 | | QUERY_NODE_LOGIC_PLAN_WINDOW, |
1049 | | QUERY_NODE_LOGIC_PLAN_FILL, |
1050 | | QUERY_NODE_LOGIC_PLAN_SORT, |
1051 | | QUERY_NODE_LOGIC_PLAN_PARTITION, |
1052 | | QUERY_NODE_LOGIC_PLAN_INDEF_ROWS_FUNC, |
1053 | | QUERY_NODE_LOGIC_PLAN_INTERP_FUNC, |
1054 | | QUERY_NODE_LOGIC_SUBPLAN, |
1055 | | QUERY_NODE_LOGIC_PLAN, |
1056 | | QUERY_NODE_LOGIC_PLAN_GROUP_CACHE, |
1057 | | QUERY_NODE_LOGIC_PLAN_DYN_QUERY_CTRL, |
1058 | | QUERY_NODE_LOGIC_PLAN_FORECAST_FUNC, |
1059 | | QUERY_NODE_LOGIC_PLAN_VIRTUAL_TABLE_SCAN, |
1060 | | QUERY_NODE_LOGIC_PLAN_ANALYSIS_FUNC, |
1061 | | QUERY_NODE_LOGIC_PLAN_ROWSET_SOURCE, |
1062 | | QUERY_NODE_LOGIC_PLAN_TAG_REF_SOURCE, |
1063 | | QUERY_NODE_LOGIC_PLAN_DISTINCT_FILTER, |
1064 | | QUERY_NODE_LOGIC_PLAN_WINDOW_FUNC, |
1065 | | |
1066 | | // physical plan node |
1067 | | QUERY_NODE_PHYSICAL_PLAN_TAG_SCAN = 1100, |
1068 | | QUERY_NODE_PHYSICAL_PLAN_TABLE_SCAN, |
1069 | | QUERY_NODE_PHYSICAL_PLAN_TABLE_SEQ_SCAN, // INACTIVE |
1070 | | QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN, |
1071 | | QUERY_NODE_PHYSICAL_PLAN_STREAM_SCAN, |
1072 | | QUERY_NODE_PHYSICAL_PLAN_SYSTABLE_SCAN, |
1073 | | QUERY_NODE_PHYSICAL_PLAN_BLOCK_DIST_SCAN, |
1074 | | QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN, |
1075 | | QUERY_NODE_PHYSICAL_PLAN_PROJECT, |
1076 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_JOIN, |
1077 | | QUERY_NODE_PHYSICAL_PLAN_HASH_AGG, |
1078 | | QUERY_NODE_PHYSICAL_PLAN_EXCHANGE, |
1079 | | QUERY_NODE_PHYSICAL_PLAN_MERGE, |
1080 | | QUERY_NODE_PHYSICAL_PLAN_SORT, |
1081 | | QUERY_NODE_PHYSICAL_PLAN_GROUP_SORT, |
1082 | | QUERY_NODE_PHYSICAL_PLAN_HASH_INTERVAL, |
1083 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_INTERVAL, // INACTIVE |
1084 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_ALIGNED_INTERVAL, |
1085 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_1, |
1086 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_2, |
1087 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_3, |
1088 | | QUERY_NODE_PHYSICAL_PLAN_FILL, |
1089 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_4, |
1090 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_SESSION, |
1091 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_5, |
1092 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_6, |
1093 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_7, |
1094 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_STATE, |
1095 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_8, |
1096 | | QUERY_NODE_PHYSICAL_PLAN_PARTITION, |
1097 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_9, |
1098 | | QUERY_NODE_PHYSICAL_PLAN_INDEF_ROWS_FUNC, |
1099 | | QUERY_NODE_PHYSICAL_PLAN_INTERP_FUNC, |
1100 | | QUERY_NODE_PHYSICAL_PLAN_DISPATCH, |
1101 | | QUERY_NODE_PHYSICAL_PLAN_INSERT, |
1102 | | QUERY_NODE_PHYSICAL_PLAN_QUERY_INSERT, |
1103 | | QUERY_NODE_PHYSICAL_PLAN_DELETE, |
1104 | | QUERY_NODE_PHYSICAL_SUBPLAN, |
1105 | | QUERY_NODE_PHYSICAL_PLAN, |
1106 | | QUERY_NODE_PHYSICAL_PLAN_TABLE_COUNT_SCAN, |
1107 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_EVENT, |
1108 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_10, |
1109 | | QUERY_NODE_PHYSICAL_PLAN_HASH_JOIN, |
1110 | | QUERY_NODE_PHYSICAL_PLAN_GROUP_CACHE, |
1111 | | QUERY_NODE_PHYSICAL_PLAN_DYN_QUERY_CTRL, |
1112 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_COUNT, |
1113 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_11, |
1114 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_12, |
1115 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_13, |
1116 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_ANOMALY, |
1117 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_14, |
1118 | | QUERY_NODE_PHYSICAL_PLAN_FORECAST_FUNC, |
1119 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_15, |
1120 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_16, |
1121 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_17, |
1122 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_18, |
1123 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_19, |
1124 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_20, |
1125 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_21, |
1126 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_22, |
1127 | | QUERY_NODE_PHYSICAL_PLAN_UNUSED_23, |
1128 | | QUERY_NODE_PHYSICAL_PLAN_WINDOW_FUNC, |
1129 | | QUERY_NODE_PHYSICAL_PLAN_VIRTUAL_TABLE_SCAN, |
1130 | | QUERY_NODE_PHYSICAL_PLAN_EXTERNAL_WINDOW, |
1131 | | QUERY_NODE_PHYSICAL_PLAN_HASH_EXTERNAL, |
1132 | | QUERY_NODE_PHYSICAL_PLAN_MERGE_ALIGNED_EXTERNAL, |
1133 | | QUERY_NODE_PHYSICAL_PLAN_STREAM_INSERT, |
1134 | | QUERY_NODE_PHYSICAL_PLAN_ANALYSIS_FUNC, |
1135 | | QUERY_NODE_PHYSICAL_PLAN_ROWSET_SOURCE, |
1136 | | QUERY_NODE_PHYSICAL_PLAN_TAG_REF_SOURCE, |
1137 | | QUERY_NODE_PHYSICAL_PLAN_DISTINCT_FILTER, // deprecated |
1138 | | QUERY_NODE_PHYSICAL_PLAN_FEDERATED_SCAN, // federated query scan operator |
1139 | | // Same plan as TABLE_COUNT_SCAN plus an ins_tables row type filter (tbCountType). Emitted only when |
1140 | | // the filter is present so that older vnodes reject the unknown node type instead of silently |
1141 | | // ignoring the filter and returning an unfiltered (too large) count during rolling upgrades. |
1142 | | QUERY_NODE_PHYSICAL_PLAN_TABLE_COUNT_SCAN_BY_TYPE, |
1143 | | QUERY_NODE_PHYSICAL_PLAN_THETA_JOIN, |
1144 | | // xnode |
1145 | | QUERY_NODE_CREATE_XNODE_STMT = 1200, // Xnode |
1146 | | QUERY_NODE_DROP_XNODE_STMT, |
1147 | | QUERY_NODE_DRAIN_XNODE_STMT, |
1148 | | QUERY_NODE_XNODE_TASK_OPTIONS, // XNode task options |
1149 | | QUERY_NODE_XNODE_TASK_SOURCE_OPT, // XNode task source |
1150 | | QUERY_NODE_XNODE_TASK_SINK_OPT, // XNode task sink |
1151 | | QUERY_NODE_CREATE_XNODE_TASK_STMT, // XNode task |
1152 | | QUERY_NODE_START_XNODE_TASK_STMT, // XNode task |
1153 | | QUERY_NODE_STOP_XNODE_TASK_STMT, // XNode task |
1154 | | QUERY_NODE_UPDATE_XNODE_TASK_STMT, // XNode task |
1155 | | QUERY_NODE_DROP_XNODE_TASK_STMT, // XNode task |
1156 | | QUERY_NODE_CREATE_XNODE_JOB_STMT, // XNode job |
1157 | | QUERY_NODE_ALTER_XNODE_JOB_STMT, // XNode job |
1158 | | QUERY_NODE_REBALANCE_XNODE_JOB_STMT, // XNode job |
1159 | | QUERY_NODE_REBALANCE_XNODE_JOB_WHERE_STMT, // XNode job |
1160 | | QUERY_NODE_DROP_XNODE_JOB_STMT, // XNode job |
1161 | | QUERY_NODE_CREATE_XNODE_AGENT_STMT, // XNode agent |
1162 | | QUERY_NODE_DROP_XNODE_AGENT_STMT, // XNode agent |
1163 | | QUERY_NODE_ALTER_XNODE_AGENT_STMT, // XNode agent |
1164 | | QUERY_NODE_ALTER_XNODE_STMT, // Alter xnode |
1165 | | |
1166 | | // ext-source virtual table series (appended to avoid disturbing pinned QUERY_NODE_SHOW_CREATE_VIEW_STMT=181 block) |
1167 | | QUERY_NODE_SERIES_DECL, |
1168 | | QUERY_NODE_SERIES_TAG_ASSIGN, |
1169 | | // appended to avoid disturbing pinned show-statement values |
1170 | | QUERY_NODE_FLUSH_MNODE_STMT, |
1171 | | |
1172 | | // xnode restart (appended to preserve existing enum numeric values) |
1173 | | QUERY_NODE_RESTART_XNODE_STMT, |
1174 | | // Correlation nodes use a separate range; existing wire IDs stay unchanged. |
1175 | | QUERY_NODE_OUTER_REF = 1300, |
1176 | | QUERY_NODE_CORRELATION_PARAM, |
1177 | | QUERY_NODE_CORRELATION_PARAM_BINDING, |
1178 | | QUERY_NODE_CORRELATED_SUBQUERY, |
1179 | | QUERY_NODE_CORRELATION_TEMPLATE, |
1180 | | QUERY_NODE_CORRELATION_TIME_RANGE_INIT, |
1181 | | } ENodeType; |
1182 | | |
1183 | | typedef struct { |
1184 | | int32_t vgId; |
1185 | | uint8_t option; // 0x0 REQ_OPT_TBNAME, 0x01 REQ_OPT_TBUID |
1186 | | uint8_t autoCreateCtb; // 0x0 not auto create, 0x01 auto create |
1187 | | const char* dbFName; |
1188 | | const char* tbName; |
1189 | | } SBuildTableInput; |
1190 | | |
1191 | | typedef struct { |
1192 | | char db[TSDB_DB_FNAME_LEN]; |
1193 | | int64_t dbId; |
1194 | | int32_t vgVersion; |
1195 | | int32_t numOfTable; // unit is TSDB_TABLE_NUM_UNIT |
1196 | | int64_t stateTs; |
1197 | | } SBuildUseDBInput; |
1198 | | |
1199 | | typedef struct SField { |
1200 | | char name[TSDB_COL_NAME_LEN]; |
1201 | | uint8_t type; |
1202 | | int8_t flags; |
1203 | | int32_t bytes; |
1204 | | } SField; |
1205 | | |
1206 | | typedef struct SFieldWithOptions { |
1207 | | char name[TSDB_COL_NAME_LEN]; |
1208 | | uint8_t type; |
1209 | | int8_t flags; |
1210 | | int32_t bytes; |
1211 | | uint32_t compress; |
1212 | | STypeMod typeMod; |
1213 | | } SFieldWithOptions; |
1214 | | |
1215 | | typedef struct SRetention { |
1216 | | int64_t freq; |
1217 | | int64_t keep; |
1218 | | int8_t freqUnit; |
1219 | | int8_t keepUnit; |
1220 | | } SRetention; |
1221 | | |
1222 | | #define RETENTION_VALID(l, r) ((((l) == 0 && (r)->freq >= 0) || ((r)->freq > 0)) && ((r)->keep > 0)) |
1223 | | |
1224 | | #pragma pack(push, 1) |
1225 | | // null-terminated string instead of char array to avoid too many memory consumption in case of more than 1M tableMeta |
1226 | | typedef struct SEp { |
1227 | | char fqdn[TSDB_FQDN_LEN]; |
1228 | | uint16_t port; |
1229 | | } SEp; |
1230 | | |
1231 | | typedef struct { |
1232 | | int32_t contLen; |
1233 | | int32_t vgId; |
1234 | | } SMsgHead; |
1235 | | |
1236 | | // Submit message for one table |
1237 | | typedef struct SSubmitBlk { |
1238 | | int64_t uid; // table unique id |
1239 | | int64_t suid; // stable id |
1240 | | int32_t sversion; // data schema version |
1241 | | int32_t dataLen; // data part length, not including the SSubmitBlk head |
1242 | | int32_t schemaLen; // schema length, if length is 0, no schema exists |
1243 | | int32_t numOfRows; // total number of rows in current submit block |
1244 | | char data[]; |
1245 | | } SSubmitBlk; |
1246 | | |
1247 | | // Submit message for this TSDB |
1248 | | typedef struct { |
1249 | | SMsgHead header; |
1250 | | int64_t version; |
1251 | | int32_t length; |
1252 | | int32_t numOfBlocks; |
1253 | | char blocks[]; |
1254 | | } SSubmitReq; |
1255 | | |
1256 | | typedef struct { |
1257 | | int32_t totalLen; |
1258 | | int32_t len; |
1259 | | STSRow* row; |
1260 | | } SSubmitBlkIter; |
1261 | | |
1262 | | typedef struct { |
1263 | | int32_t totalLen; |
1264 | | int32_t len; |
1265 | | // head of SSubmitBlk |
1266 | | int64_t uid; // table unique id |
1267 | | int64_t suid; // stable id |
1268 | | int32_t sversion; // data schema version |
1269 | | int32_t dataLen; // data part length, not including the SSubmitBlk head |
1270 | | int32_t schemaLen; // schema length, if length is 0, no schema exists |
1271 | | int32_t numOfRows; // total number of rows in current submit block |
1272 | | // head of SSubmitBlk |
1273 | | int32_t numOfBlocks; |
1274 | | const void* pMsg; |
1275 | | } SSubmitMsgIter; |
1276 | | |
1277 | | int32_t tInitSubmitMsgIter(const SSubmitReq* pMsg, SSubmitMsgIter* pIter); |
1278 | | int32_t tGetSubmitMsgNext(SSubmitMsgIter* pIter, SSubmitBlk** pPBlock); |
1279 | | int32_t tInitSubmitBlkIter(SSubmitMsgIter* pMsgIter, SSubmitBlk* pBlock, SSubmitBlkIter* pIter); |
1280 | | STSRow* tGetSubmitBlkNext(SSubmitBlkIter* pIter); |
1281 | | // for debug |
1282 | | int32_t tPrintFixedSchemaSubmitReq(SSubmitReq* pReq, STSchema* pSchema); |
1283 | | |
1284 | | typedef struct { |
1285 | | bool hasRef; |
1286 | | col_id_t id; |
1287 | | int8_t refType; // 0=internal, 1=external (DS section 6.2.7) |
1288 | | char refSourceName[TSDB_EXT_SOURCE_NAME_LEN]; // external source name (refType=1) |
1289 | | char refSchemaName[TSDB_EXT_SOURCE_SCHEMA_LEN]; // external schema captured at virtual-table creation (PG only) |
1290 | | char refDbName[TSDB_DB_NAME_LEN]; |
1291 | | char refTableName[TSDB_TABLE_NAME_LEN]; |
1292 | | char refColName[TSDB_COL_NAME_LEN]; |
1293 | | int32_t tagCondLen; |
1294 | | char *tagCondJson; // serialized series tag condition (JSON string from nodesNodeToString), or NULL |
1295 | | int32_t filterCondLen; |
1296 | | char *filterCondJson; // serialized MySQL/PostgreSQL column filter, or NULL |
1297 | | char colName[TSDB_COL_NAME_LEN]; // for tmq get json |
1298 | | } SColRef; |
1299 | | |
1300 | | typedef struct { |
1301 | | int32_t nCols; |
1302 | | int32_t version; |
1303 | | SColRef* pColRef; |
1304 | | int32_t nTagRefs; |
1305 | | SColRef* pTagRef; |
1306 | | } SColRefWrapper; |
1307 | | |
1308 | | int32_t tEncodeSColRefWrapper(SEncoder* pCoder, const SColRefWrapper* pWrapper); |
1309 | | int32_t tDecodeSColRefWrapperEx(SDecoder* pDecoder, SColRefWrapper* pWrapper); |
1310 | | void tFreeSColRefArray(SColRef* pColRef, int32_t nCols); |
1311 | | |
1312 | | typedef struct SSeriesEntry { |
1313 | | char alias[TSDB_COL_NAME_LEN]; |
1314 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
1315 | | char dbName[TSDB_DB_NAME_LEN]; |
1316 | | char measurementName[TSDB_TABLE_NAME_LEN]; |
1317 | | int32_t tagCondLen; |
1318 | | char* tagCondJson; |
1319 | | } SSeriesEntry; |
1320 | | |
1321 | | typedef struct SSeriesWrapper { |
1322 | | int32_t nSeries; |
1323 | | SSeriesEntry* pSeries; |
1324 | | } SSeriesWrapper; |
1325 | | |
1326 | | int32_t tEncodeSSeriesWrapper(SEncoder* pCoder, const SSeriesWrapper* pWrapper); |
1327 | | int32_t tDecodeSSeriesWrapper(SDecoder* pDecoder, SSeriesWrapper* pWrapper); |
1328 | | void tFreeSSeriesWrapper(SSeriesWrapper* pWrapper); |
1329 | | |
1330 | | typedef struct { |
1331 | | int32_t vgId; |
1332 | | SColRef colRef; |
1333 | | } SColRefEx; |
1334 | | |
1335 | | typedef struct { |
1336 | | int16_t colId; |
1337 | | char refDbName[TSDB_DB_NAME_LEN]; |
1338 | | char refTableName[TSDB_TABLE_NAME_LEN]; |
1339 | | char refColName[TSDB_COL_NAME_LEN]; |
1340 | | char refSourceName[TSDB_EXT_SOURCE_NAME_LEN]; // external source name, empty for internal refs |
1341 | | bool hasFilterCond; // saved external-column filter, including resolved leaf refs |
1342 | | } SRefColInfo; |
1343 | | |
1344 | | typedef struct SVCTableRefCols { |
1345 | | uint64_t uid; |
1346 | | int32_t numOfSrcTbls; |
1347 | | int32_t numOfColRefs; |
1348 | | SRefColInfo* refCols; |
1349 | | int32_t numOfTagRefs; |
1350 | | SRefColInfo* tagRefCols; |
1351 | | } SVCTableRefCols; |
1352 | | |
1353 | | typedef struct SVCTableMergeInfo { |
1354 | | uint64_t uid; |
1355 | | int32_t numOfSrcTbls; |
1356 | | } SVCTableMergeInfo; |
1357 | | |
1358 | | typedef struct { |
1359 | | int32_t nCols; |
1360 | | SColRefEx* pColRefEx; |
1361 | | } SColRefExWrapper; |
1362 | | |
1363 | | struct SSchema { |
1364 | | int8_t type; |
1365 | | int8_t flags; |
1366 | | col_id_t colId; |
1367 | | int32_t bytes; |
1368 | | char name[TSDB_COL_NAME_LEN]; |
1369 | | }; |
1370 | | struct SSchemaExt { |
1371 | | col_id_t colId; |
1372 | | uint32_t compress; |
1373 | | STypeMod typeMod; |
1374 | | }; |
1375 | | |
1376 | | struct SSchemaRsma { |
1377 | | int64_t interval[2]; |
1378 | | int32_t nFuncs; |
1379 | | int8_t tbType; |
1380 | | tb_uid_t tbUid; |
1381 | | func_id_t* funcIds; |
1382 | | char tbName[TSDB_TABLE_NAME_LEN]; |
1383 | | }; |
1384 | | |
1385 | | struct SSchema2 { |
1386 | | int8_t type; |
1387 | | int8_t flags; |
1388 | | col_id_t colId; |
1389 | | int32_t bytes; |
1390 | | char name[TSDB_COL_NAME_LEN]; |
1391 | | uint32_t compress; |
1392 | | }; |
1393 | | |
1394 | | typedef struct { |
1395 | | char tbName[TSDB_TABLE_NAME_LEN]; |
1396 | | char stbName[TSDB_TABLE_NAME_LEN]; |
1397 | | char dbFName[TSDB_DB_FNAME_LEN]; |
1398 | | int64_t dbId; |
1399 | | int32_t numOfTags; |
1400 | | int32_t numOfColumns; |
1401 | | int8_t precision; |
1402 | | int8_t tableType; |
1403 | | int32_t sversion; |
1404 | | int32_t tversion; |
1405 | | int32_t rversion; |
1406 | | uint64_t suid; |
1407 | | uint64_t tuid; |
1408 | | int32_t vgId; |
1409 | | union { |
1410 | | uint8_t flag; |
1411 | | struct { |
1412 | | uint8_t sysInfo : 1; |
1413 | | uint8_t isAudit : 1; |
1414 | | uint8_t privCat : 3; // ESysTblPrivCat |
1415 | | uint8_t secLvl : 3; |
1416 | | }; |
1417 | | }; |
1418 | | int64_t ownerId; |
1419 | | SSchema* pSchemas; |
1420 | | SSchemaExt* pSchemaExt; |
1421 | | int8_t virtualStb; |
1422 | | int32_t numOfColRefs; |
1423 | | SColRef* pColRefs; |
1424 | | int32_t numOfTagRefs; |
1425 | | SColRef* pTagRefs; |
1426 | | int32_t numOfSeries; |
1427 | | SSeriesEntry* pSeries; |
1428 | | int8_t secureDelete; |
1429 | | int8_t hasInheritors; // 1 if other VSTs inherit from this STB (non-leaf) |
1430 | | } STableMetaRsp; |
1431 | | |
1432 | | typedef struct { |
1433 | | int32_t code; |
1434 | | int64_t uid; |
1435 | | char* tblFName; |
1436 | | int32_t numOfRows; |
1437 | | int32_t affectedRows; |
1438 | | int64_t sver; |
1439 | | STableMetaRsp* pMeta; |
1440 | | } SSubmitBlkRsp; |
1441 | | |
1442 | | typedef struct { |
1443 | | int32_t numOfRows; |
1444 | | int32_t affectedRows; |
1445 | | int32_t nBlocks; |
1446 | | union { |
1447 | | SArray* pArray; |
1448 | | SSubmitBlkRsp* pBlocks; |
1449 | | }; |
1450 | | } SSubmitRsp; |
1451 | | |
1452 | | // int32_t tEncodeSSubmitRsp(SEncoder* pEncoder, const SSubmitRsp* pRsp); |
1453 | | // int32_t tDecodeSSubmitRsp(SDecoder* pDecoder, SSubmitRsp* pRsp); |
1454 | | // void tFreeSSubmitBlkRsp(void* param); |
1455 | | void tFreeSSubmitRsp(SSubmitRsp* pRsp); |
1456 | | |
1457 | 0 | #define COL_SMA_ON ((int8_t)0x1) |
1458 | 0 | #define COL_IDX_ON ((int8_t)0x2) |
1459 | 0 | #define COL_IS_KEY ((int8_t)0x4) |
1460 | | #define COL_SET_NULL ((int8_t)0x10) |
1461 | | #define COL_SET_VAL ((int8_t)0x20) |
1462 | 0 | #define COL_IS_SYSINFO ((int8_t)0x40) |
1463 | 0 | #define COL_HAS_TYPE_MOD ((int8_t)0x80) |
1464 | 0 | #define COL_REF_BY_STM ((int8_t)0x08) |
1465 | | |
1466 | | #define COL_IS_SET(FLG) (((FLG) & (COL_SET_VAL | COL_SET_NULL)) != 0) |
1467 | | #define COL_CLR_SET(FLG) ((FLG) &= (~(COL_SET_VAL | COL_SET_NULL))) |
1468 | | |
1469 | | #define IS_BSMA_ON(s) (((s)->flags & 0x01) == COL_SMA_ON) |
1470 | 0 | #define IS_IDX_ON(s) (((s)->flags & 0x02) == COL_IDX_ON) |
1471 | | #define IS_SET_NULL(s) (((s)->flags & COL_SET_NULL) == COL_SET_NULL) |
1472 | | |
1473 | | #define SSCHMEA_SET_IDX_ON(s) \ |
1474 | | do { \ |
1475 | | (s)->flags |= COL_IDX_ON; \ |
1476 | | } while (0) |
1477 | | |
1478 | | #define SSCHMEA_SET_IDX_OFF(s) \ |
1479 | | do { \ |
1480 | | (s)->flags &= (~COL_IDX_ON); \ |
1481 | | } while (0) |
1482 | | |
1483 | | #define SSCHEMA_SET_TYPE_MOD(s) \ |
1484 | | do { \ |
1485 | | (s)->flags |= COL_HAS_TYPE_MOD; \ |
1486 | | } while (0) |
1487 | | |
1488 | | #define HAS_TYPE_MOD(s) (((s)->flags & COL_HAS_TYPE_MOD)) |
1489 | | |
1490 | | #define SSCHMEA_TYPE(s) ((s)->type) |
1491 | | #define SSCHMEA_FLAGS(s) ((s)->flags) |
1492 | | #define SSCHMEA_COLID(s) ((s)->colId) |
1493 | | #define SSCHMEA_BYTES(s) ((s)->bytes) |
1494 | | #define SSCHMEA_NAME(s) ((s)->name) |
1495 | | |
1496 | | typedef struct { |
1497 | | bool tsEnableMonitor; |
1498 | | int32_t tsMonitorInterval; |
1499 | | int32_t tsSlowLogThreshold; |
1500 | | int32_t tsSlowLogMaxLen; |
1501 | | int32_t tsSlowLogScope; |
1502 | | int32_t tsSlowLogThresholdTest; // Obsolete |
1503 | | char tsSlowLogExceptDb[TSDB_DB_NAME_LEN]; |
1504 | | } SMonitorParas; |
1505 | | |
1506 | | typedef struct { |
1507 | | STypeMod typeMod; |
1508 | | } SExtSchema; |
1509 | | |
1510 | | bool hasExtSchema(const SExtSchema* pExtSchema); |
1511 | | |
1512 | | typedef struct { |
1513 | | int32_t nCols; |
1514 | | int32_t version; |
1515 | | SSchema* pSchema; |
1516 | | SSchemaRsma* pRsma; |
1517 | | } SSchemaWrapper; |
1518 | | |
1519 | | typedef struct { |
1520 | | col_id_t id; |
1521 | | uint32_t alg; |
1522 | | } SColCmpr; |
1523 | | |
1524 | | typedef struct { |
1525 | | int32_t nCols; |
1526 | | int32_t version; |
1527 | | SColCmpr* pColCmpr; |
1528 | | } SColCmprWrapper; |
1529 | | |
1530 | 0 | static FORCE_INLINE int32_t tInitDefaultSColRefWrapperByCols(SColRefWrapper* pRef, int32_t nCols) { |
1531 | 0 | if (pRef->pColRef) { |
1532 | 0 | return TSDB_CODE_INVALID_PARA; |
1533 | 0 | } |
1534 | 0 | pRef->pColRef = (SColRef*)taosMemoryCalloc(nCols, sizeof(SColRef)); |
1535 | 0 | if (pRef->pColRef == NULL) { |
1536 | 0 | return terrno; |
1537 | 0 | } |
1538 | 0 | pRef->nCols = nCols; |
1539 | 0 | for (int32_t i = 0; i < nCols; i++) { |
1540 | 0 | pRef->pColRef[i].hasRef = false; |
1541 | 0 | pRef->pColRef[i].id = (col_id_t)(i + 1); |
1542 | 0 | } |
1543 | 0 | return 0; |
1544 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parser.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parTranslater.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parUtil.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parAstParser.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parAuthenticator.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parCalcConst.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parInsertSql.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parInsertUtil.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: taos_lemon_sql.tab.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parAstCreater.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: parInsertSml.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planner.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planLogicCreater.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planOptimizer.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planPhysiCreater.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planScaleOut.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planSpliter.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planUtil.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: planValidator.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: catalog.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgAsync.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgCache.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgDbg.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgRemote.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgRent.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ctgUtil.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: extConnector.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: extDialect.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: extDialectDefaults.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: functionMgt.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tudf.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: builtins.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: builtinsimpl.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: spillDistinctSet.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: thistogram.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tpercentile.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tavgfunction.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tminmax.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tminmaxavx.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: filter.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: scalar.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: sclfunc.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: sclvector.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesCloneFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesCodeFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesEqualFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesMatchFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesMsgFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesRemotePlanToSQL.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesToSQLFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesTraverseFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: nodesUtilFuncs.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: extTypeMap.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: queryUtil.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: querymsg.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: trans.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: transCli.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: transComm.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: transSasl.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: transSvr.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: transTLS.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: thttp.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: geomFunc.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tconfig.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tdigest.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tlog.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tmempool.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tpagedbuf.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: mpDirect.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: extCapability.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: systable.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tanalytics.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tdatablock.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tdataformat.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tglobal.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tmisce.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tname.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tpriv.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: ttime.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tvariant.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: streamMsg.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: streamWindowPlan.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tmsg.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: xnode.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: tencrypt.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: streamJson.c:tInitDefaultSColRefWrapperByCols Unexecuted instantiation: crypt.c:tInitDefaultSColRefWrapperByCols |
1545 | | |
1546 | 0 | static FORCE_INLINE int32_t tInitDefaultSColRefWrapperByTags(SColRefWrapper* pRef, int32_t nTags, col_id_t startColId) { |
1547 | 0 | if (pRef->pTagRef) { |
1548 | 0 | return TSDB_CODE_INVALID_PARA; |
1549 | 0 | } |
1550 | 0 | pRef->pTagRef = (SColRef*)taosMemoryCalloc(nTags, sizeof(SColRef)); |
1551 | 0 | if (pRef->pTagRef == NULL) { |
1552 | 0 | return terrno; |
1553 | 0 | } |
1554 | 0 | pRef->nTagRefs = nTags; |
1555 | 0 | for (int32_t i = 0; i < nTags; i++) { |
1556 | 0 | pRef->pTagRef[i].hasRef = false; |
1557 | 0 | pRef->pTagRef[i].id = (col_id_t)(startColId + i); |
1558 | 0 | } |
1559 | 0 | return 0; |
1560 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parser.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parTranslater.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parUtil.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parAstParser.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parAuthenticator.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parCalcConst.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parInsertSql.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parInsertUtil.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: taos_lemon_sql.tab.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parAstCreater.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: parInsertSml.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planner.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planLogicCreater.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planOptimizer.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planPhysiCreater.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planScaleOut.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planSpliter.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planUtil.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: planValidator.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: catalog.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgAsync.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgCache.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgDbg.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgRemote.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgRent.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ctgUtil.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: extConnector.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: extDialect.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: extDialectDefaults.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: functionMgt.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tudf.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: builtins.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: builtinsimpl.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: spillDistinctSet.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: thistogram.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tpercentile.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tavgfunction.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tminmax.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tminmaxavx.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: filter.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: scalar.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: sclfunc.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: sclvector.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesCloneFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesCodeFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesEqualFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesMatchFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesMsgFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesRemotePlanToSQL.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesToSQLFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesTraverseFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: nodesUtilFuncs.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: extTypeMap.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: queryUtil.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: querymsg.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: trans.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: transCli.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: transComm.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: transSasl.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: transSvr.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: transTLS.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: thttp.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: geomFunc.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tconfig.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tdigest.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tlog.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tmempool.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tpagedbuf.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: mpDirect.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: extCapability.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: systable.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tanalytics.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tdatablock.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tdataformat.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tglobal.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tmisce.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tname.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tpriv.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: ttime.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tvariant.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: streamMsg.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: streamWindowPlan.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tmsg.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: xnode.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: tencrypt.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: streamJson.c:tInitDefaultSColRefWrapperByTags Unexecuted instantiation: crypt.c:tInitDefaultSColRefWrapperByTags |
1561 | | |
1562 | 0 | static FORCE_INLINE SColCmprWrapper* tCloneSColCmprWrapper(const SColCmprWrapper* pSrcWrapper) { |
1563 | 0 | if (pSrcWrapper->pColCmpr == NULL || pSrcWrapper->nCols == 0) { |
1564 | 0 | terrno = TSDB_CODE_INVALID_PARA; |
1565 | 0 | return NULL; |
1566 | 0 | } |
1567 | 0 |
|
1568 | 0 | SColCmprWrapper* pDstWrapper = (SColCmprWrapper*)taosMemoryMalloc(sizeof(SColCmprWrapper)); |
1569 | 0 | if (pDstWrapper == NULL) { |
1570 | 0 | return NULL; |
1571 | 0 | } |
1572 | 0 | pDstWrapper->nCols = pSrcWrapper->nCols; |
1573 | 0 | pDstWrapper->version = pSrcWrapper->version; |
1574 | 0 |
|
1575 | 0 | int32_t size = sizeof(SColCmpr) * pDstWrapper->nCols; |
1576 | 0 | pDstWrapper->pColCmpr = (SColCmpr*)taosMemoryCalloc(1, size); |
1577 | 0 | if (pDstWrapper->pColCmpr == NULL) { |
1578 | 0 | taosMemoryFree(pDstWrapper); |
1579 | 0 | return NULL; |
1580 | 0 | } |
1581 | 0 | (void)memcpy(pDstWrapper->pColCmpr, pSrcWrapper->pColCmpr, size); |
1582 | 0 |
|
1583 | 0 | return pDstWrapper; |
1584 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tCloneSColCmprWrapper Unexecuted instantiation: parser.c:tCloneSColCmprWrapper Unexecuted instantiation: parTranslater.c:tCloneSColCmprWrapper Unexecuted instantiation: parUtil.c:tCloneSColCmprWrapper Unexecuted instantiation: parAstParser.c:tCloneSColCmprWrapper Unexecuted instantiation: parAuthenticator.c:tCloneSColCmprWrapper Unexecuted instantiation: parCalcConst.c:tCloneSColCmprWrapper Unexecuted instantiation: parInsertSql.c:tCloneSColCmprWrapper Unexecuted instantiation: parInsertUtil.c:tCloneSColCmprWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tCloneSColCmprWrapper Unexecuted instantiation: parAstCreater.c:tCloneSColCmprWrapper Unexecuted instantiation: parInsertSml.c:tCloneSColCmprWrapper Unexecuted instantiation: planner.c:tCloneSColCmprWrapper Unexecuted instantiation: planLogicCreater.c:tCloneSColCmprWrapper Unexecuted instantiation: planOptimizer.c:tCloneSColCmprWrapper Unexecuted instantiation: planPhysiCreater.c:tCloneSColCmprWrapper Unexecuted instantiation: planScaleOut.c:tCloneSColCmprWrapper Unexecuted instantiation: planSpliter.c:tCloneSColCmprWrapper Unexecuted instantiation: planUtil.c:tCloneSColCmprWrapper Unexecuted instantiation: planValidator.c:tCloneSColCmprWrapper Unexecuted instantiation: catalog.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgAsync.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgCache.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgDbg.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgRemote.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgRent.c:tCloneSColCmprWrapper Unexecuted instantiation: ctgUtil.c:tCloneSColCmprWrapper Unexecuted instantiation: extConnector.c:tCloneSColCmprWrapper Unexecuted instantiation: extDialect.c:tCloneSColCmprWrapper Unexecuted instantiation: extDialectDefaults.c:tCloneSColCmprWrapper Unexecuted instantiation: functionMgt.c:tCloneSColCmprWrapper Unexecuted instantiation: tudf.c:tCloneSColCmprWrapper Unexecuted instantiation: builtins.c:tCloneSColCmprWrapper Unexecuted instantiation: builtinsimpl.c:tCloneSColCmprWrapper Unexecuted instantiation: spillDistinctSet.c:tCloneSColCmprWrapper Unexecuted instantiation: thistogram.c:tCloneSColCmprWrapper Unexecuted instantiation: tpercentile.c:tCloneSColCmprWrapper Unexecuted instantiation: tavgfunction.c:tCloneSColCmprWrapper Unexecuted instantiation: tminmax.c:tCloneSColCmprWrapper Unexecuted instantiation: tminmaxavx.c:tCloneSColCmprWrapper Unexecuted instantiation: filter.c:tCloneSColCmprWrapper Unexecuted instantiation: scalar.c:tCloneSColCmprWrapper Unexecuted instantiation: sclfunc.c:tCloneSColCmprWrapper Unexecuted instantiation: sclvector.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesCloneFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesCodeFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesEqualFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesMatchFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesMsgFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: nodesUtilFuncs.c:tCloneSColCmprWrapper Unexecuted instantiation: extTypeMap.c:tCloneSColCmprWrapper Unexecuted instantiation: queryUtil.c:tCloneSColCmprWrapper Unexecuted instantiation: querymsg.c:tCloneSColCmprWrapper Unexecuted instantiation: trans.c:tCloneSColCmprWrapper Unexecuted instantiation: transCli.c:tCloneSColCmprWrapper Unexecuted instantiation: transComm.c:tCloneSColCmprWrapper Unexecuted instantiation: transSasl.c:tCloneSColCmprWrapper Unexecuted instantiation: transSvr.c:tCloneSColCmprWrapper Unexecuted instantiation: transTLS.c:tCloneSColCmprWrapper Unexecuted instantiation: thttp.c:tCloneSColCmprWrapper Unexecuted instantiation: geomFunc.c:tCloneSColCmprWrapper Unexecuted instantiation: tconfig.c:tCloneSColCmprWrapper Unexecuted instantiation: tdigest.c:tCloneSColCmprWrapper Unexecuted instantiation: tlog.c:tCloneSColCmprWrapper Unexecuted instantiation: tmempool.c:tCloneSColCmprWrapper Unexecuted instantiation: tpagedbuf.c:tCloneSColCmprWrapper Unexecuted instantiation: mpDirect.c:tCloneSColCmprWrapper Unexecuted instantiation: extCapability.c:tCloneSColCmprWrapper Unexecuted instantiation: systable.c:tCloneSColCmprWrapper Unexecuted instantiation: tanalytics.c:tCloneSColCmprWrapper Unexecuted instantiation: tdatablock.c:tCloneSColCmprWrapper Unexecuted instantiation: tdataformat.c:tCloneSColCmprWrapper Unexecuted instantiation: tglobal.c:tCloneSColCmprWrapper Unexecuted instantiation: tmisce.c:tCloneSColCmprWrapper Unexecuted instantiation: tname.c:tCloneSColCmprWrapper Unexecuted instantiation: tpriv.c:tCloneSColCmprWrapper Unexecuted instantiation: ttime.c:tCloneSColCmprWrapper Unexecuted instantiation: tvariant.c:tCloneSColCmprWrapper Unexecuted instantiation: streamMsg.c:tCloneSColCmprWrapper Unexecuted instantiation: streamWindowPlan.c:tCloneSColCmprWrapper Unexecuted instantiation: tmsg.c:tCloneSColCmprWrapper Unexecuted instantiation: xnode.c:tCloneSColCmprWrapper Unexecuted instantiation: tencrypt.c:tCloneSColCmprWrapper Unexecuted instantiation: streamJson.c:tCloneSColCmprWrapper Unexecuted instantiation: crypt.c:tCloneSColCmprWrapper |
1585 | | |
1586 | 0 | static FORCE_INLINE int32_t tInitDefaultSColCmprWrapperByCols(SColCmprWrapper* pCmpr, int32_t nCols) { |
1587 | 0 | if (!(!pCmpr->pColCmpr)) { |
1588 | 0 | return TSDB_CODE_INVALID_PARA; |
1589 | 0 | } |
1590 | 0 | pCmpr->pColCmpr = (SColCmpr*)taosMemoryCalloc(nCols, sizeof(SColCmpr)); |
1591 | 0 | if (pCmpr->pColCmpr == NULL) { |
1592 | 0 | return terrno; |
1593 | 0 | } |
1594 | 0 | pCmpr->nCols = nCols; |
1595 | 0 | return 0; |
1596 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parser.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parTranslater.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parUtil.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parAstParser.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parAuthenticator.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parCalcConst.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parInsertSql.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parInsertUtil.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: taos_lemon_sql.tab.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parAstCreater.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: parInsertSml.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planner.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planLogicCreater.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planOptimizer.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planPhysiCreater.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planScaleOut.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planSpliter.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planUtil.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: planValidator.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: catalog.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgAsync.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgCache.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgDbg.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgRemote.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgRent.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ctgUtil.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: extConnector.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: extDialect.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: extDialectDefaults.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: functionMgt.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tudf.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: builtins.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: builtinsimpl.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: spillDistinctSet.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: thistogram.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tpercentile.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tavgfunction.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tminmax.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tminmaxavx.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: filter.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: scalar.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: sclfunc.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: sclvector.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesCloneFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesCodeFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesEqualFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesMatchFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesMsgFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesRemotePlanToSQL.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesToSQLFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesTraverseFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: nodesUtilFuncs.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: extTypeMap.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: queryUtil.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: querymsg.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: trans.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: transCli.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: transComm.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: transSasl.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: transSvr.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: transTLS.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: thttp.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: geomFunc.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tconfig.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tdigest.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tlog.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tmempool.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tpagedbuf.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: mpDirect.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: extCapability.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: systable.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tanalytics.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tdatablock.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tdataformat.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tglobal.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tmisce.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tname.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tpriv.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: ttime.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tvariant.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: streamMsg.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: streamWindowPlan.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tmsg.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: xnode.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: tencrypt.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: streamJson.c:tInitDefaultSColCmprWrapperByCols Unexecuted instantiation: crypt.c:tInitDefaultSColCmprWrapperByCols |
1597 | | |
1598 | 0 | static FORCE_INLINE int32_t tInitDefaultSColCmprWrapper(SColCmprWrapper* pCmpr, SSchemaWrapper* pSchema) { |
1599 | 0 | pCmpr->nCols = pSchema->nCols; |
1600 | 0 | if (!(!pCmpr->pColCmpr)) { |
1601 | 0 | return TSDB_CODE_INVALID_PARA; |
1602 | 0 | } |
1603 | 0 | pCmpr->pColCmpr = (SColCmpr*)taosMemoryCalloc(pCmpr->nCols, sizeof(SColCmpr)); |
1604 | 0 | if (pCmpr->pColCmpr == NULL) { |
1605 | 0 | return terrno; |
1606 | 0 | } |
1607 | 0 | for (int32_t i = 0; i < pCmpr->nCols; i++) { |
1608 | 0 | SColCmpr* pColCmpr = &pCmpr->pColCmpr[i]; |
1609 | 0 | SSchema* pColSchema = &pSchema->pSchema[i]; |
1610 | 0 | pColCmpr->id = pColSchema->colId; |
1611 | 0 | pColCmpr->alg = 0; |
1612 | 0 | } |
1613 | 0 | return 0; |
1614 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parser.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parTranslater.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parUtil.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parAstParser.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parAuthenticator.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parCalcConst.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parInsertSql.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parInsertUtil.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parAstCreater.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: parInsertSml.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planner.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planLogicCreater.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planOptimizer.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planPhysiCreater.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planScaleOut.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planSpliter.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planUtil.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: planValidator.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: catalog.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgAsync.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgCache.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgDbg.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgRemote.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgRent.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ctgUtil.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: extConnector.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: extDialect.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: extDialectDefaults.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: functionMgt.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tudf.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: builtins.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: builtinsimpl.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: spillDistinctSet.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: thistogram.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tpercentile.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tavgfunction.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tminmax.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tminmaxavx.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: filter.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: scalar.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: sclfunc.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: sclvector.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesCloneFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesCodeFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesEqualFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesMatchFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesMsgFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: nodesUtilFuncs.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: extTypeMap.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: queryUtil.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: querymsg.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: trans.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: transCli.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: transComm.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: transSasl.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: transSvr.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: transTLS.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: thttp.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: geomFunc.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tconfig.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tdigest.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tlog.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tmempool.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tpagedbuf.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: mpDirect.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: extCapability.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: systable.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tanalytics.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tdatablock.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tdataformat.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tglobal.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tmisce.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tname.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tpriv.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: ttime.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tvariant.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: streamMsg.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: streamWindowPlan.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tmsg.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: xnode.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: tencrypt.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: streamJson.c:tInitDefaultSColCmprWrapper Unexecuted instantiation: crypt.c:tInitDefaultSColCmprWrapper |
1615 | | |
1616 | 0 | static FORCE_INLINE void tDeleteSColCmprWrapper(SColCmprWrapper* pWrapper) { |
1617 | 0 | if (pWrapper == NULL) return; |
1618 | 0 |
|
1619 | 0 | taosMemoryFreeClear(pWrapper->pColCmpr); |
1620 | 0 | taosMemoryFreeClear(pWrapper); |
1621 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDeleteSColCmprWrapper Unexecuted instantiation: parser.c:tDeleteSColCmprWrapper Unexecuted instantiation: parTranslater.c:tDeleteSColCmprWrapper Unexecuted instantiation: parUtil.c:tDeleteSColCmprWrapper Unexecuted instantiation: parAstParser.c:tDeleteSColCmprWrapper Unexecuted instantiation: parAuthenticator.c:tDeleteSColCmprWrapper Unexecuted instantiation: parCalcConst.c:tDeleteSColCmprWrapper Unexecuted instantiation: parInsertSql.c:tDeleteSColCmprWrapper Unexecuted instantiation: parInsertUtil.c:tDeleteSColCmprWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDeleteSColCmprWrapper Unexecuted instantiation: parAstCreater.c:tDeleteSColCmprWrapper Unexecuted instantiation: parInsertSml.c:tDeleteSColCmprWrapper Unexecuted instantiation: planner.c:tDeleteSColCmprWrapper Unexecuted instantiation: planLogicCreater.c:tDeleteSColCmprWrapper Unexecuted instantiation: planOptimizer.c:tDeleteSColCmprWrapper Unexecuted instantiation: planPhysiCreater.c:tDeleteSColCmprWrapper Unexecuted instantiation: planScaleOut.c:tDeleteSColCmprWrapper Unexecuted instantiation: planSpliter.c:tDeleteSColCmprWrapper Unexecuted instantiation: planUtil.c:tDeleteSColCmprWrapper Unexecuted instantiation: planValidator.c:tDeleteSColCmprWrapper Unexecuted instantiation: catalog.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgAsync.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgCache.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgDbg.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgRemote.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgRent.c:tDeleteSColCmprWrapper Unexecuted instantiation: ctgUtil.c:tDeleteSColCmprWrapper Unexecuted instantiation: extConnector.c:tDeleteSColCmprWrapper Unexecuted instantiation: extDialect.c:tDeleteSColCmprWrapper Unexecuted instantiation: extDialectDefaults.c:tDeleteSColCmprWrapper Unexecuted instantiation: functionMgt.c:tDeleteSColCmprWrapper Unexecuted instantiation: tudf.c:tDeleteSColCmprWrapper Unexecuted instantiation: builtins.c:tDeleteSColCmprWrapper Unexecuted instantiation: builtinsimpl.c:tDeleteSColCmprWrapper Unexecuted instantiation: spillDistinctSet.c:tDeleteSColCmprWrapper Unexecuted instantiation: thistogram.c:tDeleteSColCmprWrapper Unexecuted instantiation: tpercentile.c:tDeleteSColCmprWrapper Unexecuted instantiation: tavgfunction.c:tDeleteSColCmprWrapper Unexecuted instantiation: tminmax.c:tDeleteSColCmprWrapper Unexecuted instantiation: tminmaxavx.c:tDeleteSColCmprWrapper Unexecuted instantiation: filter.c:tDeleteSColCmprWrapper Unexecuted instantiation: scalar.c:tDeleteSColCmprWrapper Unexecuted instantiation: sclfunc.c:tDeleteSColCmprWrapper Unexecuted instantiation: sclvector.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDeleteSColCmprWrapper Unexecuted instantiation: extTypeMap.c:tDeleteSColCmprWrapper Unexecuted instantiation: queryUtil.c:tDeleteSColCmprWrapper Unexecuted instantiation: querymsg.c:tDeleteSColCmprWrapper Unexecuted instantiation: trans.c:tDeleteSColCmprWrapper Unexecuted instantiation: transCli.c:tDeleteSColCmprWrapper Unexecuted instantiation: transComm.c:tDeleteSColCmprWrapper Unexecuted instantiation: transSasl.c:tDeleteSColCmprWrapper Unexecuted instantiation: transSvr.c:tDeleteSColCmprWrapper Unexecuted instantiation: transTLS.c:tDeleteSColCmprWrapper Unexecuted instantiation: thttp.c:tDeleteSColCmprWrapper Unexecuted instantiation: geomFunc.c:tDeleteSColCmprWrapper Unexecuted instantiation: tconfig.c:tDeleteSColCmprWrapper Unexecuted instantiation: tdigest.c:tDeleteSColCmprWrapper Unexecuted instantiation: tlog.c:tDeleteSColCmprWrapper Unexecuted instantiation: tmempool.c:tDeleteSColCmprWrapper Unexecuted instantiation: tpagedbuf.c:tDeleteSColCmprWrapper Unexecuted instantiation: mpDirect.c:tDeleteSColCmprWrapper Unexecuted instantiation: extCapability.c:tDeleteSColCmprWrapper Unexecuted instantiation: systable.c:tDeleteSColCmprWrapper Unexecuted instantiation: tanalytics.c:tDeleteSColCmprWrapper Unexecuted instantiation: tdatablock.c:tDeleteSColCmprWrapper Unexecuted instantiation: tdataformat.c:tDeleteSColCmprWrapper Unexecuted instantiation: tglobal.c:tDeleteSColCmprWrapper Unexecuted instantiation: tmisce.c:tDeleteSColCmprWrapper Unexecuted instantiation: tname.c:tDeleteSColCmprWrapper Unexecuted instantiation: tpriv.c:tDeleteSColCmprWrapper Unexecuted instantiation: ttime.c:tDeleteSColCmprWrapper Unexecuted instantiation: tvariant.c:tDeleteSColCmprWrapper Unexecuted instantiation: streamMsg.c:tDeleteSColCmprWrapper Unexecuted instantiation: streamWindowPlan.c:tDeleteSColCmprWrapper Unexecuted instantiation: tmsg.c:tDeleteSColCmprWrapper Unexecuted instantiation: xnode.c:tDeleteSColCmprWrapper Unexecuted instantiation: tencrypt.c:tDeleteSColCmprWrapper Unexecuted instantiation: streamJson.c:tDeleteSColCmprWrapper Unexecuted instantiation: crypt.c:tDeleteSColCmprWrapper |
1622 | 0 | static FORCE_INLINE SSchemaWrapper* tCloneSSchemaWrapper(const SSchemaWrapper* pSchemaWrapper) { |
1623 | 0 | if (pSchemaWrapper->pSchema == NULL) return NULL; |
1624 | 0 |
|
1625 | 0 | SSchemaWrapper* pSW = (SSchemaWrapper*)taosMemoryCalloc(1, sizeof(SSchemaWrapper)); |
1626 | 0 | if (pSW == NULL) { |
1627 | 0 | return NULL; |
1628 | 0 | } |
1629 | 0 | pSW->nCols = pSchemaWrapper->nCols; |
1630 | 0 | pSW->version = pSchemaWrapper->version; |
1631 | 0 | pSW->pSchema = (SSchema*)taosMemoryCalloc(pSW->nCols, sizeof(SSchema)); |
1632 | 0 | if (pSW->pSchema == NULL) { |
1633 | 0 | taosMemoryFree(pSW); |
1634 | 0 | return NULL; |
1635 | 0 | } |
1636 | 0 |
|
1637 | 0 | (void)memcpy(pSW->pSchema, pSchemaWrapper->pSchema, pSW->nCols * sizeof(SSchema)); |
1638 | 0 | return pSW; |
1639 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tCloneSSchemaWrapper Unexecuted instantiation: parser.c:tCloneSSchemaWrapper Unexecuted instantiation: parTranslater.c:tCloneSSchemaWrapper Unexecuted instantiation: parUtil.c:tCloneSSchemaWrapper Unexecuted instantiation: parAstParser.c:tCloneSSchemaWrapper Unexecuted instantiation: parAuthenticator.c:tCloneSSchemaWrapper Unexecuted instantiation: parCalcConst.c:tCloneSSchemaWrapper Unexecuted instantiation: parInsertSql.c:tCloneSSchemaWrapper Unexecuted instantiation: parInsertUtil.c:tCloneSSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tCloneSSchemaWrapper Unexecuted instantiation: parAstCreater.c:tCloneSSchemaWrapper Unexecuted instantiation: parInsertSml.c:tCloneSSchemaWrapper Unexecuted instantiation: planner.c:tCloneSSchemaWrapper Unexecuted instantiation: planLogicCreater.c:tCloneSSchemaWrapper Unexecuted instantiation: planOptimizer.c:tCloneSSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:tCloneSSchemaWrapper Unexecuted instantiation: planScaleOut.c:tCloneSSchemaWrapper Unexecuted instantiation: planSpliter.c:tCloneSSchemaWrapper Unexecuted instantiation: planUtil.c:tCloneSSchemaWrapper Unexecuted instantiation: planValidator.c:tCloneSSchemaWrapper Unexecuted instantiation: catalog.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgAsync.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgCache.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgDbg.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgRemote.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgRent.c:tCloneSSchemaWrapper Unexecuted instantiation: ctgUtil.c:tCloneSSchemaWrapper Unexecuted instantiation: extConnector.c:tCloneSSchemaWrapper Unexecuted instantiation: extDialect.c:tCloneSSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:tCloneSSchemaWrapper Unexecuted instantiation: functionMgt.c:tCloneSSchemaWrapper Unexecuted instantiation: tudf.c:tCloneSSchemaWrapper Unexecuted instantiation: builtins.c:tCloneSSchemaWrapper Unexecuted instantiation: builtinsimpl.c:tCloneSSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:tCloneSSchemaWrapper Unexecuted instantiation: thistogram.c:tCloneSSchemaWrapper Unexecuted instantiation: tpercentile.c:tCloneSSchemaWrapper Unexecuted instantiation: tavgfunction.c:tCloneSSchemaWrapper Unexecuted instantiation: tminmax.c:tCloneSSchemaWrapper Unexecuted instantiation: tminmaxavx.c:tCloneSSchemaWrapper Unexecuted instantiation: filter.c:tCloneSSchemaWrapper Unexecuted instantiation: scalar.c:tCloneSSchemaWrapper Unexecuted instantiation: sclfunc.c:tCloneSSchemaWrapper Unexecuted instantiation: sclvector.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tCloneSSchemaWrapper Unexecuted instantiation: extTypeMap.c:tCloneSSchemaWrapper Unexecuted instantiation: queryUtil.c:tCloneSSchemaWrapper Unexecuted instantiation: querymsg.c:tCloneSSchemaWrapper Unexecuted instantiation: trans.c:tCloneSSchemaWrapper Unexecuted instantiation: transCli.c:tCloneSSchemaWrapper Unexecuted instantiation: transComm.c:tCloneSSchemaWrapper Unexecuted instantiation: transSasl.c:tCloneSSchemaWrapper Unexecuted instantiation: transSvr.c:tCloneSSchemaWrapper Unexecuted instantiation: transTLS.c:tCloneSSchemaWrapper Unexecuted instantiation: thttp.c:tCloneSSchemaWrapper Unexecuted instantiation: geomFunc.c:tCloneSSchemaWrapper Unexecuted instantiation: tconfig.c:tCloneSSchemaWrapper Unexecuted instantiation: tdigest.c:tCloneSSchemaWrapper Unexecuted instantiation: tlog.c:tCloneSSchemaWrapper Unexecuted instantiation: tmempool.c:tCloneSSchemaWrapper Unexecuted instantiation: tpagedbuf.c:tCloneSSchemaWrapper Unexecuted instantiation: mpDirect.c:tCloneSSchemaWrapper Unexecuted instantiation: extCapability.c:tCloneSSchemaWrapper Unexecuted instantiation: systable.c:tCloneSSchemaWrapper Unexecuted instantiation: tanalytics.c:tCloneSSchemaWrapper Unexecuted instantiation: tdatablock.c:tCloneSSchemaWrapper Unexecuted instantiation: tdataformat.c:tCloneSSchemaWrapper Unexecuted instantiation: tglobal.c:tCloneSSchemaWrapper Unexecuted instantiation: tmisce.c:tCloneSSchemaWrapper Unexecuted instantiation: tname.c:tCloneSSchemaWrapper Unexecuted instantiation: tpriv.c:tCloneSSchemaWrapper Unexecuted instantiation: ttime.c:tCloneSSchemaWrapper Unexecuted instantiation: tvariant.c:tCloneSSchemaWrapper Unexecuted instantiation: streamMsg.c:tCloneSSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:tCloneSSchemaWrapper Unexecuted instantiation: tmsg.c:tCloneSSchemaWrapper Unexecuted instantiation: xnode.c:tCloneSSchemaWrapper Unexecuted instantiation: tencrypt.c:tCloneSSchemaWrapper Unexecuted instantiation: streamJson.c:tCloneSSchemaWrapper Unexecuted instantiation: crypt.c:tCloneSSchemaWrapper |
1640 | | |
1641 | 0 | static FORCE_INLINE void tDeleteSchemaWrapper(SSchemaWrapper* pSchemaWrapper) { |
1642 | 0 | if (pSchemaWrapper) { |
1643 | 0 | taosMemoryFree(pSchemaWrapper->pSchema); |
1644 | 0 | if (pSchemaWrapper->pRsma) { |
1645 | 0 | taosMemoryFreeClear(pSchemaWrapper->pRsma->funcIds); |
1646 | 0 | taosMemoryFreeClear(pSchemaWrapper->pRsma); |
1647 | 0 | } |
1648 | 0 | taosMemoryFree(pSchemaWrapper); |
1649 | 0 | } |
1650 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDeleteSchemaWrapper Unexecuted instantiation: parser.c:tDeleteSchemaWrapper Unexecuted instantiation: parTranslater.c:tDeleteSchemaWrapper Unexecuted instantiation: parUtil.c:tDeleteSchemaWrapper Unexecuted instantiation: parAstParser.c:tDeleteSchemaWrapper Unexecuted instantiation: parAuthenticator.c:tDeleteSchemaWrapper Unexecuted instantiation: parCalcConst.c:tDeleteSchemaWrapper Unexecuted instantiation: parInsertSql.c:tDeleteSchemaWrapper Unexecuted instantiation: parInsertUtil.c:tDeleteSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDeleteSchemaWrapper Unexecuted instantiation: parAstCreater.c:tDeleteSchemaWrapper Unexecuted instantiation: parInsertSml.c:tDeleteSchemaWrapper Unexecuted instantiation: planner.c:tDeleteSchemaWrapper Unexecuted instantiation: planLogicCreater.c:tDeleteSchemaWrapper Unexecuted instantiation: planOptimizer.c:tDeleteSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:tDeleteSchemaWrapper Unexecuted instantiation: planScaleOut.c:tDeleteSchemaWrapper Unexecuted instantiation: planSpliter.c:tDeleteSchemaWrapper Unexecuted instantiation: planUtil.c:tDeleteSchemaWrapper Unexecuted instantiation: planValidator.c:tDeleteSchemaWrapper Unexecuted instantiation: catalog.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgAsync.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgCache.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgDbg.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgRemote.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgRent.c:tDeleteSchemaWrapper Unexecuted instantiation: ctgUtil.c:tDeleteSchemaWrapper Unexecuted instantiation: extConnector.c:tDeleteSchemaWrapper Unexecuted instantiation: extDialect.c:tDeleteSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:tDeleteSchemaWrapper Unexecuted instantiation: functionMgt.c:tDeleteSchemaWrapper Unexecuted instantiation: tudf.c:tDeleteSchemaWrapper Unexecuted instantiation: builtins.c:tDeleteSchemaWrapper Unexecuted instantiation: builtinsimpl.c:tDeleteSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:tDeleteSchemaWrapper Unexecuted instantiation: thistogram.c:tDeleteSchemaWrapper Unexecuted instantiation: tpercentile.c:tDeleteSchemaWrapper Unexecuted instantiation: tavgfunction.c:tDeleteSchemaWrapper Unexecuted instantiation: tminmax.c:tDeleteSchemaWrapper Unexecuted instantiation: tminmaxavx.c:tDeleteSchemaWrapper Unexecuted instantiation: filter.c:tDeleteSchemaWrapper Unexecuted instantiation: scalar.c:tDeleteSchemaWrapper Unexecuted instantiation: sclfunc.c:tDeleteSchemaWrapper Unexecuted instantiation: sclvector.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDeleteSchemaWrapper Unexecuted instantiation: extTypeMap.c:tDeleteSchemaWrapper Unexecuted instantiation: queryUtil.c:tDeleteSchemaWrapper Unexecuted instantiation: querymsg.c:tDeleteSchemaWrapper Unexecuted instantiation: trans.c:tDeleteSchemaWrapper Unexecuted instantiation: transCli.c:tDeleteSchemaWrapper Unexecuted instantiation: transComm.c:tDeleteSchemaWrapper Unexecuted instantiation: transSasl.c:tDeleteSchemaWrapper Unexecuted instantiation: transSvr.c:tDeleteSchemaWrapper Unexecuted instantiation: transTLS.c:tDeleteSchemaWrapper Unexecuted instantiation: thttp.c:tDeleteSchemaWrapper Unexecuted instantiation: geomFunc.c:tDeleteSchemaWrapper Unexecuted instantiation: tconfig.c:tDeleteSchemaWrapper Unexecuted instantiation: tdigest.c:tDeleteSchemaWrapper Unexecuted instantiation: tlog.c:tDeleteSchemaWrapper Unexecuted instantiation: tmempool.c:tDeleteSchemaWrapper Unexecuted instantiation: tpagedbuf.c:tDeleteSchemaWrapper Unexecuted instantiation: mpDirect.c:tDeleteSchemaWrapper Unexecuted instantiation: extCapability.c:tDeleteSchemaWrapper Unexecuted instantiation: systable.c:tDeleteSchemaWrapper Unexecuted instantiation: tanalytics.c:tDeleteSchemaWrapper Unexecuted instantiation: tdatablock.c:tDeleteSchemaWrapper Unexecuted instantiation: tdataformat.c:tDeleteSchemaWrapper Unexecuted instantiation: tglobal.c:tDeleteSchemaWrapper Unexecuted instantiation: tmisce.c:tDeleteSchemaWrapper Unexecuted instantiation: tname.c:tDeleteSchemaWrapper Unexecuted instantiation: tpriv.c:tDeleteSchemaWrapper Unexecuted instantiation: ttime.c:tDeleteSchemaWrapper Unexecuted instantiation: tvariant.c:tDeleteSchemaWrapper Unexecuted instantiation: streamMsg.c:tDeleteSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:tDeleteSchemaWrapper Unexecuted instantiation: tmsg.c:tDeleteSchemaWrapper Unexecuted instantiation: xnode.c:tDeleteSchemaWrapper Unexecuted instantiation: tencrypt.c:tDeleteSchemaWrapper Unexecuted instantiation: streamJson.c:tDeleteSchemaWrapper Unexecuted instantiation: crypt.c:tDeleteSchemaWrapper |
1651 | | |
1652 | 0 | static FORCE_INLINE void tDestroySchemaWrapper(SSchemaWrapper* pSchemaWrapper) { |
1653 | 0 | if (pSchemaWrapper) { |
1654 | 0 | taosMemoryFreeClear(pSchemaWrapper->pSchema); |
1655 | 0 | if (pSchemaWrapper->pRsma) { |
1656 | 0 | taosMemoryFreeClear(pSchemaWrapper->pRsma->funcIds); |
1657 | 0 | taosMemoryFreeClear(pSchemaWrapper->pRsma); |
1658 | 0 | } |
1659 | 0 | } |
1660 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDestroySchemaWrapper Unexecuted instantiation: parser.c:tDestroySchemaWrapper Unexecuted instantiation: parTranslater.c:tDestroySchemaWrapper Unexecuted instantiation: parUtil.c:tDestroySchemaWrapper Unexecuted instantiation: parAstParser.c:tDestroySchemaWrapper Unexecuted instantiation: parAuthenticator.c:tDestroySchemaWrapper Unexecuted instantiation: parCalcConst.c:tDestroySchemaWrapper Unexecuted instantiation: parInsertSql.c:tDestroySchemaWrapper Unexecuted instantiation: parInsertUtil.c:tDestroySchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDestroySchemaWrapper Unexecuted instantiation: parAstCreater.c:tDestroySchemaWrapper Unexecuted instantiation: parInsertSml.c:tDestroySchemaWrapper Unexecuted instantiation: planner.c:tDestroySchemaWrapper Unexecuted instantiation: planLogicCreater.c:tDestroySchemaWrapper Unexecuted instantiation: planOptimizer.c:tDestroySchemaWrapper Unexecuted instantiation: planPhysiCreater.c:tDestroySchemaWrapper Unexecuted instantiation: planScaleOut.c:tDestroySchemaWrapper Unexecuted instantiation: planSpliter.c:tDestroySchemaWrapper Unexecuted instantiation: planUtil.c:tDestroySchemaWrapper Unexecuted instantiation: planValidator.c:tDestroySchemaWrapper Unexecuted instantiation: catalog.c:tDestroySchemaWrapper Unexecuted instantiation: ctgAsync.c:tDestroySchemaWrapper Unexecuted instantiation: ctgCache.c:tDestroySchemaWrapper Unexecuted instantiation: ctgDbg.c:tDestroySchemaWrapper Unexecuted instantiation: ctgRemote.c:tDestroySchemaWrapper Unexecuted instantiation: ctgRent.c:tDestroySchemaWrapper Unexecuted instantiation: ctgUtil.c:tDestroySchemaWrapper Unexecuted instantiation: extConnector.c:tDestroySchemaWrapper Unexecuted instantiation: extDialect.c:tDestroySchemaWrapper Unexecuted instantiation: extDialectDefaults.c:tDestroySchemaWrapper Unexecuted instantiation: functionMgt.c:tDestroySchemaWrapper Unexecuted instantiation: tudf.c:tDestroySchemaWrapper Unexecuted instantiation: builtins.c:tDestroySchemaWrapper Unexecuted instantiation: builtinsimpl.c:tDestroySchemaWrapper Unexecuted instantiation: spillDistinctSet.c:tDestroySchemaWrapper Unexecuted instantiation: thistogram.c:tDestroySchemaWrapper Unexecuted instantiation: tpercentile.c:tDestroySchemaWrapper Unexecuted instantiation: tavgfunction.c:tDestroySchemaWrapper Unexecuted instantiation: tminmax.c:tDestroySchemaWrapper Unexecuted instantiation: tminmaxavx.c:tDestroySchemaWrapper Unexecuted instantiation: filter.c:tDestroySchemaWrapper Unexecuted instantiation: scalar.c:tDestroySchemaWrapper Unexecuted instantiation: sclfunc.c:tDestroySchemaWrapper Unexecuted instantiation: sclvector.c:tDestroySchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDestroySchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDestroySchemaWrapper Unexecuted instantiation: extTypeMap.c:tDestroySchemaWrapper Unexecuted instantiation: queryUtil.c:tDestroySchemaWrapper Unexecuted instantiation: querymsg.c:tDestroySchemaWrapper Unexecuted instantiation: trans.c:tDestroySchemaWrapper Unexecuted instantiation: transCli.c:tDestroySchemaWrapper Unexecuted instantiation: transComm.c:tDestroySchemaWrapper Unexecuted instantiation: transSasl.c:tDestroySchemaWrapper Unexecuted instantiation: transSvr.c:tDestroySchemaWrapper Unexecuted instantiation: transTLS.c:tDestroySchemaWrapper Unexecuted instantiation: thttp.c:tDestroySchemaWrapper Unexecuted instantiation: geomFunc.c:tDestroySchemaWrapper Unexecuted instantiation: tconfig.c:tDestroySchemaWrapper Unexecuted instantiation: tdigest.c:tDestroySchemaWrapper Unexecuted instantiation: tlog.c:tDestroySchemaWrapper Unexecuted instantiation: tmempool.c:tDestroySchemaWrapper Unexecuted instantiation: tpagedbuf.c:tDestroySchemaWrapper Unexecuted instantiation: mpDirect.c:tDestroySchemaWrapper Unexecuted instantiation: extCapability.c:tDestroySchemaWrapper Unexecuted instantiation: systable.c:tDestroySchemaWrapper Unexecuted instantiation: tanalytics.c:tDestroySchemaWrapper Unexecuted instantiation: tdatablock.c:tDestroySchemaWrapper Unexecuted instantiation: tdataformat.c:tDestroySchemaWrapper Unexecuted instantiation: tglobal.c:tDestroySchemaWrapper Unexecuted instantiation: tmisce.c:tDestroySchemaWrapper Unexecuted instantiation: tname.c:tDestroySchemaWrapper Unexecuted instantiation: tpriv.c:tDestroySchemaWrapper Unexecuted instantiation: ttime.c:tDestroySchemaWrapper Unexecuted instantiation: tvariant.c:tDestroySchemaWrapper Unexecuted instantiation: streamMsg.c:tDestroySchemaWrapper Unexecuted instantiation: streamWindowPlan.c:tDestroySchemaWrapper Unexecuted instantiation: tmsg.c:tDestroySchemaWrapper Unexecuted instantiation: xnode.c:tDestroySchemaWrapper Unexecuted instantiation: tencrypt.c:tDestroySchemaWrapper Unexecuted instantiation: streamJson.c:tDestroySchemaWrapper Unexecuted instantiation: crypt.c:tDestroySchemaWrapper |
1661 | | |
1662 | 0 | static FORCE_INLINE void tDeleteSSchemaWrapperForHash(void* pSchemaWrapper) { |
1663 | 0 | if (pSchemaWrapper != NULL && *(SSchemaWrapper**)pSchemaWrapper != NULL) { |
1664 | 0 | tDeleteSchemaWrapper(*(SSchemaWrapper**)pSchemaWrapper); |
1665 | 0 | } |
1666 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parser.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parTranslater.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parUtil.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parAstParser.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parAuthenticator.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parCalcConst.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parInsertSql.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parInsertUtil.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: taos_lemon_sql.tab.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parAstCreater.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: parInsertSml.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planner.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planLogicCreater.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planOptimizer.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planPhysiCreater.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planScaleOut.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planSpliter.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planUtil.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: planValidator.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: catalog.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgAsync.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgCache.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgDbg.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgRemote.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgRent.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ctgUtil.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: extConnector.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: extDialect.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: extDialectDefaults.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: functionMgt.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tudf.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: builtins.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: builtinsimpl.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: spillDistinctSet.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: thistogram.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tpercentile.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tavgfunction.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tminmax.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tminmaxavx.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: filter.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: scalar.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: sclfunc.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: sclvector.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesCloneFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesCodeFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesEqualFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesMatchFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesMsgFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesRemotePlanToSQL.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesToSQLFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesTraverseFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: nodesUtilFuncs.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: extTypeMap.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: queryUtil.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: querymsg.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: trans.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: transCli.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: transComm.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: transSasl.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: transSvr.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: transTLS.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: thttp.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: geomFunc.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tconfig.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tdigest.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tlog.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tmempool.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tpagedbuf.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: mpDirect.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: extCapability.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: systable.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tanalytics.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tdatablock.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tdataformat.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tglobal.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tmisce.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tname.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tpriv.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: ttime.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tvariant.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: streamMsg.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: streamWindowPlan.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tmsg.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: xnode.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: tencrypt.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: streamJson.c:tDeleteSSchemaWrapperForHash Unexecuted instantiation: crypt.c:tDeleteSSchemaWrapperForHash |
1667 | | |
1668 | 0 | static FORCE_INLINE int32_t taosEncodeSSchema(void** buf, const SSchema* pSchema) { |
1669 | 0 | int32_t tlen = 0; |
1670 | 0 | tlen += taosEncodeFixedI8(buf, pSchema->type); |
1671 | 0 | tlen += taosEncodeFixedI8(buf, pSchema->flags); |
1672 | 0 | tlen += taosEncodeFixedI32(buf, pSchema->bytes); |
1673 | 0 | tlen += taosEncodeFixedI16(buf, pSchema->colId); |
1674 | 0 | tlen += taosEncodeString(buf, pSchema->name); |
1675 | 0 | return tlen; |
1676 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosEncodeSSchema Unexecuted instantiation: parser.c:taosEncodeSSchema Unexecuted instantiation: parTranslater.c:taosEncodeSSchema Unexecuted instantiation: parUtil.c:taosEncodeSSchema Unexecuted instantiation: parAstParser.c:taosEncodeSSchema Unexecuted instantiation: parAuthenticator.c:taosEncodeSSchema Unexecuted instantiation: parCalcConst.c:taosEncodeSSchema Unexecuted instantiation: parInsertSql.c:taosEncodeSSchema Unexecuted instantiation: parInsertUtil.c:taosEncodeSSchema Unexecuted instantiation: taos_lemon_sql.tab.c:taosEncodeSSchema Unexecuted instantiation: parAstCreater.c:taosEncodeSSchema Unexecuted instantiation: parInsertSml.c:taosEncodeSSchema Unexecuted instantiation: planner.c:taosEncodeSSchema Unexecuted instantiation: planLogicCreater.c:taosEncodeSSchema Unexecuted instantiation: planOptimizer.c:taosEncodeSSchema Unexecuted instantiation: planPhysiCreater.c:taosEncodeSSchema Unexecuted instantiation: planScaleOut.c:taosEncodeSSchema Unexecuted instantiation: planSpliter.c:taosEncodeSSchema Unexecuted instantiation: planUtil.c:taosEncodeSSchema Unexecuted instantiation: planValidator.c:taosEncodeSSchema Unexecuted instantiation: catalog.c:taosEncodeSSchema Unexecuted instantiation: ctgAsync.c:taosEncodeSSchema Unexecuted instantiation: ctgCache.c:taosEncodeSSchema Unexecuted instantiation: ctgDbg.c:taosEncodeSSchema Unexecuted instantiation: ctgRemote.c:taosEncodeSSchema Unexecuted instantiation: ctgRent.c:taosEncodeSSchema Unexecuted instantiation: ctgUtil.c:taosEncodeSSchema Unexecuted instantiation: extConnector.c:taosEncodeSSchema Unexecuted instantiation: extDialect.c:taosEncodeSSchema Unexecuted instantiation: extDialectDefaults.c:taosEncodeSSchema Unexecuted instantiation: functionMgt.c:taosEncodeSSchema Unexecuted instantiation: tudf.c:taosEncodeSSchema Unexecuted instantiation: builtins.c:taosEncodeSSchema Unexecuted instantiation: builtinsimpl.c:taosEncodeSSchema Unexecuted instantiation: spillDistinctSet.c:taosEncodeSSchema Unexecuted instantiation: thistogram.c:taosEncodeSSchema Unexecuted instantiation: tpercentile.c:taosEncodeSSchema Unexecuted instantiation: tavgfunction.c:taosEncodeSSchema Unexecuted instantiation: tminmax.c:taosEncodeSSchema Unexecuted instantiation: tminmaxavx.c:taosEncodeSSchema Unexecuted instantiation: filter.c:taosEncodeSSchema Unexecuted instantiation: scalar.c:taosEncodeSSchema Unexecuted instantiation: sclfunc.c:taosEncodeSSchema Unexecuted instantiation: sclvector.c:taosEncodeSSchema Unexecuted instantiation: nodesCloneFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesCodeFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesEqualFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesMatchFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesMsgFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesRemotePlanToSQL.c:taosEncodeSSchema Unexecuted instantiation: nodesToSQLFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesTraverseFuncs.c:taosEncodeSSchema Unexecuted instantiation: nodesUtilFuncs.c:taosEncodeSSchema Unexecuted instantiation: extTypeMap.c:taosEncodeSSchema Unexecuted instantiation: queryUtil.c:taosEncodeSSchema Unexecuted instantiation: querymsg.c:taosEncodeSSchema Unexecuted instantiation: trans.c:taosEncodeSSchema Unexecuted instantiation: transCli.c:taosEncodeSSchema Unexecuted instantiation: transComm.c:taosEncodeSSchema Unexecuted instantiation: transSasl.c:taosEncodeSSchema Unexecuted instantiation: transSvr.c:taosEncodeSSchema Unexecuted instantiation: transTLS.c:taosEncodeSSchema Unexecuted instantiation: thttp.c:taosEncodeSSchema Unexecuted instantiation: geomFunc.c:taosEncodeSSchema Unexecuted instantiation: tconfig.c:taosEncodeSSchema Unexecuted instantiation: tdigest.c:taosEncodeSSchema Unexecuted instantiation: tlog.c:taosEncodeSSchema Unexecuted instantiation: tmempool.c:taosEncodeSSchema Unexecuted instantiation: tpagedbuf.c:taosEncodeSSchema Unexecuted instantiation: mpDirect.c:taosEncodeSSchema Unexecuted instantiation: extCapability.c:taosEncodeSSchema Unexecuted instantiation: systable.c:taosEncodeSSchema Unexecuted instantiation: tanalytics.c:taosEncodeSSchema Unexecuted instantiation: tdatablock.c:taosEncodeSSchema Unexecuted instantiation: tdataformat.c:taosEncodeSSchema Unexecuted instantiation: tglobal.c:taosEncodeSSchema Unexecuted instantiation: tmisce.c:taosEncodeSSchema Unexecuted instantiation: tname.c:taosEncodeSSchema Unexecuted instantiation: tpriv.c:taosEncodeSSchema Unexecuted instantiation: ttime.c:taosEncodeSSchema Unexecuted instantiation: tvariant.c:taosEncodeSSchema Unexecuted instantiation: streamMsg.c:taosEncodeSSchema Unexecuted instantiation: streamWindowPlan.c:taosEncodeSSchema Unexecuted instantiation: tmsg.c:taosEncodeSSchema Unexecuted instantiation: xnode.c:taosEncodeSSchema Unexecuted instantiation: tencrypt.c:taosEncodeSSchema Unexecuted instantiation: streamJson.c:taosEncodeSSchema Unexecuted instantiation: crypt.c:taosEncodeSSchema |
1677 | | |
1678 | 0 | static FORCE_INLINE void* taosDecodeSSchema(const void* buf, SSchema* pSchema) { |
1679 | 0 | buf = taosDecodeFixedI8(buf, &pSchema->type); |
1680 | 0 | buf = taosDecodeFixedI8(buf, &pSchema->flags); |
1681 | 0 | buf = taosDecodeFixedI32(buf, &pSchema->bytes); |
1682 | 0 | buf = taosDecodeFixedI16(buf, &pSchema->colId); |
1683 | 0 | buf = taosDecodeStringTo(buf, pSchema->name); |
1684 | 0 | return (void*)buf; |
1685 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosDecodeSSchema Unexecuted instantiation: parser.c:taosDecodeSSchema Unexecuted instantiation: parTranslater.c:taosDecodeSSchema Unexecuted instantiation: parUtil.c:taosDecodeSSchema Unexecuted instantiation: parAstParser.c:taosDecodeSSchema Unexecuted instantiation: parAuthenticator.c:taosDecodeSSchema Unexecuted instantiation: parCalcConst.c:taosDecodeSSchema Unexecuted instantiation: parInsertSql.c:taosDecodeSSchema Unexecuted instantiation: parInsertUtil.c:taosDecodeSSchema Unexecuted instantiation: taos_lemon_sql.tab.c:taosDecodeSSchema Unexecuted instantiation: parAstCreater.c:taosDecodeSSchema Unexecuted instantiation: parInsertSml.c:taosDecodeSSchema Unexecuted instantiation: planner.c:taosDecodeSSchema Unexecuted instantiation: planLogicCreater.c:taosDecodeSSchema Unexecuted instantiation: planOptimizer.c:taosDecodeSSchema Unexecuted instantiation: planPhysiCreater.c:taosDecodeSSchema Unexecuted instantiation: planScaleOut.c:taosDecodeSSchema Unexecuted instantiation: planSpliter.c:taosDecodeSSchema Unexecuted instantiation: planUtil.c:taosDecodeSSchema Unexecuted instantiation: planValidator.c:taosDecodeSSchema Unexecuted instantiation: catalog.c:taosDecodeSSchema Unexecuted instantiation: ctgAsync.c:taosDecodeSSchema Unexecuted instantiation: ctgCache.c:taosDecodeSSchema Unexecuted instantiation: ctgDbg.c:taosDecodeSSchema Unexecuted instantiation: ctgRemote.c:taosDecodeSSchema Unexecuted instantiation: ctgRent.c:taosDecodeSSchema Unexecuted instantiation: ctgUtil.c:taosDecodeSSchema Unexecuted instantiation: extConnector.c:taosDecodeSSchema Unexecuted instantiation: extDialect.c:taosDecodeSSchema Unexecuted instantiation: extDialectDefaults.c:taosDecodeSSchema Unexecuted instantiation: functionMgt.c:taosDecodeSSchema Unexecuted instantiation: tudf.c:taosDecodeSSchema Unexecuted instantiation: builtins.c:taosDecodeSSchema Unexecuted instantiation: builtinsimpl.c:taosDecodeSSchema Unexecuted instantiation: spillDistinctSet.c:taosDecodeSSchema Unexecuted instantiation: thistogram.c:taosDecodeSSchema Unexecuted instantiation: tpercentile.c:taosDecodeSSchema Unexecuted instantiation: tavgfunction.c:taosDecodeSSchema Unexecuted instantiation: tminmax.c:taosDecodeSSchema Unexecuted instantiation: tminmaxavx.c:taosDecodeSSchema Unexecuted instantiation: filter.c:taosDecodeSSchema Unexecuted instantiation: scalar.c:taosDecodeSSchema Unexecuted instantiation: sclfunc.c:taosDecodeSSchema Unexecuted instantiation: sclvector.c:taosDecodeSSchema Unexecuted instantiation: nodesCloneFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesCodeFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesEqualFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesMatchFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesMsgFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesRemotePlanToSQL.c:taosDecodeSSchema Unexecuted instantiation: nodesToSQLFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesTraverseFuncs.c:taosDecodeSSchema Unexecuted instantiation: nodesUtilFuncs.c:taosDecodeSSchema Unexecuted instantiation: extTypeMap.c:taosDecodeSSchema Unexecuted instantiation: queryUtil.c:taosDecodeSSchema Unexecuted instantiation: querymsg.c:taosDecodeSSchema Unexecuted instantiation: trans.c:taosDecodeSSchema Unexecuted instantiation: transCli.c:taosDecodeSSchema Unexecuted instantiation: transComm.c:taosDecodeSSchema Unexecuted instantiation: transSasl.c:taosDecodeSSchema Unexecuted instantiation: transSvr.c:taosDecodeSSchema Unexecuted instantiation: transTLS.c:taosDecodeSSchema Unexecuted instantiation: thttp.c:taosDecodeSSchema Unexecuted instantiation: geomFunc.c:taosDecodeSSchema Unexecuted instantiation: tconfig.c:taosDecodeSSchema Unexecuted instantiation: tdigest.c:taosDecodeSSchema Unexecuted instantiation: tlog.c:taosDecodeSSchema Unexecuted instantiation: tmempool.c:taosDecodeSSchema Unexecuted instantiation: tpagedbuf.c:taosDecodeSSchema Unexecuted instantiation: mpDirect.c:taosDecodeSSchema Unexecuted instantiation: extCapability.c:taosDecodeSSchema Unexecuted instantiation: systable.c:taosDecodeSSchema Unexecuted instantiation: tanalytics.c:taosDecodeSSchema Unexecuted instantiation: tdatablock.c:taosDecodeSSchema Unexecuted instantiation: tdataformat.c:taosDecodeSSchema Unexecuted instantiation: tglobal.c:taosDecodeSSchema Unexecuted instantiation: tmisce.c:taosDecodeSSchema Unexecuted instantiation: tname.c:taosDecodeSSchema Unexecuted instantiation: tpriv.c:taosDecodeSSchema Unexecuted instantiation: ttime.c:taosDecodeSSchema Unexecuted instantiation: tvariant.c:taosDecodeSSchema Unexecuted instantiation: streamMsg.c:taosDecodeSSchema Unexecuted instantiation: streamWindowPlan.c:taosDecodeSSchema Unexecuted instantiation: tmsg.c:taosDecodeSSchema Unexecuted instantiation: xnode.c:taosDecodeSSchema Unexecuted instantiation: tencrypt.c:taosDecodeSSchema Unexecuted instantiation: streamJson.c:taosDecodeSSchema Unexecuted instantiation: crypt.c:taosDecodeSSchema |
1686 | | |
1687 | 0 | static FORCE_INLINE int32_t tEncodeSSchema(SEncoder* pEncoder, const SSchema* pSchema) { |
1688 | 0 | TAOS_CHECK_RETURN(tEncodeI8(pEncoder, pSchema->type)); |
1689 | 0 | TAOS_CHECK_RETURN(tEncodeI8(pEncoder, pSchema->flags)); |
1690 | 0 | TAOS_CHECK_RETURN(tEncodeI32v(pEncoder, pSchema->bytes)); |
1691 | 0 | TAOS_CHECK_RETURN(tEncodeI16v(pEncoder, pSchema->colId)); |
1692 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pSchema->name)); |
1693 | 0 | return 0; |
1694 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSSchema Unexecuted instantiation: parser.c:tEncodeSSchema Unexecuted instantiation: parTranslater.c:tEncodeSSchema Unexecuted instantiation: parUtil.c:tEncodeSSchema Unexecuted instantiation: parAstParser.c:tEncodeSSchema Unexecuted instantiation: parAuthenticator.c:tEncodeSSchema Unexecuted instantiation: parCalcConst.c:tEncodeSSchema Unexecuted instantiation: parInsertSql.c:tEncodeSSchema Unexecuted instantiation: parInsertUtil.c:tEncodeSSchema Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSSchema Unexecuted instantiation: parAstCreater.c:tEncodeSSchema Unexecuted instantiation: parInsertSml.c:tEncodeSSchema Unexecuted instantiation: planner.c:tEncodeSSchema Unexecuted instantiation: planLogicCreater.c:tEncodeSSchema Unexecuted instantiation: planOptimizer.c:tEncodeSSchema Unexecuted instantiation: planPhysiCreater.c:tEncodeSSchema Unexecuted instantiation: planScaleOut.c:tEncodeSSchema Unexecuted instantiation: planSpliter.c:tEncodeSSchema Unexecuted instantiation: planUtil.c:tEncodeSSchema Unexecuted instantiation: planValidator.c:tEncodeSSchema Unexecuted instantiation: catalog.c:tEncodeSSchema Unexecuted instantiation: ctgAsync.c:tEncodeSSchema Unexecuted instantiation: ctgCache.c:tEncodeSSchema Unexecuted instantiation: ctgDbg.c:tEncodeSSchema Unexecuted instantiation: ctgRemote.c:tEncodeSSchema Unexecuted instantiation: ctgRent.c:tEncodeSSchema Unexecuted instantiation: ctgUtil.c:tEncodeSSchema Unexecuted instantiation: extConnector.c:tEncodeSSchema Unexecuted instantiation: extDialect.c:tEncodeSSchema Unexecuted instantiation: extDialectDefaults.c:tEncodeSSchema Unexecuted instantiation: functionMgt.c:tEncodeSSchema Unexecuted instantiation: tudf.c:tEncodeSSchema Unexecuted instantiation: builtins.c:tEncodeSSchema Unexecuted instantiation: builtinsimpl.c:tEncodeSSchema Unexecuted instantiation: spillDistinctSet.c:tEncodeSSchema Unexecuted instantiation: thistogram.c:tEncodeSSchema Unexecuted instantiation: tpercentile.c:tEncodeSSchema Unexecuted instantiation: tavgfunction.c:tEncodeSSchema Unexecuted instantiation: tminmax.c:tEncodeSSchema Unexecuted instantiation: tminmaxavx.c:tEncodeSSchema Unexecuted instantiation: filter.c:tEncodeSSchema Unexecuted instantiation: scalar.c:tEncodeSSchema Unexecuted instantiation: sclfunc.c:tEncodeSSchema Unexecuted instantiation: sclvector.c:tEncodeSSchema Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSSchema Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSSchema Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSSchema Unexecuted instantiation: extTypeMap.c:tEncodeSSchema Unexecuted instantiation: queryUtil.c:tEncodeSSchema Unexecuted instantiation: querymsg.c:tEncodeSSchema Unexecuted instantiation: trans.c:tEncodeSSchema Unexecuted instantiation: transCli.c:tEncodeSSchema Unexecuted instantiation: transComm.c:tEncodeSSchema Unexecuted instantiation: transSasl.c:tEncodeSSchema Unexecuted instantiation: transSvr.c:tEncodeSSchema Unexecuted instantiation: transTLS.c:tEncodeSSchema Unexecuted instantiation: thttp.c:tEncodeSSchema Unexecuted instantiation: geomFunc.c:tEncodeSSchema Unexecuted instantiation: tconfig.c:tEncodeSSchema Unexecuted instantiation: tdigest.c:tEncodeSSchema Unexecuted instantiation: tlog.c:tEncodeSSchema Unexecuted instantiation: tmempool.c:tEncodeSSchema Unexecuted instantiation: tpagedbuf.c:tEncodeSSchema Unexecuted instantiation: mpDirect.c:tEncodeSSchema Unexecuted instantiation: extCapability.c:tEncodeSSchema Unexecuted instantiation: systable.c:tEncodeSSchema Unexecuted instantiation: tanalytics.c:tEncodeSSchema Unexecuted instantiation: tdatablock.c:tEncodeSSchema Unexecuted instantiation: tdataformat.c:tEncodeSSchema Unexecuted instantiation: tglobal.c:tEncodeSSchema Unexecuted instantiation: tmisce.c:tEncodeSSchema Unexecuted instantiation: tname.c:tEncodeSSchema Unexecuted instantiation: tpriv.c:tEncodeSSchema Unexecuted instantiation: ttime.c:tEncodeSSchema Unexecuted instantiation: tvariant.c:tEncodeSSchema Unexecuted instantiation: streamMsg.c:tEncodeSSchema Unexecuted instantiation: streamWindowPlan.c:tEncodeSSchema Unexecuted instantiation: tmsg.c:tEncodeSSchema Unexecuted instantiation: xnode.c:tEncodeSSchema Unexecuted instantiation: tencrypt.c:tEncodeSSchema Unexecuted instantiation: streamJson.c:tEncodeSSchema Unexecuted instantiation: crypt.c:tEncodeSSchema |
1695 | | |
1696 | 0 | static FORCE_INLINE int32_t tDecodeSSchema(SDecoder* pDecoder, SSchema* pSchema) { |
1697 | 0 | TAOS_CHECK_RETURN(tDecodeI8(pDecoder, &pSchema->type)); |
1698 | 0 | TAOS_CHECK_RETURN(tDecodeI8(pDecoder, &pSchema->flags)); |
1699 | 0 | TAOS_CHECK_RETURN(tDecodeI32v(pDecoder, &pSchema->bytes)); |
1700 | 0 | TAOS_CHECK_RETURN(tDecodeI16v(pDecoder, &pSchema->colId)); |
1701 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pSchema->name)); |
1702 | 0 | return 0; |
1703 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSSchema Unexecuted instantiation: parser.c:tDecodeSSchema Unexecuted instantiation: parTranslater.c:tDecodeSSchema Unexecuted instantiation: parUtil.c:tDecodeSSchema Unexecuted instantiation: parAstParser.c:tDecodeSSchema Unexecuted instantiation: parAuthenticator.c:tDecodeSSchema Unexecuted instantiation: parCalcConst.c:tDecodeSSchema Unexecuted instantiation: parInsertSql.c:tDecodeSSchema Unexecuted instantiation: parInsertUtil.c:tDecodeSSchema Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSSchema Unexecuted instantiation: parAstCreater.c:tDecodeSSchema Unexecuted instantiation: parInsertSml.c:tDecodeSSchema Unexecuted instantiation: planner.c:tDecodeSSchema Unexecuted instantiation: planLogicCreater.c:tDecodeSSchema Unexecuted instantiation: planOptimizer.c:tDecodeSSchema Unexecuted instantiation: planPhysiCreater.c:tDecodeSSchema Unexecuted instantiation: planScaleOut.c:tDecodeSSchema Unexecuted instantiation: planSpliter.c:tDecodeSSchema Unexecuted instantiation: planUtil.c:tDecodeSSchema Unexecuted instantiation: planValidator.c:tDecodeSSchema Unexecuted instantiation: catalog.c:tDecodeSSchema Unexecuted instantiation: ctgAsync.c:tDecodeSSchema Unexecuted instantiation: ctgCache.c:tDecodeSSchema Unexecuted instantiation: ctgDbg.c:tDecodeSSchema Unexecuted instantiation: ctgRemote.c:tDecodeSSchema Unexecuted instantiation: ctgRent.c:tDecodeSSchema Unexecuted instantiation: ctgUtil.c:tDecodeSSchema Unexecuted instantiation: extConnector.c:tDecodeSSchema Unexecuted instantiation: extDialect.c:tDecodeSSchema Unexecuted instantiation: extDialectDefaults.c:tDecodeSSchema Unexecuted instantiation: functionMgt.c:tDecodeSSchema Unexecuted instantiation: tudf.c:tDecodeSSchema Unexecuted instantiation: builtins.c:tDecodeSSchema Unexecuted instantiation: builtinsimpl.c:tDecodeSSchema Unexecuted instantiation: spillDistinctSet.c:tDecodeSSchema Unexecuted instantiation: thistogram.c:tDecodeSSchema Unexecuted instantiation: tpercentile.c:tDecodeSSchema Unexecuted instantiation: tavgfunction.c:tDecodeSSchema Unexecuted instantiation: tminmax.c:tDecodeSSchema Unexecuted instantiation: tminmaxavx.c:tDecodeSSchema Unexecuted instantiation: filter.c:tDecodeSSchema Unexecuted instantiation: scalar.c:tDecodeSSchema Unexecuted instantiation: sclfunc.c:tDecodeSSchema Unexecuted instantiation: sclvector.c:tDecodeSSchema Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSSchema Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSSchema Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSSchema Unexecuted instantiation: extTypeMap.c:tDecodeSSchema Unexecuted instantiation: queryUtil.c:tDecodeSSchema Unexecuted instantiation: querymsg.c:tDecodeSSchema Unexecuted instantiation: trans.c:tDecodeSSchema Unexecuted instantiation: transCli.c:tDecodeSSchema Unexecuted instantiation: transComm.c:tDecodeSSchema Unexecuted instantiation: transSasl.c:tDecodeSSchema Unexecuted instantiation: transSvr.c:tDecodeSSchema Unexecuted instantiation: transTLS.c:tDecodeSSchema Unexecuted instantiation: thttp.c:tDecodeSSchema Unexecuted instantiation: geomFunc.c:tDecodeSSchema Unexecuted instantiation: tconfig.c:tDecodeSSchema Unexecuted instantiation: tdigest.c:tDecodeSSchema Unexecuted instantiation: tlog.c:tDecodeSSchema Unexecuted instantiation: tmempool.c:tDecodeSSchema Unexecuted instantiation: tpagedbuf.c:tDecodeSSchema Unexecuted instantiation: mpDirect.c:tDecodeSSchema Unexecuted instantiation: extCapability.c:tDecodeSSchema Unexecuted instantiation: systable.c:tDecodeSSchema Unexecuted instantiation: tanalytics.c:tDecodeSSchema Unexecuted instantiation: tdatablock.c:tDecodeSSchema Unexecuted instantiation: tdataformat.c:tDecodeSSchema Unexecuted instantiation: tglobal.c:tDecodeSSchema Unexecuted instantiation: tmisce.c:tDecodeSSchema Unexecuted instantiation: tname.c:tDecodeSSchema Unexecuted instantiation: tpriv.c:tDecodeSSchema Unexecuted instantiation: ttime.c:tDecodeSSchema Unexecuted instantiation: tvariant.c:tDecodeSSchema Unexecuted instantiation: streamMsg.c:tDecodeSSchema Unexecuted instantiation: streamWindowPlan.c:tDecodeSSchema Unexecuted instantiation: tmsg.c:tDecodeSSchema Unexecuted instantiation: xnode.c:tDecodeSSchema Unexecuted instantiation: tencrypt.c:tDecodeSSchema Unexecuted instantiation: streamJson.c:tDecodeSSchema Unexecuted instantiation: crypt.c:tDecodeSSchema |
1704 | | |
1705 | 0 | static FORCE_INLINE int32_t tEncodeSSchemaExt(SEncoder* pEncoder, const SSchemaExt* pSchemaExt) { |
1706 | 0 | TAOS_CHECK_RETURN(tEncodeI16v(pEncoder, pSchemaExt->colId)); |
1707 | 0 | TAOS_CHECK_RETURN(tEncodeU32(pEncoder, pSchemaExt->compress)); |
1708 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, pSchemaExt->typeMod)); |
1709 | 0 | return 0; |
1710 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSSchemaExt Unexecuted instantiation: parser.c:tEncodeSSchemaExt Unexecuted instantiation: parTranslater.c:tEncodeSSchemaExt Unexecuted instantiation: parUtil.c:tEncodeSSchemaExt Unexecuted instantiation: parAstParser.c:tEncodeSSchemaExt Unexecuted instantiation: parAuthenticator.c:tEncodeSSchemaExt Unexecuted instantiation: parCalcConst.c:tEncodeSSchemaExt Unexecuted instantiation: parInsertSql.c:tEncodeSSchemaExt Unexecuted instantiation: parInsertUtil.c:tEncodeSSchemaExt Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSSchemaExt Unexecuted instantiation: parAstCreater.c:tEncodeSSchemaExt Unexecuted instantiation: parInsertSml.c:tEncodeSSchemaExt Unexecuted instantiation: planner.c:tEncodeSSchemaExt Unexecuted instantiation: planLogicCreater.c:tEncodeSSchemaExt Unexecuted instantiation: planOptimizer.c:tEncodeSSchemaExt Unexecuted instantiation: planPhysiCreater.c:tEncodeSSchemaExt Unexecuted instantiation: planScaleOut.c:tEncodeSSchemaExt Unexecuted instantiation: planSpliter.c:tEncodeSSchemaExt Unexecuted instantiation: planUtil.c:tEncodeSSchemaExt Unexecuted instantiation: planValidator.c:tEncodeSSchemaExt Unexecuted instantiation: catalog.c:tEncodeSSchemaExt Unexecuted instantiation: ctgAsync.c:tEncodeSSchemaExt Unexecuted instantiation: ctgCache.c:tEncodeSSchemaExt Unexecuted instantiation: ctgDbg.c:tEncodeSSchemaExt Unexecuted instantiation: ctgRemote.c:tEncodeSSchemaExt Unexecuted instantiation: ctgRent.c:tEncodeSSchemaExt Unexecuted instantiation: ctgUtil.c:tEncodeSSchemaExt Unexecuted instantiation: extConnector.c:tEncodeSSchemaExt Unexecuted instantiation: extDialect.c:tEncodeSSchemaExt Unexecuted instantiation: extDialectDefaults.c:tEncodeSSchemaExt Unexecuted instantiation: functionMgt.c:tEncodeSSchemaExt Unexecuted instantiation: tudf.c:tEncodeSSchemaExt Unexecuted instantiation: builtins.c:tEncodeSSchemaExt Unexecuted instantiation: builtinsimpl.c:tEncodeSSchemaExt Unexecuted instantiation: spillDistinctSet.c:tEncodeSSchemaExt Unexecuted instantiation: thistogram.c:tEncodeSSchemaExt Unexecuted instantiation: tpercentile.c:tEncodeSSchemaExt Unexecuted instantiation: tavgfunction.c:tEncodeSSchemaExt Unexecuted instantiation: tminmax.c:tEncodeSSchemaExt Unexecuted instantiation: tminmaxavx.c:tEncodeSSchemaExt Unexecuted instantiation: filter.c:tEncodeSSchemaExt Unexecuted instantiation: scalar.c:tEncodeSSchemaExt Unexecuted instantiation: sclfunc.c:tEncodeSSchemaExt Unexecuted instantiation: sclvector.c:tEncodeSSchemaExt Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSSchemaExt Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSSchemaExt Unexecuted instantiation: extTypeMap.c:tEncodeSSchemaExt Unexecuted instantiation: queryUtil.c:tEncodeSSchemaExt Unexecuted instantiation: querymsg.c:tEncodeSSchemaExt Unexecuted instantiation: trans.c:tEncodeSSchemaExt Unexecuted instantiation: transCli.c:tEncodeSSchemaExt Unexecuted instantiation: transComm.c:tEncodeSSchemaExt Unexecuted instantiation: transSasl.c:tEncodeSSchemaExt Unexecuted instantiation: transSvr.c:tEncodeSSchemaExt Unexecuted instantiation: transTLS.c:tEncodeSSchemaExt Unexecuted instantiation: thttp.c:tEncodeSSchemaExt Unexecuted instantiation: geomFunc.c:tEncodeSSchemaExt Unexecuted instantiation: tconfig.c:tEncodeSSchemaExt Unexecuted instantiation: tdigest.c:tEncodeSSchemaExt Unexecuted instantiation: tlog.c:tEncodeSSchemaExt Unexecuted instantiation: tmempool.c:tEncodeSSchemaExt Unexecuted instantiation: tpagedbuf.c:tEncodeSSchemaExt Unexecuted instantiation: mpDirect.c:tEncodeSSchemaExt Unexecuted instantiation: extCapability.c:tEncodeSSchemaExt Unexecuted instantiation: systable.c:tEncodeSSchemaExt Unexecuted instantiation: tanalytics.c:tEncodeSSchemaExt Unexecuted instantiation: tdatablock.c:tEncodeSSchemaExt Unexecuted instantiation: tdataformat.c:tEncodeSSchemaExt Unexecuted instantiation: tglobal.c:tEncodeSSchemaExt Unexecuted instantiation: tmisce.c:tEncodeSSchemaExt Unexecuted instantiation: tname.c:tEncodeSSchemaExt Unexecuted instantiation: tpriv.c:tEncodeSSchemaExt Unexecuted instantiation: ttime.c:tEncodeSSchemaExt Unexecuted instantiation: tvariant.c:tEncodeSSchemaExt Unexecuted instantiation: streamMsg.c:tEncodeSSchemaExt Unexecuted instantiation: streamWindowPlan.c:tEncodeSSchemaExt Unexecuted instantiation: tmsg.c:tEncodeSSchemaExt Unexecuted instantiation: xnode.c:tEncodeSSchemaExt Unexecuted instantiation: tencrypt.c:tEncodeSSchemaExt Unexecuted instantiation: streamJson.c:tEncodeSSchemaExt Unexecuted instantiation: crypt.c:tEncodeSSchemaExt |
1711 | | |
1712 | 0 | static FORCE_INLINE int32_t tDecodeSSchemaExt(SDecoder* pDecoder, SSchemaExt* pSchemaExt) { |
1713 | 0 | TAOS_CHECK_RETURN(tDecodeI16v(pDecoder, &pSchemaExt->colId)); |
1714 | 0 | TAOS_CHECK_RETURN(tDecodeU32(pDecoder, &pSchemaExt->compress)); |
1715 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pSchemaExt->typeMod)); |
1716 | 0 | return 0; |
1717 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSSchemaExt Unexecuted instantiation: parser.c:tDecodeSSchemaExt Unexecuted instantiation: parTranslater.c:tDecodeSSchemaExt Unexecuted instantiation: parUtil.c:tDecodeSSchemaExt Unexecuted instantiation: parAstParser.c:tDecodeSSchemaExt Unexecuted instantiation: parAuthenticator.c:tDecodeSSchemaExt Unexecuted instantiation: parCalcConst.c:tDecodeSSchemaExt Unexecuted instantiation: parInsertSql.c:tDecodeSSchemaExt Unexecuted instantiation: parInsertUtil.c:tDecodeSSchemaExt Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSSchemaExt Unexecuted instantiation: parAstCreater.c:tDecodeSSchemaExt Unexecuted instantiation: parInsertSml.c:tDecodeSSchemaExt Unexecuted instantiation: planner.c:tDecodeSSchemaExt Unexecuted instantiation: planLogicCreater.c:tDecodeSSchemaExt Unexecuted instantiation: planOptimizer.c:tDecodeSSchemaExt Unexecuted instantiation: planPhysiCreater.c:tDecodeSSchemaExt Unexecuted instantiation: planScaleOut.c:tDecodeSSchemaExt Unexecuted instantiation: planSpliter.c:tDecodeSSchemaExt Unexecuted instantiation: planUtil.c:tDecodeSSchemaExt Unexecuted instantiation: planValidator.c:tDecodeSSchemaExt Unexecuted instantiation: catalog.c:tDecodeSSchemaExt Unexecuted instantiation: ctgAsync.c:tDecodeSSchemaExt Unexecuted instantiation: ctgCache.c:tDecodeSSchemaExt Unexecuted instantiation: ctgDbg.c:tDecodeSSchemaExt Unexecuted instantiation: ctgRemote.c:tDecodeSSchemaExt Unexecuted instantiation: ctgRent.c:tDecodeSSchemaExt Unexecuted instantiation: ctgUtil.c:tDecodeSSchemaExt Unexecuted instantiation: extConnector.c:tDecodeSSchemaExt Unexecuted instantiation: extDialect.c:tDecodeSSchemaExt Unexecuted instantiation: extDialectDefaults.c:tDecodeSSchemaExt Unexecuted instantiation: functionMgt.c:tDecodeSSchemaExt Unexecuted instantiation: tudf.c:tDecodeSSchemaExt Unexecuted instantiation: builtins.c:tDecodeSSchemaExt Unexecuted instantiation: builtinsimpl.c:tDecodeSSchemaExt Unexecuted instantiation: spillDistinctSet.c:tDecodeSSchemaExt Unexecuted instantiation: thistogram.c:tDecodeSSchemaExt Unexecuted instantiation: tpercentile.c:tDecodeSSchemaExt Unexecuted instantiation: tavgfunction.c:tDecodeSSchemaExt Unexecuted instantiation: tminmax.c:tDecodeSSchemaExt Unexecuted instantiation: tminmaxavx.c:tDecodeSSchemaExt Unexecuted instantiation: filter.c:tDecodeSSchemaExt Unexecuted instantiation: scalar.c:tDecodeSSchemaExt Unexecuted instantiation: sclfunc.c:tDecodeSSchemaExt Unexecuted instantiation: sclvector.c:tDecodeSSchemaExt Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSSchemaExt Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSSchemaExt Unexecuted instantiation: extTypeMap.c:tDecodeSSchemaExt Unexecuted instantiation: queryUtil.c:tDecodeSSchemaExt Unexecuted instantiation: querymsg.c:tDecodeSSchemaExt Unexecuted instantiation: trans.c:tDecodeSSchemaExt Unexecuted instantiation: transCli.c:tDecodeSSchemaExt Unexecuted instantiation: transComm.c:tDecodeSSchemaExt Unexecuted instantiation: transSasl.c:tDecodeSSchemaExt Unexecuted instantiation: transSvr.c:tDecodeSSchemaExt Unexecuted instantiation: transTLS.c:tDecodeSSchemaExt Unexecuted instantiation: thttp.c:tDecodeSSchemaExt Unexecuted instantiation: geomFunc.c:tDecodeSSchemaExt Unexecuted instantiation: tconfig.c:tDecodeSSchemaExt Unexecuted instantiation: tdigest.c:tDecodeSSchemaExt Unexecuted instantiation: tlog.c:tDecodeSSchemaExt Unexecuted instantiation: tmempool.c:tDecodeSSchemaExt Unexecuted instantiation: tpagedbuf.c:tDecodeSSchemaExt Unexecuted instantiation: mpDirect.c:tDecodeSSchemaExt Unexecuted instantiation: extCapability.c:tDecodeSSchemaExt Unexecuted instantiation: systable.c:tDecodeSSchemaExt Unexecuted instantiation: tanalytics.c:tDecodeSSchemaExt Unexecuted instantiation: tdatablock.c:tDecodeSSchemaExt Unexecuted instantiation: tdataformat.c:tDecodeSSchemaExt Unexecuted instantiation: tglobal.c:tDecodeSSchemaExt Unexecuted instantiation: tmisce.c:tDecodeSSchemaExt Unexecuted instantiation: tname.c:tDecodeSSchemaExt Unexecuted instantiation: tpriv.c:tDecodeSSchemaExt Unexecuted instantiation: ttime.c:tDecodeSSchemaExt Unexecuted instantiation: tvariant.c:tDecodeSSchemaExt Unexecuted instantiation: streamMsg.c:tDecodeSSchemaExt Unexecuted instantiation: streamWindowPlan.c:tDecodeSSchemaExt Unexecuted instantiation: tmsg.c:tDecodeSSchemaExt Unexecuted instantiation: xnode.c:tDecodeSSchemaExt Unexecuted instantiation: tencrypt.c:tDecodeSSchemaExt Unexecuted instantiation: streamJson.c:tDecodeSSchemaExt Unexecuted instantiation: crypt.c:tDecodeSSchemaExt |
1718 | | |
1719 | 0 | static FORCE_INLINE int32_t tEncodeSColRef(SEncoder* pEncoder, const SColRef* pColRef) { |
1720 | 0 | TAOS_CHECK_RETURN(tEncodeI8(pEncoder, pColRef->hasRef)); |
1721 | 0 | TAOS_CHECK_RETURN(tEncodeI16(pEncoder, pColRef->id)); |
1722 | 0 | if (pColRef->hasRef) { |
1723 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pColRef->refDbName)); |
1724 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pColRef->refTableName)); |
1725 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pColRef->refColName)); |
1726 | 0 | } |
1727 | 0 | return 0; |
1728 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSColRef Unexecuted instantiation: parser.c:tEncodeSColRef Unexecuted instantiation: parTranslater.c:tEncodeSColRef Unexecuted instantiation: parUtil.c:tEncodeSColRef Unexecuted instantiation: parAstParser.c:tEncodeSColRef Unexecuted instantiation: parAuthenticator.c:tEncodeSColRef Unexecuted instantiation: parCalcConst.c:tEncodeSColRef Unexecuted instantiation: parInsertSql.c:tEncodeSColRef Unexecuted instantiation: parInsertUtil.c:tEncodeSColRef Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSColRef Unexecuted instantiation: parAstCreater.c:tEncodeSColRef Unexecuted instantiation: parInsertSml.c:tEncodeSColRef Unexecuted instantiation: planner.c:tEncodeSColRef Unexecuted instantiation: planLogicCreater.c:tEncodeSColRef Unexecuted instantiation: planOptimizer.c:tEncodeSColRef Unexecuted instantiation: planPhysiCreater.c:tEncodeSColRef Unexecuted instantiation: planScaleOut.c:tEncodeSColRef Unexecuted instantiation: planSpliter.c:tEncodeSColRef Unexecuted instantiation: planUtil.c:tEncodeSColRef Unexecuted instantiation: planValidator.c:tEncodeSColRef Unexecuted instantiation: catalog.c:tEncodeSColRef Unexecuted instantiation: ctgAsync.c:tEncodeSColRef Unexecuted instantiation: ctgCache.c:tEncodeSColRef Unexecuted instantiation: ctgDbg.c:tEncodeSColRef Unexecuted instantiation: ctgRemote.c:tEncodeSColRef Unexecuted instantiation: ctgRent.c:tEncodeSColRef Unexecuted instantiation: ctgUtil.c:tEncodeSColRef Unexecuted instantiation: extConnector.c:tEncodeSColRef Unexecuted instantiation: extDialect.c:tEncodeSColRef Unexecuted instantiation: extDialectDefaults.c:tEncodeSColRef Unexecuted instantiation: functionMgt.c:tEncodeSColRef Unexecuted instantiation: tudf.c:tEncodeSColRef Unexecuted instantiation: builtins.c:tEncodeSColRef Unexecuted instantiation: builtinsimpl.c:tEncodeSColRef Unexecuted instantiation: spillDistinctSet.c:tEncodeSColRef Unexecuted instantiation: thistogram.c:tEncodeSColRef Unexecuted instantiation: tpercentile.c:tEncodeSColRef Unexecuted instantiation: tavgfunction.c:tEncodeSColRef Unexecuted instantiation: tminmax.c:tEncodeSColRef Unexecuted instantiation: tminmaxavx.c:tEncodeSColRef Unexecuted instantiation: filter.c:tEncodeSColRef Unexecuted instantiation: scalar.c:tEncodeSColRef Unexecuted instantiation: sclfunc.c:tEncodeSColRef Unexecuted instantiation: sclvector.c:tEncodeSColRef Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSColRef Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSColRef Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSColRef Unexecuted instantiation: extTypeMap.c:tEncodeSColRef Unexecuted instantiation: queryUtil.c:tEncodeSColRef Unexecuted instantiation: querymsg.c:tEncodeSColRef Unexecuted instantiation: trans.c:tEncodeSColRef Unexecuted instantiation: transCli.c:tEncodeSColRef Unexecuted instantiation: transComm.c:tEncodeSColRef Unexecuted instantiation: transSasl.c:tEncodeSColRef Unexecuted instantiation: transSvr.c:tEncodeSColRef Unexecuted instantiation: transTLS.c:tEncodeSColRef Unexecuted instantiation: thttp.c:tEncodeSColRef Unexecuted instantiation: geomFunc.c:tEncodeSColRef Unexecuted instantiation: tconfig.c:tEncodeSColRef Unexecuted instantiation: tdigest.c:tEncodeSColRef Unexecuted instantiation: tlog.c:tEncodeSColRef Unexecuted instantiation: tmempool.c:tEncodeSColRef Unexecuted instantiation: tpagedbuf.c:tEncodeSColRef Unexecuted instantiation: mpDirect.c:tEncodeSColRef Unexecuted instantiation: extCapability.c:tEncodeSColRef Unexecuted instantiation: systable.c:tEncodeSColRef Unexecuted instantiation: tanalytics.c:tEncodeSColRef Unexecuted instantiation: tdatablock.c:tEncodeSColRef Unexecuted instantiation: tdataformat.c:tEncodeSColRef Unexecuted instantiation: tglobal.c:tEncodeSColRef Unexecuted instantiation: tmisce.c:tEncodeSColRef Unexecuted instantiation: tname.c:tEncodeSColRef Unexecuted instantiation: tpriv.c:tEncodeSColRef Unexecuted instantiation: ttime.c:tEncodeSColRef Unexecuted instantiation: tvariant.c:tEncodeSColRef Unexecuted instantiation: streamMsg.c:tEncodeSColRef Unexecuted instantiation: streamWindowPlan.c:tEncodeSColRef Unexecuted instantiation: tmsg.c:tEncodeSColRef Unexecuted instantiation: xnode.c:tEncodeSColRef Unexecuted instantiation: tencrypt.c:tEncodeSColRef Unexecuted instantiation: streamJson.c:tEncodeSColRef Unexecuted instantiation: crypt.c:tEncodeSColRef |
1729 | | |
1730 | 0 | static FORCE_INLINE int32_t tDecodeSColRef(SDecoder* pDecoder, SColRef* pColRef) { |
1731 | 0 | pColRef->tagCondLen = 0; |
1732 | 0 | pColRef->tagCondJson = NULL; |
1733 | 0 | pColRef->filterCondLen = 0; |
1734 | 0 | pColRef->filterCondJson = NULL; |
1735 | 0 | pColRef->refType = 0; |
1736 | 0 | pColRef->refSourceName[0] = '\0'; |
1737 | 0 | pColRef->refSchemaName[0] = '\0'; |
1738 | 0 | TAOS_CHECK_RETURN(tDecodeI8(pDecoder, (int8_t*)&pColRef->hasRef)); |
1739 | 0 | TAOS_CHECK_RETURN(tDecodeI16(pDecoder, &pColRef->id)); |
1740 | 0 | if (pColRef->hasRef) { |
1741 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pColRef->refDbName)); |
1742 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pColRef->refTableName)); |
1743 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pColRef->refColName)); |
1744 | 0 | } |
1745 | | |
1746 | 0 | return 0; |
1747 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSColRef Unexecuted instantiation: parser.c:tDecodeSColRef Unexecuted instantiation: parTranslater.c:tDecodeSColRef Unexecuted instantiation: parUtil.c:tDecodeSColRef Unexecuted instantiation: parAstParser.c:tDecodeSColRef Unexecuted instantiation: parAuthenticator.c:tDecodeSColRef Unexecuted instantiation: parCalcConst.c:tDecodeSColRef Unexecuted instantiation: parInsertSql.c:tDecodeSColRef Unexecuted instantiation: parInsertUtil.c:tDecodeSColRef Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSColRef Unexecuted instantiation: parAstCreater.c:tDecodeSColRef Unexecuted instantiation: parInsertSml.c:tDecodeSColRef Unexecuted instantiation: planner.c:tDecodeSColRef Unexecuted instantiation: planLogicCreater.c:tDecodeSColRef Unexecuted instantiation: planOptimizer.c:tDecodeSColRef Unexecuted instantiation: planPhysiCreater.c:tDecodeSColRef Unexecuted instantiation: planScaleOut.c:tDecodeSColRef Unexecuted instantiation: planSpliter.c:tDecodeSColRef Unexecuted instantiation: planUtil.c:tDecodeSColRef Unexecuted instantiation: planValidator.c:tDecodeSColRef Unexecuted instantiation: catalog.c:tDecodeSColRef Unexecuted instantiation: ctgAsync.c:tDecodeSColRef Unexecuted instantiation: ctgCache.c:tDecodeSColRef Unexecuted instantiation: ctgDbg.c:tDecodeSColRef Unexecuted instantiation: ctgRemote.c:tDecodeSColRef Unexecuted instantiation: ctgRent.c:tDecodeSColRef Unexecuted instantiation: ctgUtil.c:tDecodeSColRef Unexecuted instantiation: extConnector.c:tDecodeSColRef Unexecuted instantiation: extDialect.c:tDecodeSColRef Unexecuted instantiation: extDialectDefaults.c:tDecodeSColRef Unexecuted instantiation: functionMgt.c:tDecodeSColRef Unexecuted instantiation: tudf.c:tDecodeSColRef Unexecuted instantiation: builtins.c:tDecodeSColRef Unexecuted instantiation: builtinsimpl.c:tDecodeSColRef Unexecuted instantiation: spillDistinctSet.c:tDecodeSColRef Unexecuted instantiation: thistogram.c:tDecodeSColRef Unexecuted instantiation: tpercentile.c:tDecodeSColRef Unexecuted instantiation: tavgfunction.c:tDecodeSColRef Unexecuted instantiation: tminmax.c:tDecodeSColRef Unexecuted instantiation: tminmaxavx.c:tDecodeSColRef Unexecuted instantiation: filter.c:tDecodeSColRef Unexecuted instantiation: scalar.c:tDecodeSColRef Unexecuted instantiation: sclfunc.c:tDecodeSColRef Unexecuted instantiation: sclvector.c:tDecodeSColRef Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSColRef Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSColRef Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSColRef Unexecuted instantiation: extTypeMap.c:tDecodeSColRef Unexecuted instantiation: queryUtil.c:tDecodeSColRef Unexecuted instantiation: querymsg.c:tDecodeSColRef Unexecuted instantiation: trans.c:tDecodeSColRef Unexecuted instantiation: transCli.c:tDecodeSColRef Unexecuted instantiation: transComm.c:tDecodeSColRef Unexecuted instantiation: transSasl.c:tDecodeSColRef Unexecuted instantiation: transSvr.c:tDecodeSColRef Unexecuted instantiation: transTLS.c:tDecodeSColRef Unexecuted instantiation: thttp.c:tDecodeSColRef Unexecuted instantiation: geomFunc.c:tDecodeSColRef Unexecuted instantiation: tconfig.c:tDecodeSColRef Unexecuted instantiation: tdigest.c:tDecodeSColRef Unexecuted instantiation: tlog.c:tDecodeSColRef Unexecuted instantiation: tmempool.c:tDecodeSColRef Unexecuted instantiation: tpagedbuf.c:tDecodeSColRef Unexecuted instantiation: mpDirect.c:tDecodeSColRef Unexecuted instantiation: extCapability.c:tDecodeSColRef Unexecuted instantiation: systable.c:tDecodeSColRef Unexecuted instantiation: tanalytics.c:tDecodeSColRef Unexecuted instantiation: tdatablock.c:tDecodeSColRef Unexecuted instantiation: tdataformat.c:tDecodeSColRef Unexecuted instantiation: tglobal.c:tDecodeSColRef Unexecuted instantiation: tmisce.c:tDecodeSColRef Unexecuted instantiation: tname.c:tDecodeSColRef Unexecuted instantiation: tpriv.c:tDecodeSColRef Unexecuted instantiation: ttime.c:tDecodeSColRef Unexecuted instantiation: tvariant.c:tDecodeSColRef Unexecuted instantiation: streamMsg.c:tDecodeSColRef Unexecuted instantiation: streamWindowPlan.c:tDecodeSColRef Unexecuted instantiation: tmsg.c:tDecodeSColRef Unexecuted instantiation: xnode.c:tDecodeSColRef Unexecuted instantiation: tencrypt.c:tDecodeSColRef Unexecuted instantiation: streamJson.c:tDecodeSColRef Unexecuted instantiation: crypt.c:tDecodeSColRef |
1748 | | |
1749 | 0 | static FORCE_INLINE int32_t tEncodeSColRefExt(SEncoder* pEncoder, const SColRef* pColRef) { |
1750 | 0 | if (pColRef->hasRef) { |
1751 | 0 | TAOS_CHECK_RETURN(tEncodeI8(pEncoder, pColRef->refType)); |
1752 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pColRef->refSourceName)); |
1753 | 0 | TAOS_CHECK_RETURN(tEncodeCStr(pEncoder, pColRef->refSchemaName)); |
1754 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, pColRef->tagCondLen)); |
1755 | 0 | if (pColRef->tagCondLen > 0) { |
1756 | 0 | TAOS_CHECK_RETURN(tEncodeBinary(pEncoder, (const uint8_t*)pColRef->tagCondJson, pColRef->tagCondLen)); |
1757 | 0 | } |
1758 | 0 | } |
1759 | 0 | return 0; |
1760 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSColRefExt Unexecuted instantiation: parser.c:tEncodeSColRefExt Unexecuted instantiation: parTranslater.c:tEncodeSColRefExt Unexecuted instantiation: parUtil.c:tEncodeSColRefExt Unexecuted instantiation: parAstParser.c:tEncodeSColRefExt Unexecuted instantiation: parAuthenticator.c:tEncodeSColRefExt Unexecuted instantiation: parCalcConst.c:tEncodeSColRefExt Unexecuted instantiation: parInsertSql.c:tEncodeSColRefExt Unexecuted instantiation: parInsertUtil.c:tEncodeSColRefExt Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSColRefExt Unexecuted instantiation: parAstCreater.c:tEncodeSColRefExt Unexecuted instantiation: parInsertSml.c:tEncodeSColRefExt Unexecuted instantiation: planner.c:tEncodeSColRefExt Unexecuted instantiation: planLogicCreater.c:tEncodeSColRefExt Unexecuted instantiation: planOptimizer.c:tEncodeSColRefExt Unexecuted instantiation: planPhysiCreater.c:tEncodeSColRefExt Unexecuted instantiation: planScaleOut.c:tEncodeSColRefExt Unexecuted instantiation: planSpliter.c:tEncodeSColRefExt Unexecuted instantiation: planUtil.c:tEncodeSColRefExt Unexecuted instantiation: planValidator.c:tEncodeSColRefExt Unexecuted instantiation: catalog.c:tEncodeSColRefExt Unexecuted instantiation: ctgAsync.c:tEncodeSColRefExt Unexecuted instantiation: ctgCache.c:tEncodeSColRefExt Unexecuted instantiation: ctgDbg.c:tEncodeSColRefExt Unexecuted instantiation: ctgRemote.c:tEncodeSColRefExt Unexecuted instantiation: ctgRent.c:tEncodeSColRefExt Unexecuted instantiation: ctgUtil.c:tEncodeSColRefExt Unexecuted instantiation: extConnector.c:tEncodeSColRefExt Unexecuted instantiation: extDialect.c:tEncodeSColRefExt Unexecuted instantiation: extDialectDefaults.c:tEncodeSColRefExt Unexecuted instantiation: functionMgt.c:tEncodeSColRefExt Unexecuted instantiation: tudf.c:tEncodeSColRefExt Unexecuted instantiation: builtins.c:tEncodeSColRefExt Unexecuted instantiation: builtinsimpl.c:tEncodeSColRefExt Unexecuted instantiation: spillDistinctSet.c:tEncodeSColRefExt Unexecuted instantiation: thistogram.c:tEncodeSColRefExt Unexecuted instantiation: tpercentile.c:tEncodeSColRefExt Unexecuted instantiation: tavgfunction.c:tEncodeSColRefExt Unexecuted instantiation: tminmax.c:tEncodeSColRefExt Unexecuted instantiation: tminmaxavx.c:tEncodeSColRefExt Unexecuted instantiation: filter.c:tEncodeSColRefExt Unexecuted instantiation: scalar.c:tEncodeSColRefExt Unexecuted instantiation: sclfunc.c:tEncodeSColRefExt Unexecuted instantiation: sclvector.c:tEncodeSColRefExt Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSColRefExt Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSColRefExt Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSColRefExt Unexecuted instantiation: extTypeMap.c:tEncodeSColRefExt Unexecuted instantiation: queryUtil.c:tEncodeSColRefExt Unexecuted instantiation: querymsg.c:tEncodeSColRefExt Unexecuted instantiation: trans.c:tEncodeSColRefExt Unexecuted instantiation: transCli.c:tEncodeSColRefExt Unexecuted instantiation: transComm.c:tEncodeSColRefExt Unexecuted instantiation: transSasl.c:tEncodeSColRefExt Unexecuted instantiation: transSvr.c:tEncodeSColRefExt Unexecuted instantiation: transTLS.c:tEncodeSColRefExt Unexecuted instantiation: thttp.c:tEncodeSColRefExt Unexecuted instantiation: geomFunc.c:tEncodeSColRefExt Unexecuted instantiation: tconfig.c:tEncodeSColRefExt Unexecuted instantiation: tdigest.c:tEncodeSColRefExt Unexecuted instantiation: tlog.c:tEncodeSColRefExt Unexecuted instantiation: tmempool.c:tEncodeSColRefExt Unexecuted instantiation: tpagedbuf.c:tEncodeSColRefExt Unexecuted instantiation: mpDirect.c:tEncodeSColRefExt Unexecuted instantiation: extCapability.c:tEncodeSColRefExt Unexecuted instantiation: systable.c:tEncodeSColRefExt Unexecuted instantiation: tanalytics.c:tEncodeSColRefExt Unexecuted instantiation: tdatablock.c:tEncodeSColRefExt Unexecuted instantiation: tdataformat.c:tEncodeSColRefExt Unexecuted instantiation: tglobal.c:tEncodeSColRefExt Unexecuted instantiation: tmisce.c:tEncodeSColRefExt Unexecuted instantiation: tname.c:tEncodeSColRefExt Unexecuted instantiation: tpriv.c:tEncodeSColRefExt Unexecuted instantiation: ttime.c:tEncodeSColRefExt Unexecuted instantiation: tvariant.c:tEncodeSColRefExt Unexecuted instantiation: streamMsg.c:tEncodeSColRefExt Unexecuted instantiation: streamWindowPlan.c:tEncodeSColRefExt Unexecuted instantiation: tmsg.c:tEncodeSColRefExt Unexecuted instantiation: xnode.c:tEncodeSColRefExt Unexecuted instantiation: tencrypt.c:tEncodeSColRefExt Unexecuted instantiation: streamJson.c:tEncodeSColRefExt Unexecuted instantiation: crypt.c:tEncodeSColRefExt |
1761 | | |
1762 | 0 | static FORCE_INLINE int32_t tDecodeSColRefExt(SDecoder* pDecoder, SColRef* pColRef) { |
1763 | 0 | if (pColRef->hasRef) { |
1764 | 0 | TAOS_CHECK_RETURN(tDecodeI8(pDecoder, &pColRef->refType)); |
1765 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pColRef->refSourceName)); |
1766 | 0 | TAOS_CHECK_RETURN(tDecodeCStrTo(pDecoder, pColRef->refSchemaName)); |
1767 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pColRef->tagCondLen)); |
1768 | 0 | if (pColRef->tagCondLen > 0) { |
1769 | 0 | uint8_t* tmpBuf = NULL; |
1770 | 0 | uint32_t tmpLen = 0; |
1771 | 0 | TAOS_CHECK_RETURN(tDecodeBinary(pDecoder, &tmpBuf, &tmpLen)); |
1772 | 0 | if ((int32_t)tmpLen != pColRef->tagCondLen) { |
1773 | 0 | return TSDB_CODE_INVALID_MSG; |
1774 | 0 | } |
1775 | 0 | pColRef->tagCondJson = (char*)taosMemoryMalloc(pColRef->tagCondLen + 1); |
1776 | 0 | if (pColRef->tagCondJson == NULL) { |
1777 | 0 | TAOS_CHECK_RETURN(terrno); |
1778 | 0 | } |
1779 | 0 | memcpy(pColRef->tagCondJson, tmpBuf, pColRef->tagCondLen); |
1780 | 0 | pColRef->tagCondJson[pColRef->tagCondLen] = '\0'; |
1781 | 0 | } |
1782 | 0 | } |
1783 | | |
1784 | 0 | return 0; |
1785 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSColRefExt Unexecuted instantiation: parser.c:tDecodeSColRefExt Unexecuted instantiation: parTranslater.c:tDecodeSColRefExt Unexecuted instantiation: parUtil.c:tDecodeSColRefExt Unexecuted instantiation: parAstParser.c:tDecodeSColRefExt Unexecuted instantiation: parAuthenticator.c:tDecodeSColRefExt Unexecuted instantiation: parCalcConst.c:tDecodeSColRefExt Unexecuted instantiation: parInsertSql.c:tDecodeSColRefExt Unexecuted instantiation: parInsertUtil.c:tDecodeSColRefExt Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSColRefExt Unexecuted instantiation: parAstCreater.c:tDecodeSColRefExt Unexecuted instantiation: parInsertSml.c:tDecodeSColRefExt Unexecuted instantiation: planner.c:tDecodeSColRefExt Unexecuted instantiation: planLogicCreater.c:tDecodeSColRefExt Unexecuted instantiation: planOptimizer.c:tDecodeSColRefExt Unexecuted instantiation: planPhysiCreater.c:tDecodeSColRefExt Unexecuted instantiation: planScaleOut.c:tDecodeSColRefExt Unexecuted instantiation: planSpliter.c:tDecodeSColRefExt Unexecuted instantiation: planUtil.c:tDecodeSColRefExt Unexecuted instantiation: planValidator.c:tDecodeSColRefExt Unexecuted instantiation: catalog.c:tDecodeSColRefExt Unexecuted instantiation: ctgAsync.c:tDecodeSColRefExt Unexecuted instantiation: ctgCache.c:tDecodeSColRefExt Unexecuted instantiation: ctgDbg.c:tDecodeSColRefExt Unexecuted instantiation: ctgRemote.c:tDecodeSColRefExt Unexecuted instantiation: ctgRent.c:tDecodeSColRefExt Unexecuted instantiation: ctgUtil.c:tDecodeSColRefExt Unexecuted instantiation: extConnector.c:tDecodeSColRefExt Unexecuted instantiation: extDialect.c:tDecodeSColRefExt Unexecuted instantiation: extDialectDefaults.c:tDecodeSColRefExt Unexecuted instantiation: functionMgt.c:tDecodeSColRefExt Unexecuted instantiation: tudf.c:tDecodeSColRefExt Unexecuted instantiation: builtins.c:tDecodeSColRefExt Unexecuted instantiation: builtinsimpl.c:tDecodeSColRefExt Unexecuted instantiation: spillDistinctSet.c:tDecodeSColRefExt Unexecuted instantiation: thistogram.c:tDecodeSColRefExt Unexecuted instantiation: tpercentile.c:tDecodeSColRefExt Unexecuted instantiation: tavgfunction.c:tDecodeSColRefExt Unexecuted instantiation: tminmax.c:tDecodeSColRefExt Unexecuted instantiation: tminmaxavx.c:tDecodeSColRefExt Unexecuted instantiation: filter.c:tDecodeSColRefExt Unexecuted instantiation: scalar.c:tDecodeSColRefExt Unexecuted instantiation: sclfunc.c:tDecodeSColRefExt Unexecuted instantiation: sclvector.c:tDecodeSColRefExt Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSColRefExt Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSColRefExt Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSColRefExt Unexecuted instantiation: extTypeMap.c:tDecodeSColRefExt Unexecuted instantiation: queryUtil.c:tDecodeSColRefExt Unexecuted instantiation: querymsg.c:tDecodeSColRefExt Unexecuted instantiation: trans.c:tDecodeSColRefExt Unexecuted instantiation: transCli.c:tDecodeSColRefExt Unexecuted instantiation: transComm.c:tDecodeSColRefExt Unexecuted instantiation: transSasl.c:tDecodeSColRefExt Unexecuted instantiation: transSvr.c:tDecodeSColRefExt Unexecuted instantiation: transTLS.c:tDecodeSColRefExt Unexecuted instantiation: thttp.c:tDecodeSColRefExt Unexecuted instantiation: geomFunc.c:tDecodeSColRefExt Unexecuted instantiation: tconfig.c:tDecodeSColRefExt Unexecuted instantiation: tdigest.c:tDecodeSColRefExt Unexecuted instantiation: tlog.c:tDecodeSColRefExt Unexecuted instantiation: tmempool.c:tDecodeSColRefExt Unexecuted instantiation: tpagedbuf.c:tDecodeSColRefExt Unexecuted instantiation: mpDirect.c:tDecodeSColRefExt Unexecuted instantiation: extCapability.c:tDecodeSColRefExt Unexecuted instantiation: systable.c:tDecodeSColRefExt Unexecuted instantiation: tanalytics.c:tDecodeSColRefExt Unexecuted instantiation: tdatablock.c:tDecodeSColRefExt Unexecuted instantiation: tdataformat.c:tDecodeSColRefExt Unexecuted instantiation: tglobal.c:tDecodeSColRefExt Unexecuted instantiation: tmisce.c:tDecodeSColRefExt Unexecuted instantiation: tname.c:tDecodeSColRefExt Unexecuted instantiation: tpriv.c:tDecodeSColRefExt Unexecuted instantiation: ttime.c:tDecodeSColRefExt Unexecuted instantiation: tvariant.c:tDecodeSColRefExt Unexecuted instantiation: streamMsg.c:tDecodeSColRefExt Unexecuted instantiation: streamWindowPlan.c:tDecodeSColRefExt Unexecuted instantiation: tmsg.c:tDecodeSColRefExt Unexecuted instantiation: xnode.c:tDecodeSColRefExt Unexecuted instantiation: tencrypt.c:tDecodeSColRefExt Unexecuted instantiation: streamJson.c:tDecodeSColRefExt Unexecuted instantiation: crypt.c:tDecodeSColRefExt |
1786 | | |
1787 | 0 | static FORCE_INLINE int32_t tEncodeSColRefFilterCond(SEncoder* pEncoder, const SColRef* pColRef) { |
1788 | 0 | int32_t len = pColRef->hasRef ? pColRef->filterCondLen : 0; |
1789 | 0 | if (len < 0 || (len > 0 && NULL == pColRef->filterCondJson)) { |
1790 | 0 | return TSDB_CODE_INVALID_MSG; |
1791 | 0 | } |
1792 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, len)); |
1793 | 0 | if (len > 0) { |
1794 | 0 | TAOS_CHECK_RETURN(tEncodeBinary(pEncoder, (const uint8_t*)pColRef->filterCondJson, len)); |
1795 | 0 | } |
1796 | 0 | return TSDB_CODE_SUCCESS; |
1797 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSColRefFilterCond Unexecuted instantiation: parser.c:tEncodeSColRefFilterCond Unexecuted instantiation: parTranslater.c:tEncodeSColRefFilterCond Unexecuted instantiation: parUtil.c:tEncodeSColRefFilterCond Unexecuted instantiation: parAstParser.c:tEncodeSColRefFilterCond Unexecuted instantiation: parAuthenticator.c:tEncodeSColRefFilterCond Unexecuted instantiation: parCalcConst.c:tEncodeSColRefFilterCond Unexecuted instantiation: parInsertSql.c:tEncodeSColRefFilterCond Unexecuted instantiation: parInsertUtil.c:tEncodeSColRefFilterCond Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSColRefFilterCond Unexecuted instantiation: parAstCreater.c:tEncodeSColRefFilterCond Unexecuted instantiation: parInsertSml.c:tEncodeSColRefFilterCond Unexecuted instantiation: planner.c:tEncodeSColRefFilterCond Unexecuted instantiation: planLogicCreater.c:tEncodeSColRefFilterCond Unexecuted instantiation: planOptimizer.c:tEncodeSColRefFilterCond Unexecuted instantiation: planPhysiCreater.c:tEncodeSColRefFilterCond Unexecuted instantiation: planScaleOut.c:tEncodeSColRefFilterCond Unexecuted instantiation: planSpliter.c:tEncodeSColRefFilterCond Unexecuted instantiation: planUtil.c:tEncodeSColRefFilterCond Unexecuted instantiation: planValidator.c:tEncodeSColRefFilterCond Unexecuted instantiation: catalog.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgAsync.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgCache.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgDbg.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgRemote.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgRent.c:tEncodeSColRefFilterCond Unexecuted instantiation: ctgUtil.c:tEncodeSColRefFilterCond Unexecuted instantiation: extConnector.c:tEncodeSColRefFilterCond Unexecuted instantiation: extDialect.c:tEncodeSColRefFilterCond Unexecuted instantiation: extDialectDefaults.c:tEncodeSColRefFilterCond Unexecuted instantiation: functionMgt.c:tEncodeSColRefFilterCond Unexecuted instantiation: tudf.c:tEncodeSColRefFilterCond Unexecuted instantiation: builtins.c:tEncodeSColRefFilterCond Unexecuted instantiation: builtinsimpl.c:tEncodeSColRefFilterCond Unexecuted instantiation: spillDistinctSet.c:tEncodeSColRefFilterCond Unexecuted instantiation: thistogram.c:tEncodeSColRefFilterCond Unexecuted instantiation: tpercentile.c:tEncodeSColRefFilterCond Unexecuted instantiation: tavgfunction.c:tEncodeSColRefFilterCond Unexecuted instantiation: tminmax.c:tEncodeSColRefFilterCond Unexecuted instantiation: tminmaxavx.c:tEncodeSColRefFilterCond Unexecuted instantiation: filter.c:tEncodeSColRefFilterCond Unexecuted instantiation: scalar.c:tEncodeSColRefFilterCond Unexecuted instantiation: sclfunc.c:tEncodeSColRefFilterCond Unexecuted instantiation: sclvector.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSColRefFilterCond Unexecuted instantiation: extTypeMap.c:tEncodeSColRefFilterCond Unexecuted instantiation: queryUtil.c:tEncodeSColRefFilterCond Unexecuted instantiation: querymsg.c:tEncodeSColRefFilterCond Unexecuted instantiation: trans.c:tEncodeSColRefFilterCond Unexecuted instantiation: transCli.c:tEncodeSColRefFilterCond Unexecuted instantiation: transComm.c:tEncodeSColRefFilterCond Unexecuted instantiation: transSasl.c:tEncodeSColRefFilterCond Unexecuted instantiation: transSvr.c:tEncodeSColRefFilterCond Unexecuted instantiation: transTLS.c:tEncodeSColRefFilterCond Unexecuted instantiation: thttp.c:tEncodeSColRefFilterCond Unexecuted instantiation: geomFunc.c:tEncodeSColRefFilterCond Unexecuted instantiation: tconfig.c:tEncodeSColRefFilterCond Unexecuted instantiation: tdigest.c:tEncodeSColRefFilterCond Unexecuted instantiation: tlog.c:tEncodeSColRefFilterCond Unexecuted instantiation: tmempool.c:tEncodeSColRefFilterCond Unexecuted instantiation: tpagedbuf.c:tEncodeSColRefFilterCond Unexecuted instantiation: mpDirect.c:tEncodeSColRefFilterCond Unexecuted instantiation: extCapability.c:tEncodeSColRefFilterCond Unexecuted instantiation: systable.c:tEncodeSColRefFilterCond Unexecuted instantiation: tanalytics.c:tEncodeSColRefFilterCond Unexecuted instantiation: tdatablock.c:tEncodeSColRefFilterCond Unexecuted instantiation: tdataformat.c:tEncodeSColRefFilterCond Unexecuted instantiation: tglobal.c:tEncodeSColRefFilterCond Unexecuted instantiation: tmisce.c:tEncodeSColRefFilterCond Unexecuted instantiation: tname.c:tEncodeSColRefFilterCond Unexecuted instantiation: tpriv.c:tEncodeSColRefFilterCond Unexecuted instantiation: ttime.c:tEncodeSColRefFilterCond Unexecuted instantiation: tvariant.c:tEncodeSColRefFilterCond Unexecuted instantiation: streamMsg.c:tEncodeSColRefFilterCond Unexecuted instantiation: streamWindowPlan.c:tEncodeSColRefFilterCond Unexecuted instantiation: tmsg.c:tEncodeSColRefFilterCond Unexecuted instantiation: xnode.c:tEncodeSColRefFilterCond Unexecuted instantiation: tencrypt.c:tEncodeSColRefFilterCond Unexecuted instantiation: streamJson.c:tEncodeSColRefFilterCond Unexecuted instantiation: crypt.c:tEncodeSColRefFilterCond |
1798 | | |
1799 | 0 | static FORCE_INLINE int32_t tDecodeSColRefFilterCondRaw(SDecoder* pDecoder, SColRef* pColRef, uint8_t** ppBuf) { |
1800 | 0 | *ppBuf = NULL; |
1801 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pColRef->filterCondLen)); |
1802 | 0 | if (pColRef->filterCondLen < 0 || (!pColRef->hasRef && pColRef->filterCondLen > 0)) { |
1803 | 0 | return TSDB_CODE_INVALID_MSG; |
1804 | 0 | } |
1805 | 0 | if (pColRef->filterCondLen > 0) { |
1806 | 0 | uint32_t len = 0; |
1807 | 0 | TAOS_CHECK_RETURN(tDecodeBinary(pDecoder, ppBuf, &len)); |
1808 | 0 | if (len != (uint32_t)pColRef->filterCondLen) { |
1809 | 0 | return TSDB_CODE_INVALID_MSG; |
1810 | 0 | } |
1811 | 0 | } |
1812 | 0 | return TSDB_CODE_SUCCESS; |
1813 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parser.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parTranslater.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parUtil.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parAstParser.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parAuthenticator.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parCalcConst.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parInsertSql.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parInsertUtil.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parAstCreater.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: parInsertSml.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planner.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planLogicCreater.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planOptimizer.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planPhysiCreater.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planScaleOut.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planSpliter.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planUtil.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: planValidator.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: catalog.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgAsync.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgCache.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgDbg.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgRemote.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgRent.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ctgUtil.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: extConnector.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: extDialect.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: extDialectDefaults.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: functionMgt.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tudf.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: builtins.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: builtinsimpl.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: spillDistinctSet.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: thistogram.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tpercentile.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tavgfunction.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tminmax.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tminmaxavx.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: filter.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: scalar.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: sclfunc.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: sclvector.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: extTypeMap.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: queryUtil.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: querymsg.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: trans.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: transCli.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: transComm.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: transSasl.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: transSvr.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: transTLS.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: thttp.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: geomFunc.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tconfig.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tdigest.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tlog.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tmempool.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tpagedbuf.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: mpDirect.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: extCapability.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: systable.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tanalytics.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tdatablock.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tdataformat.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tglobal.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tmisce.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tname.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tpriv.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: ttime.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tvariant.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: streamMsg.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: streamWindowPlan.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tmsg.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: xnode.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: tencrypt.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: streamJson.c:tDecodeSColRefFilterCondRaw Unexecuted instantiation: crypt.c:tDecodeSColRefFilterCondRaw |
1814 | | |
1815 | 0 | static FORCE_INLINE int32_t taosEncodeSSchemaWrapper(void** buf, const SSchemaWrapper* pSW) { |
1816 | 0 | int32_t tlen = 0; |
1817 | 0 | tlen += taosEncodeVariantI32(buf, pSW->nCols); |
1818 | 0 | tlen += taosEncodeVariantI32(buf, pSW->version); |
1819 | 0 | for (int32_t i = 0; i < pSW->nCols; i++) { |
1820 | 0 | tlen += taosEncodeSSchema(buf, &pSW->pSchema[i]); |
1821 | 0 | } |
1822 | 0 | return tlen; |
1823 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parser.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parTranslater.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parUtil.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parAstParser.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parAuthenticator.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parCalcConst.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parInsertSql.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parInsertUtil.c:taosEncodeSSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parAstCreater.c:taosEncodeSSchemaWrapper Unexecuted instantiation: parInsertSml.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planner.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planLogicCreater.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planOptimizer.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planScaleOut.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planSpliter.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planUtil.c:taosEncodeSSchemaWrapper Unexecuted instantiation: planValidator.c:taosEncodeSSchemaWrapper Unexecuted instantiation: catalog.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgAsync.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgCache.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgDbg.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgRemote.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgRent.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ctgUtil.c:taosEncodeSSchemaWrapper Unexecuted instantiation: extConnector.c:taosEncodeSSchemaWrapper Unexecuted instantiation: extDialect.c:taosEncodeSSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:taosEncodeSSchemaWrapper Unexecuted instantiation: functionMgt.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tudf.c:taosEncodeSSchemaWrapper Unexecuted instantiation: builtins.c:taosEncodeSSchemaWrapper Unexecuted instantiation: builtinsimpl.c:taosEncodeSSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:taosEncodeSSchemaWrapper Unexecuted instantiation: thistogram.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tpercentile.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tavgfunction.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tminmax.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tminmaxavx.c:taosEncodeSSchemaWrapper Unexecuted instantiation: filter.c:taosEncodeSSchemaWrapper Unexecuted instantiation: scalar.c:taosEncodeSSchemaWrapper Unexecuted instantiation: sclfunc.c:taosEncodeSSchemaWrapper Unexecuted instantiation: sclvector.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:taosEncodeSSchemaWrapper Unexecuted instantiation: extTypeMap.c:taosEncodeSSchemaWrapper Unexecuted instantiation: queryUtil.c:taosEncodeSSchemaWrapper Unexecuted instantiation: querymsg.c:taosEncodeSSchemaWrapper Unexecuted instantiation: trans.c:taosEncodeSSchemaWrapper Unexecuted instantiation: transCli.c:taosEncodeSSchemaWrapper Unexecuted instantiation: transComm.c:taosEncodeSSchemaWrapper Unexecuted instantiation: transSasl.c:taosEncodeSSchemaWrapper Unexecuted instantiation: transSvr.c:taosEncodeSSchemaWrapper Unexecuted instantiation: transTLS.c:taosEncodeSSchemaWrapper Unexecuted instantiation: thttp.c:taosEncodeSSchemaWrapper Unexecuted instantiation: geomFunc.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tconfig.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tdigest.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tlog.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tmempool.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tpagedbuf.c:taosEncodeSSchemaWrapper Unexecuted instantiation: mpDirect.c:taosEncodeSSchemaWrapper Unexecuted instantiation: extCapability.c:taosEncodeSSchemaWrapper Unexecuted instantiation: systable.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tanalytics.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tdatablock.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tdataformat.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tglobal.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tmisce.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tname.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tpriv.c:taosEncodeSSchemaWrapper Unexecuted instantiation: ttime.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tvariant.c:taosEncodeSSchemaWrapper Unexecuted instantiation: streamMsg.c:taosEncodeSSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tmsg.c:taosEncodeSSchemaWrapper Unexecuted instantiation: xnode.c:taosEncodeSSchemaWrapper Unexecuted instantiation: tencrypt.c:taosEncodeSSchemaWrapper Unexecuted instantiation: streamJson.c:taosEncodeSSchemaWrapper Unexecuted instantiation: crypt.c:taosEncodeSSchemaWrapper |
1824 | | |
1825 | 0 | static FORCE_INLINE void* taosDecodeSSchemaWrapper(const void* buf, SSchemaWrapper* pSW) { |
1826 | 0 | buf = taosDecodeVariantI32(buf, &pSW->nCols); |
1827 | 0 | buf = taosDecodeVariantI32(buf, &pSW->version); |
1828 | 0 | if (pSW->nCols > 0) { |
1829 | 0 | pSW->pSchema = (SSchema*)taosMemoryCalloc(pSW->nCols, sizeof(SSchema)); |
1830 | 0 | if (pSW->pSchema == NULL) { |
1831 | 0 | return NULL; |
1832 | 0 | } |
1833 | 0 |
|
1834 | 0 | for (int32_t i = 0; i < pSW->nCols; i++) { |
1835 | 0 | buf = taosDecodeSSchema(buf, &pSW->pSchema[i]); |
1836 | 0 | } |
1837 | 0 | } else { |
1838 | 0 | pSW->pSchema = NULL; |
1839 | 0 | } |
1840 | 0 | return (void*)buf; |
1841 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parser.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parTranslater.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parUtil.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parAstParser.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parAuthenticator.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parCalcConst.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parInsertSql.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parInsertUtil.c:taosDecodeSSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parAstCreater.c:taosDecodeSSchemaWrapper Unexecuted instantiation: parInsertSml.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planner.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planLogicCreater.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planOptimizer.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planScaleOut.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planSpliter.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planUtil.c:taosDecodeSSchemaWrapper Unexecuted instantiation: planValidator.c:taosDecodeSSchemaWrapper Unexecuted instantiation: catalog.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgAsync.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgCache.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgDbg.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgRemote.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgRent.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ctgUtil.c:taosDecodeSSchemaWrapper Unexecuted instantiation: extConnector.c:taosDecodeSSchemaWrapper Unexecuted instantiation: extDialect.c:taosDecodeSSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:taosDecodeSSchemaWrapper Unexecuted instantiation: functionMgt.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tudf.c:taosDecodeSSchemaWrapper Unexecuted instantiation: builtins.c:taosDecodeSSchemaWrapper Unexecuted instantiation: builtinsimpl.c:taosDecodeSSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:taosDecodeSSchemaWrapper Unexecuted instantiation: thistogram.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tpercentile.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tavgfunction.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tminmax.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tminmaxavx.c:taosDecodeSSchemaWrapper Unexecuted instantiation: filter.c:taosDecodeSSchemaWrapper Unexecuted instantiation: scalar.c:taosDecodeSSchemaWrapper Unexecuted instantiation: sclfunc.c:taosDecodeSSchemaWrapper Unexecuted instantiation: sclvector.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:taosDecodeSSchemaWrapper Unexecuted instantiation: extTypeMap.c:taosDecodeSSchemaWrapper Unexecuted instantiation: queryUtil.c:taosDecodeSSchemaWrapper Unexecuted instantiation: querymsg.c:taosDecodeSSchemaWrapper Unexecuted instantiation: trans.c:taosDecodeSSchemaWrapper Unexecuted instantiation: transCli.c:taosDecodeSSchemaWrapper Unexecuted instantiation: transComm.c:taosDecodeSSchemaWrapper Unexecuted instantiation: transSasl.c:taosDecodeSSchemaWrapper Unexecuted instantiation: transSvr.c:taosDecodeSSchemaWrapper Unexecuted instantiation: transTLS.c:taosDecodeSSchemaWrapper Unexecuted instantiation: thttp.c:taosDecodeSSchemaWrapper Unexecuted instantiation: geomFunc.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tconfig.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tdigest.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tlog.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tmempool.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tpagedbuf.c:taosDecodeSSchemaWrapper Unexecuted instantiation: mpDirect.c:taosDecodeSSchemaWrapper Unexecuted instantiation: extCapability.c:taosDecodeSSchemaWrapper Unexecuted instantiation: systable.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tanalytics.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tdatablock.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tdataformat.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tglobal.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tmisce.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tname.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tpriv.c:taosDecodeSSchemaWrapper Unexecuted instantiation: ttime.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tvariant.c:taosDecodeSSchemaWrapper Unexecuted instantiation: streamMsg.c:taosDecodeSSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tmsg.c:taosDecodeSSchemaWrapper Unexecuted instantiation: xnode.c:taosDecodeSSchemaWrapper Unexecuted instantiation: tencrypt.c:taosDecodeSSchemaWrapper Unexecuted instantiation: streamJson.c:taosDecodeSSchemaWrapper Unexecuted instantiation: crypt.c:taosDecodeSSchemaWrapper |
1842 | | |
1843 | 0 | static FORCE_INLINE int32_t tEncodeSSchemaWrapper(SEncoder* pEncoder, const SSchemaWrapper* pSW) { |
1844 | 0 | if (pSW == NULL) { |
1845 | 0 | return TSDB_CODE_INVALID_PARA; |
1846 | 0 | } |
1847 | 0 | TAOS_CHECK_RETURN(tEncodeI32v(pEncoder, pSW->nCols)); |
1848 | 0 | TAOS_CHECK_RETURN(tEncodeI32v(pEncoder, pSW->version)); |
1849 | 0 | for (int32_t i = 0; i < pSW->nCols; i++) { |
1850 | 0 | TAOS_CHECK_RETURN(tEncodeSSchema(pEncoder, &pSW->pSchema[i])); |
1851 | 0 | } |
1852 | 0 | return 0; |
1853 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSSchemaWrapper Unexecuted instantiation: parser.c:tEncodeSSchemaWrapper Unexecuted instantiation: parTranslater.c:tEncodeSSchemaWrapper Unexecuted instantiation: parUtil.c:tEncodeSSchemaWrapper Unexecuted instantiation: parAstParser.c:tEncodeSSchemaWrapper Unexecuted instantiation: parAuthenticator.c:tEncodeSSchemaWrapper Unexecuted instantiation: parCalcConst.c:tEncodeSSchemaWrapper Unexecuted instantiation: parInsertSql.c:tEncodeSSchemaWrapper Unexecuted instantiation: parInsertUtil.c:tEncodeSSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSSchemaWrapper Unexecuted instantiation: parAstCreater.c:tEncodeSSchemaWrapper Unexecuted instantiation: parInsertSml.c:tEncodeSSchemaWrapper Unexecuted instantiation: planner.c:tEncodeSSchemaWrapper Unexecuted instantiation: planLogicCreater.c:tEncodeSSchemaWrapper Unexecuted instantiation: planOptimizer.c:tEncodeSSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:tEncodeSSchemaWrapper Unexecuted instantiation: planScaleOut.c:tEncodeSSchemaWrapper Unexecuted instantiation: planSpliter.c:tEncodeSSchemaWrapper Unexecuted instantiation: planUtil.c:tEncodeSSchemaWrapper Unexecuted instantiation: planValidator.c:tEncodeSSchemaWrapper Unexecuted instantiation: catalog.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgAsync.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgCache.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgDbg.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgRemote.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgRent.c:tEncodeSSchemaWrapper Unexecuted instantiation: ctgUtil.c:tEncodeSSchemaWrapper Unexecuted instantiation: extConnector.c:tEncodeSSchemaWrapper Unexecuted instantiation: extDialect.c:tEncodeSSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:tEncodeSSchemaWrapper Unexecuted instantiation: functionMgt.c:tEncodeSSchemaWrapper Unexecuted instantiation: tudf.c:tEncodeSSchemaWrapper Unexecuted instantiation: builtins.c:tEncodeSSchemaWrapper Unexecuted instantiation: builtinsimpl.c:tEncodeSSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:tEncodeSSchemaWrapper Unexecuted instantiation: thistogram.c:tEncodeSSchemaWrapper Unexecuted instantiation: tpercentile.c:tEncodeSSchemaWrapper Unexecuted instantiation: tavgfunction.c:tEncodeSSchemaWrapper Unexecuted instantiation: tminmax.c:tEncodeSSchemaWrapper Unexecuted instantiation: tminmaxavx.c:tEncodeSSchemaWrapper Unexecuted instantiation: filter.c:tEncodeSSchemaWrapper Unexecuted instantiation: scalar.c:tEncodeSSchemaWrapper Unexecuted instantiation: sclfunc.c:tEncodeSSchemaWrapper Unexecuted instantiation: sclvector.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSSchemaWrapper Unexecuted instantiation: extTypeMap.c:tEncodeSSchemaWrapper Unexecuted instantiation: queryUtil.c:tEncodeSSchemaWrapper Unexecuted instantiation: querymsg.c:tEncodeSSchemaWrapper Unexecuted instantiation: trans.c:tEncodeSSchemaWrapper Unexecuted instantiation: transCli.c:tEncodeSSchemaWrapper Unexecuted instantiation: transComm.c:tEncodeSSchemaWrapper Unexecuted instantiation: transSasl.c:tEncodeSSchemaWrapper Unexecuted instantiation: transSvr.c:tEncodeSSchemaWrapper Unexecuted instantiation: transTLS.c:tEncodeSSchemaWrapper Unexecuted instantiation: thttp.c:tEncodeSSchemaWrapper Unexecuted instantiation: geomFunc.c:tEncodeSSchemaWrapper Unexecuted instantiation: tconfig.c:tEncodeSSchemaWrapper Unexecuted instantiation: tdigest.c:tEncodeSSchemaWrapper Unexecuted instantiation: tlog.c:tEncodeSSchemaWrapper Unexecuted instantiation: tmempool.c:tEncodeSSchemaWrapper Unexecuted instantiation: tpagedbuf.c:tEncodeSSchemaWrapper Unexecuted instantiation: mpDirect.c:tEncodeSSchemaWrapper Unexecuted instantiation: extCapability.c:tEncodeSSchemaWrapper Unexecuted instantiation: systable.c:tEncodeSSchemaWrapper Unexecuted instantiation: tanalytics.c:tEncodeSSchemaWrapper Unexecuted instantiation: tdatablock.c:tEncodeSSchemaWrapper Unexecuted instantiation: tdataformat.c:tEncodeSSchemaWrapper Unexecuted instantiation: tglobal.c:tEncodeSSchemaWrapper Unexecuted instantiation: tmisce.c:tEncodeSSchemaWrapper Unexecuted instantiation: tname.c:tEncodeSSchemaWrapper Unexecuted instantiation: tpriv.c:tEncodeSSchemaWrapper Unexecuted instantiation: ttime.c:tEncodeSSchemaWrapper Unexecuted instantiation: tvariant.c:tEncodeSSchemaWrapper Unexecuted instantiation: streamMsg.c:tEncodeSSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:tEncodeSSchemaWrapper Unexecuted instantiation: tmsg.c:tEncodeSSchemaWrapper Unexecuted instantiation: xnode.c:tEncodeSSchemaWrapper Unexecuted instantiation: tencrypt.c:tEncodeSSchemaWrapper Unexecuted instantiation: streamJson.c:tEncodeSSchemaWrapper Unexecuted instantiation: crypt.c:tEncodeSSchemaWrapper |
1854 | | |
1855 | 0 | static FORCE_INLINE int32_t tDecodeSSchemaWrapperImpl(SDecoder* pDecoder, SSchemaWrapper* pSW, bool decoderMalloc) { |
1856 | 0 | if (pSW == NULL) { |
1857 | 0 | return TSDB_CODE_INVALID_PARA; |
1858 | 0 | } |
1859 | 0 | TAOS_CHECK_RETURN(tDecodeI32v(pDecoder, &pSW->nCols)); |
1860 | 0 | TAOS_CHECK_RETURN(tDecodeI32v(pDecoder, &pSW->version)); |
1861 | | |
1862 | 0 | pSW->pSchema = decoderMalloc ? (SSchema*)tDecoderMalloc(pDecoder, (int64_t)pSW->nCols * sizeof(SSchema)) |
1863 | 0 | : (SSchema*)taosMemoryCalloc(pSW->nCols, sizeof(SSchema)); |
1864 | 0 | if (pSW->pSchema == NULL) { |
1865 | 0 | TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); |
1866 | 0 | } |
1867 | 0 | for (int32_t i = 0; i < pSW->nCols; i++) { |
1868 | 0 | TAOS_CHECK_RETURN(tDecodeSSchema(pDecoder, &pSW->pSchema[i])); |
1869 | 0 | } |
1870 | | |
1871 | 0 | return 0; |
1872 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parser.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parTranslater.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parUtil.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parAstParser.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parAuthenticator.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parCalcConst.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parInsertSql.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parInsertUtil.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parAstCreater.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: parInsertSml.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planner.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planLogicCreater.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planOptimizer.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planPhysiCreater.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planScaleOut.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planSpliter.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planUtil.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: planValidator.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: catalog.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgAsync.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgCache.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgDbg.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgRemote.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgRent.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ctgUtil.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: extConnector.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: extDialect.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: extDialectDefaults.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: functionMgt.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tudf.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: builtins.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: builtinsimpl.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: spillDistinctSet.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: thistogram.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tpercentile.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tavgfunction.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tminmax.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tminmaxavx.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: filter.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: scalar.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: sclfunc.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: sclvector.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: extTypeMap.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: queryUtil.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: querymsg.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: trans.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: transCli.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: transComm.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: transSasl.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: transSvr.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: transTLS.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: thttp.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: geomFunc.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tconfig.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tdigest.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tlog.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tmempool.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tpagedbuf.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: mpDirect.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: extCapability.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: systable.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tanalytics.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tdatablock.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tdataformat.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tglobal.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tmisce.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tname.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tpriv.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: ttime.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tvariant.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: streamMsg.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: streamWindowPlan.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tmsg.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: xnode.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: tencrypt.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: streamJson.c:tDecodeSSchemaWrapperImpl Unexecuted instantiation: crypt.c:tDecodeSSchemaWrapperImpl |
1873 | | |
1874 | 0 | static FORCE_INLINE int32_t tDecodeSSchemaWrapper(SDecoder* pDecoder, SSchemaWrapper* pSW) { |
1875 | 0 | return tDecodeSSchemaWrapperImpl(pDecoder, pSW, false); |
1876 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSSchemaWrapper Unexecuted instantiation: parser.c:tDecodeSSchemaWrapper Unexecuted instantiation: parTranslater.c:tDecodeSSchemaWrapper Unexecuted instantiation: parUtil.c:tDecodeSSchemaWrapper Unexecuted instantiation: parAstParser.c:tDecodeSSchemaWrapper Unexecuted instantiation: parAuthenticator.c:tDecodeSSchemaWrapper Unexecuted instantiation: parCalcConst.c:tDecodeSSchemaWrapper Unexecuted instantiation: parInsertSql.c:tDecodeSSchemaWrapper Unexecuted instantiation: parInsertUtil.c:tDecodeSSchemaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSSchemaWrapper Unexecuted instantiation: parAstCreater.c:tDecodeSSchemaWrapper Unexecuted instantiation: parInsertSml.c:tDecodeSSchemaWrapper Unexecuted instantiation: planner.c:tDecodeSSchemaWrapper Unexecuted instantiation: planLogicCreater.c:tDecodeSSchemaWrapper Unexecuted instantiation: planOptimizer.c:tDecodeSSchemaWrapper Unexecuted instantiation: planPhysiCreater.c:tDecodeSSchemaWrapper Unexecuted instantiation: planScaleOut.c:tDecodeSSchemaWrapper Unexecuted instantiation: planSpliter.c:tDecodeSSchemaWrapper Unexecuted instantiation: planUtil.c:tDecodeSSchemaWrapper Unexecuted instantiation: planValidator.c:tDecodeSSchemaWrapper Unexecuted instantiation: catalog.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgAsync.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgCache.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgDbg.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgRemote.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgRent.c:tDecodeSSchemaWrapper Unexecuted instantiation: ctgUtil.c:tDecodeSSchemaWrapper Unexecuted instantiation: extConnector.c:tDecodeSSchemaWrapper Unexecuted instantiation: extDialect.c:tDecodeSSchemaWrapper Unexecuted instantiation: extDialectDefaults.c:tDecodeSSchemaWrapper Unexecuted instantiation: functionMgt.c:tDecodeSSchemaWrapper Unexecuted instantiation: tudf.c:tDecodeSSchemaWrapper Unexecuted instantiation: builtins.c:tDecodeSSchemaWrapper Unexecuted instantiation: builtinsimpl.c:tDecodeSSchemaWrapper Unexecuted instantiation: spillDistinctSet.c:tDecodeSSchemaWrapper Unexecuted instantiation: thistogram.c:tDecodeSSchemaWrapper Unexecuted instantiation: tpercentile.c:tDecodeSSchemaWrapper Unexecuted instantiation: tavgfunction.c:tDecodeSSchemaWrapper Unexecuted instantiation: tminmax.c:tDecodeSSchemaWrapper Unexecuted instantiation: tminmaxavx.c:tDecodeSSchemaWrapper Unexecuted instantiation: filter.c:tDecodeSSchemaWrapper Unexecuted instantiation: scalar.c:tDecodeSSchemaWrapper Unexecuted instantiation: sclfunc.c:tDecodeSSchemaWrapper Unexecuted instantiation: sclvector.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSSchemaWrapper Unexecuted instantiation: extTypeMap.c:tDecodeSSchemaWrapper Unexecuted instantiation: queryUtil.c:tDecodeSSchemaWrapper Unexecuted instantiation: querymsg.c:tDecodeSSchemaWrapper Unexecuted instantiation: trans.c:tDecodeSSchemaWrapper Unexecuted instantiation: transCli.c:tDecodeSSchemaWrapper Unexecuted instantiation: transComm.c:tDecodeSSchemaWrapper Unexecuted instantiation: transSasl.c:tDecodeSSchemaWrapper Unexecuted instantiation: transSvr.c:tDecodeSSchemaWrapper Unexecuted instantiation: transTLS.c:tDecodeSSchemaWrapper Unexecuted instantiation: thttp.c:tDecodeSSchemaWrapper Unexecuted instantiation: geomFunc.c:tDecodeSSchemaWrapper Unexecuted instantiation: tconfig.c:tDecodeSSchemaWrapper Unexecuted instantiation: tdigest.c:tDecodeSSchemaWrapper Unexecuted instantiation: tlog.c:tDecodeSSchemaWrapper Unexecuted instantiation: tmempool.c:tDecodeSSchemaWrapper Unexecuted instantiation: tpagedbuf.c:tDecodeSSchemaWrapper Unexecuted instantiation: mpDirect.c:tDecodeSSchemaWrapper Unexecuted instantiation: extCapability.c:tDecodeSSchemaWrapper Unexecuted instantiation: systable.c:tDecodeSSchemaWrapper Unexecuted instantiation: tanalytics.c:tDecodeSSchemaWrapper Unexecuted instantiation: tdatablock.c:tDecodeSSchemaWrapper Unexecuted instantiation: tdataformat.c:tDecodeSSchemaWrapper Unexecuted instantiation: tglobal.c:tDecodeSSchemaWrapper Unexecuted instantiation: tmisce.c:tDecodeSSchemaWrapper Unexecuted instantiation: tname.c:tDecodeSSchemaWrapper Unexecuted instantiation: tpriv.c:tDecodeSSchemaWrapper Unexecuted instantiation: ttime.c:tDecodeSSchemaWrapper Unexecuted instantiation: tvariant.c:tDecodeSSchemaWrapper Unexecuted instantiation: streamMsg.c:tDecodeSSchemaWrapper Unexecuted instantiation: streamWindowPlan.c:tDecodeSSchemaWrapper Unexecuted instantiation: tmsg.c:tDecodeSSchemaWrapper Unexecuted instantiation: xnode.c:tDecodeSSchemaWrapper Unexecuted instantiation: tencrypt.c:tDecodeSSchemaWrapper Unexecuted instantiation: streamJson.c:tDecodeSSchemaWrapper Unexecuted instantiation: crypt.c:tDecodeSSchemaWrapper |
1877 | | |
1878 | 0 | static FORCE_INLINE int32_t tDecodeSSchemaWrapperEx(SDecoder* pDecoder, SSchemaWrapper* pSW) { |
1879 | 0 | return tDecodeSSchemaWrapperImpl(pDecoder, pSW, true); |
1880 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parser.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parTranslater.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parUtil.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parAstParser.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parAuthenticator.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parCalcConst.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parInsertSql.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parInsertUtil.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parAstCreater.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: parInsertSml.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planner.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planLogicCreater.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planOptimizer.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planPhysiCreater.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planScaleOut.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planSpliter.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planUtil.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: planValidator.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: catalog.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgAsync.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgCache.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgDbg.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgRemote.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgRent.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ctgUtil.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: extConnector.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: extDialect.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: extDialectDefaults.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: functionMgt.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tudf.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: builtins.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: builtinsimpl.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: spillDistinctSet.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: thistogram.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tpercentile.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tavgfunction.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tminmax.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tminmaxavx.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: filter.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: scalar.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: sclfunc.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: sclvector.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: extTypeMap.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: queryUtil.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: querymsg.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: trans.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: transCli.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: transComm.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: transSasl.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: transSvr.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: transTLS.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: thttp.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: geomFunc.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tconfig.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tdigest.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tlog.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tmempool.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tpagedbuf.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: mpDirect.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: extCapability.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: systable.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tanalytics.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tdatablock.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tdataformat.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tglobal.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tmisce.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tname.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tpriv.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: ttime.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tvariant.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: streamMsg.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: streamWindowPlan.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tmsg.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: xnode.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: tencrypt.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: streamJson.c:tDecodeSSchemaWrapperEx Unexecuted instantiation: crypt.c:tDecodeSSchemaWrapperEx |
1881 | | |
1882 | | typedef struct { |
1883 | | char name[TSDB_TABLE_FNAME_LEN]; |
1884 | | int8_t igExists; |
1885 | | int8_t source; // TD_REQ_FROM_TAOX-taosX or TD_REQ_FROM_APP-taosClient |
1886 | | int8_t reserved[6]; |
1887 | | tb_uid_t suid; |
1888 | | int64_t delay1; |
1889 | | int64_t delay2; |
1890 | | int64_t watermark1; |
1891 | | int64_t watermark2; |
1892 | | int32_t ttl; |
1893 | | int32_t colVer; |
1894 | | int32_t tagVer; |
1895 | | int32_t numOfColumns; |
1896 | | int32_t numOfTags; |
1897 | | int32_t numOfFuncs; |
1898 | | int32_t commentLen; |
1899 | | int32_t ast1Len; |
1900 | | int32_t ast2Len; |
1901 | | SArray* pColumns; // array of SFieldWithOptions |
1902 | | SArray* pTags; // array of SField |
1903 | | SArray* pFuncs; |
1904 | | char* pComment; |
1905 | | char* pAst1; |
1906 | | char* pAst2; |
1907 | | int64_t deleteMark1; |
1908 | | int64_t deleteMark2; |
1909 | | int32_t sqlLen; |
1910 | | char* sql; |
1911 | | int64_t keep; |
1912 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
1913 | | int8_t virtualStb; |
1914 | | int8_t secureDelete; |
1915 | | int8_t securityLevel; |
1916 | | // VST inheritance |
1917 | | int8_t numParents; |
1918 | | char parentStbFNames[TSDB_MAX_VST_PARENTS][TSDB_TABLE_FNAME_LEN]; |
1919 | | int16_t ownColStart; |
1920 | | int16_t ownTagStart; |
1921 | | } SMCreateStbReq; |
1922 | | |
1923 | | int32_t tSerializeSMCreateStbReq(void* buf, int32_t bufLen, SMCreateStbReq* pReq); |
1924 | | int32_t tDeserializeSMCreateStbReq(void* buf, int32_t bufLen, SMCreateStbReq* pReq); |
1925 | | void tFreeSMCreateStbReq(SMCreateStbReq* pReq); |
1926 | | |
1927 | | typedef struct { |
1928 | | STableMetaRsp* pMeta; |
1929 | | } SMCreateStbRsp; |
1930 | | |
1931 | | int32_t tEncodeSMCreateStbRsp(SEncoder* pEncoder, const SMCreateStbRsp* pRsp); |
1932 | | int32_t tDecodeSMCreateStbRsp(SDecoder* pDecoder, SMCreateStbRsp* pRsp); |
1933 | | void tFreeSMCreateStbRsp(SMCreateStbRsp* pRsp); |
1934 | | |
1935 | | typedef struct { |
1936 | | char name[TSDB_TABLE_FNAME_LEN]; |
1937 | | int8_t igNotExists; |
1938 | | int8_t source; // TD_REQ_FROM_TAOX-taosX or TD_REQ_FROM_APP-taosClient |
1939 | | int8_t reserved[6]; |
1940 | | tb_uid_t suid; |
1941 | | int32_t sqlLen; |
1942 | | char* sql; |
1943 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
1944 | | } SMDropStbReq; |
1945 | | |
1946 | | int32_t tSerializeSMDropStbReq(void* buf, int32_t bufLen, SMDropStbReq* pReq); |
1947 | | int32_t tDeserializeSMDropStbReq(void* buf, int32_t bufLen, SMDropStbReq* pReq); |
1948 | | void tFreeSMDropStbReq(SMDropStbReq* pReq); |
1949 | | |
1950 | | typedef struct { |
1951 | | char name[TSDB_TABLE_FNAME_LEN]; |
1952 | | int8_t alterType; |
1953 | | int32_t numOfFields; |
1954 | | SArray* pFields; |
1955 | | int32_t ttl; |
1956 | | int32_t commentLen; |
1957 | | char* comment; |
1958 | | int32_t sqlLen; |
1959 | | char* sql; |
1960 | | int64_t keep; |
1961 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
1962 | | SArray* pTypeMods; |
1963 | | int8_t secureDelete; |
1964 | | int8_t securityLevel; |
1965 | | // VST inheritance: for ADD_BASE_ON / DROP_BASE_ON |
1966 | | int8_t numParents; |
1967 | | char parentStbFNames[TSDB_MAX_VST_PARENTS][TSDB_TABLE_FNAME_LEN]; |
1968 | | } SMAlterStbReq; |
1969 | | |
1970 | | int32_t tSerializeSMAlterStbReq(void* buf, int32_t bufLen, SMAlterStbReq* pReq); |
1971 | | int32_t tDeserializeSMAlterStbReq(void* buf, int32_t bufLen, SMAlterStbReq* pReq); |
1972 | | void tFreeSMAltertbReq(SMAlterStbReq* pReq); |
1973 | | |
1974 | | typedef struct SEpSet { |
1975 | | int8_t inUse; |
1976 | | int8_t numOfEps; |
1977 | | SEp eps[TSDB_MAX_REPLICA]; |
1978 | | } SEpSet; |
1979 | | |
1980 | | int32_t tEncodeSEpSet(SEncoder* pEncoder, const SEpSet* pEp); |
1981 | | int32_t tDecodeSEpSet(SDecoder* pDecoder, SEpSet* pEp); |
1982 | | int32_t taosEncodeSEpSet(void** buf, const SEpSet* pEp); |
1983 | | void* taosDecodeSEpSet(const void* buf, SEpSet* pEp); |
1984 | | |
1985 | | int32_t tSerializeSEpSet(void* buf, int32_t bufLen, const SEpSet* pEpset); |
1986 | | int32_t tDeserializeSEpSet(void* buf, int32_t buflen, SEpSet* pEpset); |
1987 | | |
1988 | | typedef struct { |
1989 | | int8_t connType; |
1990 | | int32_t pid; |
1991 | | int32_t totpCode; |
1992 | | char app[TSDB_APP_NAME_LEN]; |
1993 | | char db[TSDB_DB_NAME_LEN]; |
1994 | | char user[TSDB_USER_LEN]; |
1995 | | char passwd[TSDB_PASSWORD_LEN]; |
1996 | | char token[TSDB_TOKEN_LEN]; |
1997 | | int64_t startTime; |
1998 | | int64_t connectTime; |
1999 | | char sVer[TSDB_VERSION_LEN]; |
2000 | | char signature[20]; // SHA1 produces a 20-byte signature |
2001 | | char saslToken[TSDB_TOKEN_LEN]; // one-time token from a completed SASL handshake (empty for legacy auth) |
2002 | | } SConnectReq; |
2003 | | |
2004 | | int32_t tSerializeSConnectReq(void* buf, int32_t bufLen, SConnectReq* pReq); |
2005 | | int32_t tDeserializeSConnectReq(void* buf, int32_t bufLen, SConnectReq* pReq); |
2006 | | void tSignConnectReq(SConnectReq* pReq); |
2007 | | int32_t tVerifyConnectReqSignature(const SConnectReq* pReq); |
2008 | | |
2009 | | typedef struct { |
2010 | | int64_t clusterId; |
2011 | | int32_t acctId; |
2012 | | uint32_t connId; |
2013 | | int32_t dnodeNum; |
2014 | | int8_t superUser; |
2015 | | int8_t sysInfo; |
2016 | | int8_t connType; |
2017 | | int8_t enableAuditDelete; |
2018 | | SEpSet epSet; |
2019 | | int32_t svrTimestamp; |
2020 | | int32_t passVer; |
2021 | | int32_t authVer; |
2022 | | char sVer[TSDB_VERSION_LEN]; |
2023 | | char sDetailVer[128]; |
2024 | | int64_t whiteListVer; |
2025 | | int64_t timeWhiteListVer; |
2026 | | int64_t userId; |
2027 | | SMonitorParas monitorParas; |
2028 | | char user[TSDB_USER_LEN]; |
2029 | | char tokenName[TSDB_TOKEN_NAME_LEN]; |
2030 | | int8_t enableAuditSelect; |
2031 | | int8_t enableAuditInsert; |
2032 | | int8_t auditLevel; |
2033 | | union { |
2034 | | uint32_t flags; |
2035 | | struct { |
2036 | | uint32_t minSecLevel : 3; // per-user |
2037 | | uint32_t maxSecLevel : 3; // per-user |
2038 | | uint32_t sodInitial : 1; // cluster-wide: 1 = SoD still in initial phase |
2039 | | uint32_t macActive : 1; // cluster-wide: 1 = MAC mandatory mode activated |
2040 | | uint32_t reserved : 24; |
2041 | | }; |
2042 | | }; |
2043 | | } SConnectRsp; |
2044 | | |
2045 | | int32_t tSerializeSConnectRsp(void* buf, int32_t bufLen, SConnectRsp* pRsp); |
2046 | | int32_t tDeserializeSConnectRsp(void* buf, int32_t bufLen, SConnectRsp* pRsp); |
2047 | | |
2048 | | // One round of a SASL (SCRAM-SHA-256) authentication handshake. The `data` field carries the opaque |
2049 | | // SASL token produced by gsasl_step64() and is shuttled verbatim between client and server; neither |
2050 | | // side interprets it. The handshake repeats (TDMT_MND_AUTH_SASL) until the response sets done=1. |
2051 | | typedef struct { |
2052 | | char mech[TSDB_SASL_MECH_LEN]; // SASL mechanism, e.g. "SCRAM-SHA-256" |
2053 | | char user[TSDB_USER_LEN]; // login user; used to look up credentials on the first round |
2054 | | char authId[TSDB_SASL_AUTH_ID_LEN];// server-assigned handshake id; empty on the first round |
2055 | | char sVer[TSDB_VERSION_LEN]; // client version, for compatibility checks |
2056 | | int32_t dataLen; // opaque SASL payload length |
2057 | | uint8_t* data; // opaque SASL payload (gsasl_step64 output, base64 text) |
2058 | | } SSaslStepReq; |
2059 | | |
2060 | | int32_t tSerializeSSaslStepReq(void* buf, int32_t bufLen, SSaslStepReq* pReq); |
2061 | | int32_t tDeserializeSSaslStepReq(void* buf, int32_t bufLen, SSaslStepReq* pReq); |
2062 | | void tFreeSSaslStepReq(SSaslStepReq* pReq); |
2063 | | |
2064 | | typedef struct { |
2065 | | char authId[TSDB_SASL_AUTH_ID_LEN];// echo back on the next round |
2066 | | int8_t done; // 1 when the handshake has succeeded |
2067 | | int32_t dataLen; |
2068 | | uint8_t* data; // opaque SASL payload |
2069 | | char authToken[TSDB_TOKEN_LEN]; // short-lived token issued on success to drive CONNECT |
2070 | | } SSaslStepRsp; |
2071 | | |
2072 | | int32_t tSerializeSSaslStepRsp(void* buf, int32_t bufLen, SSaslStepRsp* pRsp); |
2073 | | int32_t tDeserializeSSaslStepRsp(void* buf, int32_t bufLen, SSaslStepRsp* pRsp); |
2074 | | void tFreeSSaslStepRsp(SSaslStepRsp* pRsp); |
2075 | | |
2076 | | typedef struct { |
2077 | | char user[TSDB_USER_LEN]; |
2078 | | char pass[TSDB_PASSWORD_LEN]; |
2079 | | int32_t maxUsers; |
2080 | | int32_t maxDbs; |
2081 | | int32_t maxTimeSeries; |
2082 | | int32_t maxStreams; |
2083 | | int32_t accessState; // Configured only by command |
2084 | | int64_t maxStorage; |
2085 | | } SCreateAcctReq, SAlterAcctReq; |
2086 | | |
2087 | | // int32_t tSerializeSCreateAcctReq(void* buf, int32_t bufLen, SCreateAcctReq* pReq); |
2088 | | // int32_t tDeserializeSCreateAcctReq(void* buf, int32_t bufLen, SCreateAcctReq* pReq); |
2089 | | |
2090 | | typedef struct { |
2091 | | char user[TSDB_USER_LEN]; |
2092 | | int8_t ignoreNotExists; |
2093 | | int32_t sqlLen; |
2094 | | char* sql; |
2095 | | } SDropUserReq, SDropAcctReq; |
2096 | | |
2097 | | int32_t tSerializeSDropUserReq(void* buf, int32_t bufLen, SDropUserReq* pReq); |
2098 | | int32_t tDeserializeSDropUserReq(void* buf, int32_t bufLen, SDropUserReq* pReq); |
2099 | | void tFreeSDropUserReq(SDropUserReq* pReq); |
2100 | | |
2101 | | typedef struct { |
2102 | | char name[TSDB_ROLE_LEN]; |
2103 | | union { |
2104 | | uint8_t flag; |
2105 | | struct { |
2106 | | uint8_t ignoreExists : 1; |
2107 | | uint8_t reserve : 7; |
2108 | | }; |
2109 | | }; |
2110 | | int32_t sqlLen; |
2111 | | char* sql; |
2112 | | } SCreateRoleReq; |
2113 | | |
2114 | | int32_t tSerializeSCreateRoleReq(void* buf, int32_t bufLen, SCreateRoleReq* pReq); |
2115 | | int32_t tDeserializeSCreateRoleReq(void* buf, int32_t bufLen, SCreateRoleReq* pReq); |
2116 | | void tFreeSCreateRoleReq(SCreateRoleReq* pReq); |
2117 | | |
2118 | | typedef struct { |
2119 | | char name[TSDB_ROLE_LEN]; |
2120 | | union { |
2121 | | uint8_t flag; |
2122 | | struct { |
2123 | | uint8_t ignoreNotExists : 1; |
2124 | | uint8_t reserve : 7; |
2125 | | }; |
2126 | | }; |
2127 | | int32_t sqlLen; |
2128 | | char* sql; |
2129 | | } SDropRoleReq; |
2130 | | |
2131 | | int32_t tSerializeSDropRoleReq(void* buf, int32_t bufLen, SDropRoleReq* pReq); |
2132 | | int32_t tDeserializeSDropRoleReq(void* buf, int32_t bufLen, SDropRoleReq* pReq); |
2133 | | void tFreeSDropRoleReq(SDropRoleReq* pReq); |
2134 | | |
2135 | | typedef struct { |
2136 | | SPrivSet privSet; |
2137 | | SArray* selectCols; // SColIdNameKV, for table privileges |
2138 | | SArray* insertCols; // SColIdNameKV, for table privileges |
2139 | | SArray* updateCols; // SColIdNameKV, for table privileges |
2140 | | // delete can only specify conditions by cond and cannot specify columns |
2141 | | char* cond; // for table privileges |
2142 | | int32_t condLen; // for table privileges |
2143 | | } SPrivSetReqArgs; |
2144 | | |
2145 | | typedef struct { |
2146 | | uint8_t alterType; // TSDB_ALTER_ROLE_LOCK, TSDB_ALTER_ROLE_ROLE, TSDB_ALTER_ROLE_PRIVILEGES |
2147 | | uint8_t objType; // none, db, table, view, rsma, topic, etc. |
2148 | | union { |
2149 | | uint32_t flag; |
2150 | | struct { |
2151 | | uint32_t lock : 1; // lock or unlock role |
2152 | | uint32_t add : 1; // add or remove |
2153 | | uint32_t sysPriv : 1; // system or object privileges |
2154 | | uint32_t objLevel : 2; |
2155 | | uint32_t ignoreNotExists : 1; |
2156 | | uint32_t reserve : 26; |
2157 | | }; |
2158 | | }; |
2159 | | union { |
2160 | | SPrivSetReqArgs privileges; |
2161 | | char roleName[TSDB_ROLE_LEN]; |
2162 | | }; |
2163 | | char principal[TSDB_ROLE_LEN]; // role or user name |
2164 | | char objFName[TSDB_OBJ_FNAME_LEN]; // db |
2165 | | char tblName[TSDB_TABLE_NAME_LEN]; // none, table, view, rsma, topic, etc. |
2166 | | int32_t sqlLen; |
2167 | | char* sql; |
2168 | | } SAlterRoleReq; |
2169 | | |
2170 | | int32_t tSerializeSAlterRoleReq(void* buf, int32_t bufLen, SAlterRoleReq* pReq); |
2171 | | int32_t tDeserializeSAlterRoleReq(void* buf, int32_t bufLen, SAlterRoleReq* pReq); |
2172 | | void tFreeSAlterRoleReq(SAlterRoleReq* pReq); |
2173 | | |
2174 | | typedef struct { |
2175 | | char algorithmId[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2176 | | int32_t sqlLen; |
2177 | | char* sql; |
2178 | | } SDropEncryptAlgrReq; |
2179 | | |
2180 | | int32_t tSerializeSDropEncryptAlgrReq(void* buf, int32_t bufLen, SDropEncryptAlgrReq* pReq); |
2181 | | int32_t tDeserializeSDropEncryptAlgrReq(void* buf, int32_t bufLen, SDropEncryptAlgrReq* pReq); |
2182 | | void tFreeSDropEncryptAlgrReq(SDropEncryptAlgrReq* pReq); |
2183 | | |
2184 | | typedef struct SIpV4Range { |
2185 | | uint32_t ip; |
2186 | | uint32_t mask; |
2187 | | } SIpV4Range; |
2188 | | |
2189 | | typedef struct SIpv6Range { |
2190 | | uint64_t addr[2]; |
2191 | | uint32_t mask; |
2192 | | } SIpV6Range; |
2193 | | |
2194 | | typedef struct { |
2195 | | int8_t type; // 0: IPv4, 1: IPv6 |
2196 | | int8_t neg; // only used in SIpWhiteListDual, if neg is 1, means this is a blacklist entry |
2197 | | union { |
2198 | | SIpV4Range ipV4; |
2199 | | SIpV6Range ipV6; |
2200 | | }; |
2201 | | } SIpRange; |
2202 | | |
2203 | | typedef struct { |
2204 | | int32_t num; |
2205 | | SIpV4Range pIpRange[]; |
2206 | | } SIpWhiteList; |
2207 | | |
2208 | | typedef struct { |
2209 | | int32_t num; |
2210 | | SIpRange pIpRanges[]; |
2211 | | } SIpWhiteListDual; |
2212 | | |
2213 | | SIpWhiteListDual* cloneIpWhiteList(const SIpWhiteListDual* src); |
2214 | | int32_t cvtIpWhiteListToDual(SIpWhiteList* pWhiteList, SIpWhiteListDual** pWhiteListDual); |
2215 | | int32_t cvtIpWhiteListDualToV4(SIpWhiteListDual* pWhiteListDual, SIpWhiteList** pWhiteList); |
2216 | | int32_t createDefaultIp6Range(SIpRange* pRange); |
2217 | | int32_t createDefaultIp4Range(SIpRange* pRange); |
2218 | | |
2219 | | typedef struct { |
2220 | | int32_t sessPerUser; |
2221 | | int32_t sessConnTime; |
2222 | | int32_t sessConnIdleTime; |
2223 | | int32_t sessMaxConcurrency; |
2224 | | int32_t sessMaxCallVnodeNum; |
2225 | | } SUserSessCfg; |
2226 | | |
2227 | | void initUserDefautSessCfg(SUserSessCfg* pCfg); |
2228 | | // copyIpRange ensures that unused bytes are always zeroed, so that [pDst] can be used as a key in hash tables |
2229 | | void copyIpRange(SIpRange* pDst, const SIpRange* pSrc); |
2230 | | |
2231 | | // SDateTimeRange is used in client side during SQL statement parsing, client sends this structure |
2232 | | // to server, and server will convert it to SDateTimeWhiteListItem for internal usage. |
2233 | | typedef struct { |
2234 | | int16_t year; |
2235 | | int8_t month; // 1-12, when month is -1, it means day is week day and year is not used. |
2236 | | int8_t day; // 1-31 or 0-6 (0 means Sunday), depends on the month value. |
2237 | | int8_t hour; |
2238 | | int8_t minute; |
2239 | | int8_t neg; // this is a negative entry |
2240 | | int32_t duration; // duration in minute |
2241 | | } SDateTimeRange; |
2242 | | |
2243 | | bool isValidDateTimeRange(SDateTimeRange* pRange); |
2244 | | int32_t tEncodeSDateTimeRange(SEncoder* pEncoder, const SDateTimeRange* pRange); |
2245 | | int32_t tDecodeSDateTimeRange(SDecoder* pDecoder, SDateTimeRange* pRange); |
2246 | | |
2247 | | // SDateTimeWhiteListItem is used by server internally to represent datetime ranges. |
2248 | | typedef struct { |
2249 | | bool absolute; // true: absolute datetime range; false: weekly recurring datetime range |
2250 | | bool neg; // this is a negative entry |
2251 | | int32_t duration; // duration in seconds |
2252 | | int64_t start; // absolute timestamp in seconds or weekly offset in seconds |
2253 | | } SDateTimeWhiteListItem; |
2254 | | |
2255 | | void DateTimeRangeToWhiteListItem(SDateTimeWhiteListItem* dst, const SDateTimeRange* src); |
2256 | | bool isDateTimeWhiteListItemExpired(const SDateTimeWhiteListItem* item); |
2257 | | |
2258 | | typedef struct { |
2259 | | int32_t num; |
2260 | | SDateTimeWhiteListItem ranges[]; |
2261 | | } SDateTimeWhiteList; |
2262 | | |
2263 | | SDateTimeWhiteList* cloneDateTimeWhiteList(const SDateTimeWhiteList* src); |
2264 | | bool isTimeInDateTimeWhiteList(const SDateTimeWhiteList *wl, int64_t tm); |
2265 | | |
2266 | | |
2267 | | // SCRAM-SHA-256 credentials. When algo==TSDB_SCRAM_ALGO_SHA256, the client has |
2268 | | // pre-derived the credentials locally and the server stores them directly - the |
2269 | | // password hash is never sent over the wire. |
2270 | | typedef struct { |
2271 | | int8_t algo; // TSDB_SCRAM_ALGO_* |
2272 | | int32_t iter; // PBKDF2 iteration count |
2273 | | int32_t saltLen; // length of salt actually used |
2274 | | uint8_t salt[TSDB_SCRAM_SALT_LEN]; |
2275 | | uint8_t storedKey[TSDB_SCRAM_KEY_LEN]; |
2276 | | uint8_t serverKey[TSDB_SCRAM_KEY_LEN]; |
2277 | | } SScramCred; |
2278 | | |
2279 | | void tDeriveScramCred(const char *passHash, SScramCred *pScram); |
2280 | | |
2281 | | typedef struct { |
2282 | | int8_t createType; |
2283 | | |
2284 | | int8_t hasSessionPerUser; |
2285 | | int8_t hasConnectTime; |
2286 | | int8_t hasConnectIdleTime; |
2287 | | int8_t hasCallPerSession; |
2288 | | int8_t hasVnodePerCall; |
2289 | | int8_t hasFailedLoginAttempts; |
2290 | | int8_t hasPasswordLifeTime; |
2291 | | int8_t hasPasswordReuseTime; |
2292 | | int8_t hasPasswordReuseMax; |
2293 | | int8_t hasPasswordLockTime; |
2294 | | int8_t hasPasswordGraceTime; |
2295 | | int8_t hasInactiveAccountTime; |
2296 | | int8_t hasAllowTokenNum; |
2297 | | int8_t hasSecurityLevel; |
2298 | | |
2299 | | int8_t superUser; // denote if it is a super user or not |
2300 | | int8_t ignoreExists; |
2301 | | |
2302 | | char user[TSDB_USER_LEN]; |
2303 | | char pass[TSDB_PASSWORD_LEN]; |
2304 | | int8_t isComplexPass; |
2305 | | int8_t isSimplePass; |
2306 | | int8_t isDefaultPass; |
2307 | | int16_t passLen; |
2308 | | char totpseed[TSDB_USER_TOTPSEED_MAX_LEN + 1]; |
2309 | | |
2310 | | int8_t sysInfo; |
2311 | | int8_t createDb; |
2312 | | int8_t isImport; |
2313 | | int8_t changepass; |
2314 | | int8_t enable; |
2315 | | int8_t minSecLevel; |
2316 | | int8_t maxSecLevel; |
2317 | | |
2318 | | int8_t negIpRanges; |
2319 | | int8_t negTimeRanges; |
2320 | | |
2321 | | int32_t sessionPerUser; |
2322 | | int32_t connectTime; |
2323 | | int32_t connectIdleTime; |
2324 | | int32_t callPerSession; |
2325 | | int32_t vnodePerCall; |
2326 | | int32_t failedLoginAttempts; |
2327 | | int32_t passwordLifeTime; |
2328 | | int32_t passwordReuseTime; |
2329 | | int32_t passwordReuseMax; |
2330 | | int32_t passwordLockTime; |
2331 | | int32_t passwordGraceTime; |
2332 | | int32_t inactiveAccountTime; |
2333 | | int32_t allowTokenNum; |
2334 | | |
2335 | | int32_t numIpRanges; |
2336 | | SIpRange* pIpDualRanges; |
2337 | | int32_t numTimeRanges; |
2338 | | SDateTimeRange* pTimeRanges; |
2339 | | |
2340 | | int32_t sqlLen; |
2341 | | char* sql; |
2342 | | SScramCred scram; |
2343 | | } SCreateUserReq; |
2344 | | |
2345 | | int32_t tSerializeSCreateUserReq(void* buf, int32_t bufLen, SCreateUserReq* pReq); |
2346 | | int32_t tDeserializeSCreateUserReq(void* buf, int32_t bufLen, SCreateUserReq* pReq); |
2347 | | void tFreeSCreateUserReq(SCreateUserReq* pReq); |
2348 | | |
2349 | | typedef struct { |
2350 | | char algorithmId[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2351 | | char name[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2352 | | char desc[TSDB_ENCRYPT_ALGR_DESC_LEN]; |
2353 | | char type[TSDB_ENCRYPT_ALGR_TYPE_LEN]; |
2354 | | char osslAlgrName[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2355 | | int32_t sqlLen; |
2356 | | char* sql; |
2357 | | } SCreateEncryptAlgrReq; |
2358 | | |
2359 | | int32_t tSerializeSCreateEncryptAlgrReq(void* buf, int32_t bufLen, SCreateEncryptAlgrReq* pReq); |
2360 | | int32_t tDeserializeSCreateEncryptAlgrReq(void* buf, int32_t bufLen, SCreateEncryptAlgrReq* pReq); |
2361 | | void tFreeSCreateEncryptAlgrReq(SCreateEncryptAlgrReq* pReq); |
2362 | | |
2363 | | typedef struct { |
2364 | | int32_t dnodeId; |
2365 | | int64_t analVer; |
2366 | | } SRetrieveAnalyticsAlgoReq; |
2367 | | |
2368 | | typedef struct { |
2369 | | int64_t ver; |
2370 | | SHashObj* hash; // algoname:algotype -> SAnalUrl |
2371 | | } SRetrieveAnalyticAlgoRsp; |
2372 | | |
2373 | | int32_t tSerializeRetrieveAnalyticAlgoReq(void* buf, int32_t bufLen, SRetrieveAnalyticsAlgoReq* pReq); |
2374 | | int32_t tDeserializeRetrieveAnalyticAlgoReq(void* buf, int32_t bufLen, SRetrieveAnalyticsAlgoReq* pReq); |
2375 | | int32_t tSerializeRetrieveAnalyticAlgoRsp(void* buf, int32_t bufLen, SRetrieveAnalyticAlgoRsp* pRsp); |
2376 | | int32_t tDeserializeRetrieveAnalyticAlgoRsp(void* buf, int32_t bufLen, SRetrieveAnalyticAlgoRsp* pRsp); |
2377 | | void tFreeRetrieveAnalyticAlgoRsp(SRetrieveAnalyticAlgoRsp* pRsp); |
2378 | | |
2379 | | typedef struct { |
2380 | | int8_t alterType; |
2381 | | |
2382 | | int8_t isView; |
2383 | | |
2384 | | int8_t hasPassword; |
2385 | | int8_t hasTotpseed; |
2386 | | int8_t hasEnable; |
2387 | | int8_t hasSysinfo; |
2388 | | int8_t hasCreatedb; |
2389 | | int8_t hasChangepass; |
2390 | | int8_t hasSessionPerUser; |
2391 | | int8_t hasConnectTime; |
2392 | | int8_t hasConnectIdleTime; |
2393 | | int8_t hasCallPerSession; |
2394 | | int8_t hasVnodePerCall; |
2395 | | int8_t hasFailedLoginAttempts; |
2396 | | int8_t hasPasswordLifeTime; |
2397 | | int8_t hasPasswordReuseTime; |
2398 | | int8_t hasPasswordReuseMax; |
2399 | | int8_t hasPasswordLockTime; |
2400 | | int8_t hasPasswordGraceTime; |
2401 | | int8_t hasInactiveAccountTime; |
2402 | | int8_t hasAllowTokenNum; |
2403 | | int8_t hasSecurityLevel; |
2404 | | |
2405 | | int8_t enable; |
2406 | | int8_t sysinfo; |
2407 | | int8_t createdb; |
2408 | | int8_t changepass; |
2409 | | int8_t minSecLevel; |
2410 | | int8_t maxSecLevel; |
2411 | | |
2412 | | char user[TSDB_USER_LEN]; |
2413 | | char pass[TSDB_PASSWORD_LEN]; |
2414 | | int8_t isComplexPass; |
2415 | | int8_t isSimplePass; |
2416 | | int8_t isDefaultPass; |
2417 | | int16_t passLen; |
2418 | | char totpseed[TSDB_USER_TOTPSEED_MAX_LEN + 1]; |
2419 | | int32_t sessionPerUser; |
2420 | | int32_t connectTime; |
2421 | | int32_t connectIdleTime; |
2422 | | int32_t callPerSession; |
2423 | | int32_t vnodePerCall; |
2424 | | int32_t failedLoginAttempts; |
2425 | | int32_t passwordLifeTime; |
2426 | | int32_t passwordReuseTime; |
2427 | | int32_t passwordReuseMax; |
2428 | | int32_t passwordLockTime; |
2429 | | int32_t passwordGraceTime; |
2430 | | int32_t inactiveAccountTime; |
2431 | | int32_t allowTokenNum; |
2432 | | |
2433 | | int32_t numIpRanges; |
2434 | | int32_t numTimeRanges; |
2435 | | int32_t numDropIpRanges; |
2436 | | int32_t numDropTimeRanges; |
2437 | | SIpRange* pIpRanges; |
2438 | | SDateTimeRange* pTimeRanges; |
2439 | | SIpRange* pDropIpRanges; |
2440 | | SDateTimeRange* pDropTimeRanges; |
2441 | | SPrivSet privileges; |
2442 | | |
2443 | | char objname[TSDB_OBJ_FNAME_LEN]; // db or topic |
2444 | | char tabName[TSDB_TABLE_NAME_LEN]; |
2445 | | char* tagCond; |
2446 | | int32_t tagCondLen; |
2447 | | int32_t sqlLen; |
2448 | | char* sql; |
2449 | | SScramCred scram; |
2450 | | } SAlterUserReq; |
2451 | | |
2452 | | int32_t tSerializeSAlterUserReq(void* buf, int32_t bufLen, SAlterUserReq* pReq); |
2453 | | int32_t tDeserializeSAlterUserReq(void* buf, int32_t bufLen, SAlterUserReq* pReq); |
2454 | | void tFreeSAlterUserReq(SAlterUserReq* pReq); |
2455 | | |
2456 | | typedef struct { |
2457 | | char name[TSDB_TOKEN_NAME_LEN]; |
2458 | | char user[TSDB_USER_LEN]; |
2459 | | int8_t enable; |
2460 | | int8_t ignoreExists; |
2461 | | int32_t ttl; |
2462 | | char provider[TSDB_TOKEN_PROVIDER_LEN]; |
2463 | | char extraInfo[TSDB_TOKEN_EXTRA_INFO_LEN]; |
2464 | | |
2465 | | int32_t sqlLen; |
2466 | | char* sql; |
2467 | | } SCreateTokenReq; |
2468 | | |
2469 | | int32_t tSerializeSCreateTokenReq(void* buf, int32_t bufLen, SCreateTokenReq* pReq); |
2470 | | int32_t tDeserializeSCreateTokenReq(void* buf, int32_t bufLen, SCreateTokenReq* pReq); |
2471 | | void tFreeSCreateTokenReq(SCreateTokenReq* pReq); |
2472 | | |
2473 | | typedef struct { |
2474 | | char name[TSDB_TOKEN_NAME_LEN]; |
2475 | | char user[TSDB_USER_LEN]; |
2476 | | char token[TSDB_TOKEN_LEN]; |
2477 | | } SCreateTokenRsp; |
2478 | | |
2479 | | int32_t tSerializeSCreateTokenResp(void* buf, int32_t bufLen, SCreateTokenRsp* pRsp); |
2480 | | int32_t tDeserializeSCreateTokenResp(void* buf, int32_t bufLen, SCreateTokenRsp* pRsp); |
2481 | | void tFreeSCreateTokenResp(SCreateTokenRsp* pRsp); |
2482 | | |
2483 | | typedef struct { |
2484 | | char name[TSDB_TOKEN_NAME_LEN]; |
2485 | | |
2486 | | int8_t hasEnable; |
2487 | | int8_t hasTtl; |
2488 | | int8_t hasProvider; |
2489 | | int8_t hasExtraInfo; |
2490 | | |
2491 | | int8_t enable; |
2492 | | int32_t ttl; |
2493 | | char provider[TSDB_TOKEN_PROVIDER_LEN]; |
2494 | | char extraInfo[TSDB_TOKEN_EXTRA_INFO_LEN]; |
2495 | | |
2496 | | int32_t sqlLen; |
2497 | | char* sql; |
2498 | | } SAlterTokenReq; |
2499 | | |
2500 | | int32_t tSerializeSAlterTokenReq(void* buf, int32_t bufLen, SAlterTokenReq* pReq); |
2501 | | int32_t tDeserializeSAlterTokenReq(void* buf, int32_t bufLen, SAlterTokenReq* pReq); |
2502 | | void tFreeSAlterTokenReq(SAlterTokenReq* pReq); |
2503 | | |
2504 | | typedef struct { |
2505 | | char name[TSDB_TOKEN_NAME_LEN]; |
2506 | | int8_t ignoreNotExists; |
2507 | | int32_t sqlLen; |
2508 | | char* sql; |
2509 | | } SDropTokenReq; |
2510 | | |
2511 | | int32_t tSerializeSDropTokenReq(void* buf, int32_t bufLen, SDropTokenReq* pReq); |
2512 | | int32_t tDeserializeSDropTokenReq(void* buf, int32_t bufLen, SDropTokenReq* pReq); |
2513 | | void tFreeSDropTokenReq(SDropTokenReq* pReq); |
2514 | | |
2515 | | typedef struct { |
2516 | | char user[TSDB_USER_LEN]; |
2517 | | int32_t sqlLen; |
2518 | | char* sql; |
2519 | | } SCreateTotpSecretReq; |
2520 | | |
2521 | | int32_t tSerializeSCreateTotpSecretReq(void* buf, int32_t bufLen, SCreateTotpSecretReq* pReq); |
2522 | | int32_t tDeserializeSCreateTotpSecretReq(void* buf, int32_t bufLen, SCreateTotpSecretReq* pReq); |
2523 | | void tFreeSCreateTotpSecretReq(SCreateTotpSecretReq* pReq); |
2524 | | |
2525 | | typedef struct { |
2526 | | char user[TSDB_USER_LEN]; |
2527 | | char totpSecret[(TSDB_TOTP_SECRET_LEN * 8 + 4) / 5 + 1]; // base32 encoded totp secret + null terminator |
2528 | | } SCreateTotpSecretRsp; |
2529 | | |
2530 | | int32_t tSerializeSCreateTotpSecretRsp(void* buf, int32_t bufLen, SCreateTotpSecretRsp* pRsp); |
2531 | | int32_t tDeserializeSCreateTotpSecretRsp(void* buf, int32_t bufLen, SCreateTotpSecretRsp* pRsp); |
2532 | | |
2533 | | typedef SCreateTotpSecretReq SDropTotpSecretReq; |
2534 | 0 | #define tSerializeSDropTotpSecretReq tSerializeSCreateTotpSecretReq |
2535 | | #define tDeserializeSDropTotpSecretReq tDeserializeSCreateTotpSecretReq |
2536 | 0 | #define tFreeSDropTotpSecretReq tFreeSCreateTotpSecretReq |
2537 | | |
2538 | | typedef struct { |
2539 | | char user[TSDB_USER_LEN]; |
2540 | | } SGetUserAuthReq; |
2541 | | |
2542 | | int32_t tSerializeSGetUserAuthReq(void* buf, int32_t bufLen, SGetUserAuthReq* pReq); |
2543 | | int32_t tDeserializeSGetUserAuthReq(void* buf, int32_t bufLen, SGetUserAuthReq* pReq); |
2544 | | |
2545 | | typedef struct { |
2546 | | int8_t enabled; |
2547 | | int32_t expireTime; |
2548 | | } STokenStatus; |
2549 | | |
2550 | | typedef struct { |
2551 | | char user[TSDB_USER_LEN]; |
2552 | | int64_t userId; |
2553 | | int32_t version; |
2554 | | int32_t passVer; |
2555 | | int8_t superAuth; |
2556 | | int8_t sysInfo; |
2557 | | int8_t enable; |
2558 | | int8_t dropped; |
2559 | | union { |
2560 | | uint8_t flags; |
2561 | | struct { |
2562 | | uint8_t minSecLevel : 3; |
2563 | | uint8_t withInsertCond : 1; |
2564 | | uint8_t maxSecLevel : 3; |
2565 | | uint8_t reserved : 1; |
2566 | | }; |
2567 | | }; |
2568 | | SPrivSet sysPrivs; |
2569 | | SHashObj* objPrivs; |
2570 | | SHashObj* selectTbs; |
2571 | | SHashObj* insertTbs; |
2572 | | SHashObj* deleteTbs; |
2573 | | SHashObj* ownedDbs; |
2574 | | int64_t whiteListVer; |
2575 | | |
2576 | | SUserSessCfg sessCfg; |
2577 | | int64_t timeWhiteListVer; |
2578 | | SHashObj* tokens; |
2579 | | } SGetUserAuthRsp; |
2580 | | |
2581 | | int32_t tSerializeSGetUserAuthRsp(void* buf, int32_t bufLen, SGetUserAuthRsp* pRsp); |
2582 | | int32_t tDeserializeSGetUserAuthRsp(void* buf, int32_t bufLen, SGetUserAuthRsp* pRsp); |
2583 | | void tFreeSGetUserAuthRsp(SGetUserAuthRsp* pRsp); |
2584 | | |
2585 | | int32_t tSerializePrivSysObjPolicies(SEncoder* pEncoder, SPrivSet* sysPriv, SHashObj* pHash); |
2586 | | int32_t tDeserializePrivSysObjPolicies(SDecoder* pDecoder, SPrivSet* sysPriv, SHashObj** pHash); |
2587 | | int32_t tSerializePrivTblPolicies(SEncoder* pEncoder, SHashObj* pHash); |
2588 | | int32_t tDeserializePrivTblPolicies(SDecoder* pDecoder, SHashObj** pHash); |
2589 | | |
2590 | | int32_t tSerializeIpRange(SEncoder* encoder, SIpRange* pRange); |
2591 | | int32_t tDeserializeIpRange(SDecoder* decoder, SIpRange* pRange, bool supportNeg); |
2592 | | typedef struct { |
2593 | | int64_t ver; |
2594 | | char user[TSDB_USER_LEN]; |
2595 | | int32_t numOfRange; |
2596 | | union { |
2597 | | SIpV4Range* pIpRanges; |
2598 | | SIpRange* pIpDualRanges; |
2599 | | }; |
2600 | | } SUpdateUserIpWhite; |
2601 | | |
2602 | | typedef struct { |
2603 | | int64_t ver; |
2604 | | int numOfUser; |
2605 | | SUpdateUserIpWhite* pUserIpWhite; |
2606 | | } SUpdateIpWhite; |
2607 | | |
2608 | | int32_t tSerializeSUpdateIpWhite(void* buf, int32_t bufLen, SUpdateIpWhite* pReq); |
2609 | | int32_t tDeserializeSUpdateIpWhite(void* buf, int32_t bufLen, SUpdateIpWhite* pReq); |
2610 | | void tFreeSUpdateIpWhiteReq(SUpdateIpWhite* pReq); |
2611 | | int32_t cloneSUpdateIpWhiteReq(SUpdateIpWhite* pReq, SUpdateIpWhite** pUpdate); |
2612 | | |
2613 | | int32_t tSerializeSUpdateIpWhiteDual(void* buf, int32_t bufLen, SUpdateIpWhite* pReq); |
2614 | | int32_t tDeserializeSUpdateIpWhiteDual(void* buf, int32_t bufLen, SUpdateIpWhite* pReq); |
2615 | | void tFreeSUpdateIpWhiteDualReq(SUpdateIpWhite* pReq); |
2616 | | |
2617 | | |
2618 | | // SRetrieveWhiteListReq is used to retrieve both ip and datetime whitelist, but the |
2619 | | // corresponding response struct is different. |
2620 | | typedef struct { |
2621 | | int64_t ver; |
2622 | | } SRetrieveWhiteListReq; |
2623 | | |
2624 | | int32_t tSerializeRetrieveWhiteListReq(void* buf, int32_t bufLen, SRetrieveWhiteListReq* pReq); |
2625 | | int32_t tDeserializeRetrieveWhiteListReq(void* buf, int32_t bufLen, SRetrieveWhiteListReq* pReq); |
2626 | | |
2627 | | |
2628 | | // SGetUserWhiteListReq is used to get both ip and datetime whitelist, but the |
2629 | | // corresponding response struct is different. |
2630 | | typedef struct { |
2631 | | char user[TSDB_USER_LEN]; |
2632 | | } SGetUserWhiteListReq; |
2633 | | |
2634 | | int32_t tSerializeSGetUserWhiteListReq(void* buf, int32_t bufLen, SGetUserWhiteListReq* pReq); |
2635 | | int32_t tDeserializeSGetUserWhiteListReq(void* buf, int32_t bufLen, SGetUserWhiteListReq* pReq); |
2636 | | |
2637 | | typedef struct { |
2638 | | char user[TSDB_USER_LEN]; |
2639 | | int32_t numWhiteLists; |
2640 | | union { |
2641 | | SIpV4Range* pWhiteLists; |
2642 | | SIpRange* pWhiteListsDual; |
2643 | | }; |
2644 | | } SGetUserIpWhiteListRsp; |
2645 | | |
2646 | | int32_t tIpStrToUint(const SIpAddr* addr, SIpRange* range); |
2647 | | int32_t tIpUintToStr(const SIpRange* range, SIpAddr* addr); |
2648 | | int32_t tIpRangeSetMask(SIpRange* range, int32_t mask); |
2649 | | void tIpRangeSetDefaultMask(SIpRange* range); |
2650 | | |
2651 | | int32_t tSerializeSGetUserIpWhiteListRsp(void* buf, int32_t bufLen, SGetUserIpWhiteListRsp* pRsp); |
2652 | | int32_t tDeserializeSGetUserIpWhiteListRsp(void* buf, int32_t bufLen, SGetUserIpWhiteListRsp* pRsp); |
2653 | | void tFreeSGetUserIpWhiteListRsp(SGetUserIpWhiteListRsp* pRsp); |
2654 | | |
2655 | | int32_t tSerializeSGetUserIpWhiteListDualRsp(void* buf, int32_t bufLen, SGetUserIpWhiteListRsp* pRsp); |
2656 | | int32_t tDeserializeSGetUserIpWhiteListDualRsp(void* buf, int32_t bufLen, SGetUserIpWhiteListRsp* pRsp); |
2657 | | void tFreeSGetUserIpWhiteListDualRsp(SGetUserIpWhiteListRsp* pRsp); |
2658 | | |
2659 | | typedef struct { |
2660 | | int64_t ver; |
2661 | | char user[TSDB_USER_LEN]; |
2662 | | int32_t numWhiteLists; |
2663 | | SDateTimeWhiteListItem* pWhiteLists; |
2664 | | } SUserDateTimeWhiteList; |
2665 | | |
2666 | | |
2667 | | int32_t tSerializeSUserDateTimeWhiteList(void* buf, int32_t bufLen, SUserDateTimeWhiteList* pRsp); |
2668 | | int32_t tDeserializeSUserDateTimeWhiteList(void* buf, int32_t bufLen, SUserDateTimeWhiteList* pRsp); |
2669 | | void tFreeSUserDateTimeWhiteList(SUserDateTimeWhiteList* pRsp); |
2670 | | int32_t cloneSUserDateTimeWhiteList(const SUserDateTimeWhiteList* src, SUserDateTimeWhiteList* dest); |
2671 | | |
2672 | | typedef struct { |
2673 | | int64_t ver; |
2674 | | int numOfUser; |
2675 | | SUserDateTimeWhiteList *pUsers; |
2676 | | } SRetrieveDateTimeWhiteListRsp; |
2677 | | |
2678 | | int32_t tSerializeSRetrieveDateTimeWhiteListRsp(void* buf, int32_t bufLen, SRetrieveDateTimeWhiteListRsp* pRsp); |
2679 | | int32_t tDeserializeSRetrieveDateTimeWhiteListRsp(void* buf, int32_t bufLen, SRetrieveDateTimeWhiteListRsp* pRsp); |
2680 | | void tFreeSRetrieveDateTimeWhiteListRsp(SRetrieveDateTimeWhiteListRsp* pRsp); |
2681 | | int32_t cloneDataTimeWhiteListRsp(const SRetrieveDateTimeWhiteListRsp* src, SRetrieveDateTimeWhiteListRsp** dest); |
2682 | | |
2683 | | /* |
2684 | | * for client side struct, only column id, type, bytes are necessary |
2685 | | * But for data in vnode side, we need all the following information. |
2686 | | */ |
2687 | | typedef struct { |
2688 | | union { |
2689 | | col_id_t colId; |
2690 | | int16_t slotId; |
2691 | | }; |
2692 | | |
2693 | | uint8_t precision; |
2694 | | uint8_t scale; |
2695 | | int32_t bytes; |
2696 | | int8_t type; |
2697 | | uint8_t pk; |
2698 | | bool noData; |
2699 | | } SColumnInfo; |
2700 | | |
2701 | | typedef struct STimeWindow { |
2702 | | TSKEY skey; |
2703 | | TSKEY ekey; |
2704 | | } STimeWindow; |
2705 | | |
2706 | | typedef struct SQueryHint { |
2707 | | bool batchScan; |
2708 | | } SQueryHint; |
2709 | | |
2710 | | typedef struct { |
2711 | | int32_t tsOffset; // offset value in current msg body, NOTE: ts list is compressed |
2712 | | int32_t tsLen; // total length of ts comp block |
2713 | | int32_t tsNumOfBlocks; // ts comp block numbers |
2714 | | int32_t tsOrder; // ts comp block order |
2715 | | } STsBufInfo; |
2716 | | |
2717 | | typedef struct { |
2718 | | void* timezone; |
2719 | | char intervalUnit; |
2720 | | char slidingUnit; |
2721 | | char offsetUnit; |
2722 | | int8_t precision; |
2723 | | int8_t firstDayOfWeek; |
2724 | | int64_t interval; |
2725 | | int64_t sliding; |
2726 | | int64_t offset; |
2727 | | STimeWindow timeRange; |
2728 | | } SInterval; |
2729 | | |
2730 | | typedef struct STbVerInfo { |
2731 | | char tbFName[TSDB_TABLE_FNAME_LEN]; |
2732 | | int32_t sversion; |
2733 | | int32_t tversion; |
2734 | | int32_t rversion; // virtual table's column ref's version |
2735 | | } STbVerInfo; |
2736 | | |
2737 | | typedef struct { |
2738 | | int32_t code; |
2739 | | int64_t affectedRows; |
2740 | | SArray* tbVerInfo; // STbVerInfo |
2741 | | char* extErrMsg; // federated query remote-side error string (NULL if no ext error) |
2742 | | SExtPushdownDiagnostic* extPushdownDiag; // optional structured pushdown diagnostic (NULL if absent) |
2743 | | } SQueryTableRsp; |
2744 | | |
2745 | | int32_t tSerializeSQueryTableRsp(void* buf, int32_t bufLen, SQueryTableRsp* pRsp); |
2746 | | |
2747 | | int32_t tDeserializeSQueryTableRsp(void* buf, int32_t bufLen, SQueryTableRsp* pRsp); |
2748 | | |
2749 | | typedef struct { |
2750 | | SMsgHead header; |
2751 | | char dbFName[TSDB_DB_FNAME_LEN]; |
2752 | | char tbName[TSDB_TABLE_NAME_LEN]; |
2753 | | int64_t txnId; // batch meta txn: same-txn visibility for PRE_CREATE entries |
2754 | | } STableCfgReq; |
2755 | | |
2756 | | typedef struct { |
2757 | | char tbName[TSDB_TABLE_NAME_LEN]; |
2758 | | char stbName[TSDB_TABLE_NAME_LEN]; |
2759 | | char dbFName[TSDB_DB_FNAME_LEN]; |
2760 | | int32_t numOfTags; |
2761 | | int32_t numOfColumns; |
2762 | | int8_t tableType; |
2763 | | int64_t delay1; |
2764 | | int64_t delay2; |
2765 | | int64_t watermark1; |
2766 | | int64_t watermark2; |
2767 | | int32_t ttl; |
2768 | | int32_t keep; |
2769 | | int64_t ownerId; |
2770 | | SArray* pFuncs; |
2771 | | int32_t commentLen; |
2772 | | char* pComment; |
2773 | | SSchema* pSchemas; |
2774 | | int32_t tagsLen; |
2775 | | char* pTags; |
2776 | | SSchemaExt* pSchemaExt; |
2777 | | union { |
2778 | | uint8_t flag; |
2779 | | struct { |
2780 | | uint8_t virtualStb : 1; // no compatibility problem for little-endian arch |
2781 | | uint8_t isAudit : 1; |
2782 | | uint8_t securityLevel : 3; |
2783 | | uint8_t reserve : 3; |
2784 | | }; |
2785 | | }; |
2786 | | SColRef* pColRefs; |
2787 | | int32_t numOfTagRefs; |
2788 | | SColRef* pTagRefs; |
2789 | | int32_t numOfSeries; |
2790 | | SSeriesEntry* pSeries; |
2791 | | int8_t secureDelete; |
2792 | | int8_t numParents; |
2793 | | char parentStbNames[TSDB_MAX_VST_PARENTS][TSDB_TABLE_NAME_LEN]; |
2794 | | int16_t ownColStart; // index of first own (non-inherited) column; 0 when no inheritance |
2795 | | int16_t ownTagStart; // index of first own (non-inherited) tag; 0 when no inheritance |
2796 | | } STableCfg; |
2797 | | |
2798 | | typedef STableCfg STableCfgRsp; |
2799 | | |
2800 | | int32_t tSerializeSTableCfgReq(void* buf, int32_t bufLen, STableCfgReq* pReq); |
2801 | | int32_t tDeserializeSTableCfgReq(void* buf, int32_t bufLen, STableCfgReq* pReq); |
2802 | | |
2803 | | int32_t tSerializeSTableCfgRsp(void* buf, int32_t bufLen, STableCfgRsp* pRsp); |
2804 | | int32_t tDeserializeSTableCfgRsp(void* buf, int32_t bufLen, STableCfgRsp* pRsp); |
2805 | | void tFreeSTableCfgRsp(STableCfgRsp* pRsp); |
2806 | | |
2807 | | // VST leaf descendants query |
2808 | | typedef struct { |
2809 | | char dbFName[TSDB_DB_FNAME_LEN]; |
2810 | | int64_t suid; |
2811 | | } SVstLeavesReq; |
2812 | | |
2813 | | typedef struct { |
2814 | | char dbFName[TSDB_DB_FNAME_LEN]; |
2815 | | char stbName[TSDB_TABLE_NAME_LEN]; |
2816 | | int64_t suid; |
2817 | | } SVstLeafInfo; |
2818 | | |
2819 | | typedef struct { |
2820 | | int32_t numLeaves; |
2821 | | SVstLeafInfo* pLeaves; |
2822 | | } SVstLeavesRsp; |
2823 | | |
2824 | | int32_t tSerializeSVstLeavesReq(void* buf, int32_t bufLen, SVstLeavesReq* pReq); |
2825 | | int32_t tDeserializeSVstLeavesReq(void* buf, int32_t bufLen, SVstLeavesReq* pReq); |
2826 | | int32_t tSerializeSVstLeavesRsp(void* buf, int32_t bufLen, SVstLeavesRsp* pRsp); |
2827 | | int32_t tDeserializeSVstLeavesRsp(void* buf, int32_t bufLen, SVstLeavesRsp* pRsp); |
2828 | | void tFreeSVstLeavesRsp(SVstLeavesRsp* pRsp); |
2829 | | |
2830 | | typedef struct { |
2831 | | SMsgHead header; |
2832 | | tb_uid_t suid; |
2833 | | } SVSubTablesReq; |
2834 | | |
2835 | | int32_t tSerializeSVSubTablesReq(void* buf, int32_t bufLen, SVSubTablesReq* pReq); |
2836 | | int32_t tDeserializeSVSubTablesReq(void* buf, int32_t bufLen, SVSubTablesReq* pReq); |
2837 | | |
2838 | | typedef struct { |
2839 | | int32_t vgId; |
2840 | | SArray* pTables; // SArray<SVCTableRefCols*> |
2841 | | } SVSubTablesRsp; |
2842 | | |
2843 | | int32_t tSerializeSVSubTablesRsp(void* buf, int32_t bufLen, SVSubTablesRsp* pRsp); |
2844 | | int32_t tDeserializeSVSubTablesRsp(void* buf, int32_t bufLen, SVSubTablesRsp* pRsp); |
2845 | | void tDestroySVSubTablesRsp(void* rsp); |
2846 | | |
2847 | | typedef struct { |
2848 | | SMsgHead header; |
2849 | | tb_uid_t suid; |
2850 | | } SVStbRefDbsReq; |
2851 | | |
2852 | | int32_t tSerializeSVStbRefDbsReq(void* buf, int32_t bufLen, SVStbRefDbsReq* pReq); |
2853 | | int32_t tDeserializeSVStbRefDbsReq(void* buf, int32_t bufLen, SVStbRefDbsReq* pReq); |
2854 | | |
2855 | | typedef struct { |
2856 | | int32_t vgId; |
2857 | | SArray* pDbs; // SArray<char* (db name)> |
2858 | | SArray* pExtSources; // SArray<char* (ext source name)> |
2859 | | // Resolved col-ref info synthesized in catalog for local planner/parser consumption only. |
2860 | | // Not serialized in vnode wire format. |
2861 | | int32_t numOfColRefs; |
2862 | | SRefColInfo* pColRefCols; // Array[numOfColRefs] |
2863 | | SColRef* pResolvedColRefs; // leaf refs, Array[numOfColRefs], catalog-local only |
2864 | | // Tag ref info synthesized from first child (local only, not serialized in vnode wire format) |
2865 | | int32_t numOfTagRefs; |
2866 | | SRefColInfo* pTagRefCols; // Array[numOfTagRefs] |
2867 | | } SVStbRefDbsRsp; |
2868 | | |
2869 | | int32_t tSerializeSVStbRefDbsRsp(void* buf, int32_t bufLen, SVStbRefDbsRsp* pRsp); |
2870 | | int32_t tDeserializeSVStbRefDbsRsp(void* buf, int32_t bufLen, SVStbRefDbsRsp* pRsp); |
2871 | | void tDestroySVStbRefDbsRsp(void* rsp); |
2872 | | |
2873 | | typedef struct { |
2874 | | char db[TSDB_DB_FNAME_LEN]; |
2875 | | int32_t numOfVgroups; |
2876 | | int32_t numOfStables; // single_stable |
2877 | | int32_t buffer; // MB |
2878 | | int32_t pageSize; |
2879 | | int32_t pages; |
2880 | | int32_t cacheLastSize; |
2881 | | int32_t cacheLastShardBits; // Number of shards for last cache LRU, -1 for auto |
2882 | | int32_t daysPerFile; |
2883 | | int32_t daysToKeep0; |
2884 | | int32_t daysToKeep1; |
2885 | | int32_t daysToKeep2; |
2886 | | int32_t keepTimeOffset; |
2887 | | int32_t minRows; |
2888 | | int32_t maxRows; |
2889 | | int32_t walFsyncPeriod; |
2890 | | int8_t walLevel; |
2891 | | int8_t precision; // time resolution |
2892 | | int8_t compression; |
2893 | | int8_t replications; |
2894 | | int8_t strict; |
2895 | | int8_t cacheLast; |
2896 | | int8_t schemaless; |
2897 | | int8_t ignoreExist; |
2898 | | int32_t numOfRetensions; |
2899 | | SArray* pRetensions; // SRetention |
2900 | | int32_t walRetentionPeriod; |
2901 | | int64_t walRetentionSize; |
2902 | | int32_t walRollPeriod; |
2903 | | int64_t walSegmentSize; |
2904 | | int32_t sstTrigger; |
2905 | | int16_t hashPrefix; |
2906 | | int16_t hashSuffix; |
2907 | | int32_t ssChunkSize; |
2908 | | int32_t ssKeepLocal; |
2909 | | int8_t ssCompact; |
2910 | | int32_t tsdbPageSize; |
2911 | | int32_t sqlLen; |
2912 | | char* sql; |
2913 | | int8_t withArbitrator; |
2914 | | int8_t encryptAlgorithm; |
2915 | | char dnodeListStr[TSDB_DNODE_LIST_LEN]; |
2916 | | // 1. add auto-compact parameters |
2917 | | int32_t compactInterval; // minutes |
2918 | | int32_t compactStartTime; // minutes |
2919 | | int32_t compactEndTime; // minutes |
2920 | | int8_t compactTimeOffset; // hour |
2921 | | char encryptAlgrName[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2922 | | int8_t isAudit; |
2923 | | int8_t allowDrop; |
2924 | | int8_t secureDelete; |
2925 | | int8_t securityLevel; |
2926 | | } SCreateDbReq; |
2927 | | |
2928 | | int32_t tSerializeSCreateDbReq(void* buf, int32_t bufLen, SCreateDbReq* pReq); |
2929 | | int32_t tDeserializeSCreateDbReq(void* buf, int32_t bufLen, SCreateDbReq* pReq); |
2930 | | void tFreeSCreateDbReq(SCreateDbReq* pReq); |
2931 | | |
2932 | | typedef struct { |
2933 | | char db[TSDB_DB_FNAME_LEN]; |
2934 | | int32_t buffer; |
2935 | | int32_t pageSize; |
2936 | | int32_t pages; |
2937 | | int32_t cacheLastSize; |
2938 | | int32_t cacheLastShardBits; // Number of shards for last cache LRU, -1 for auto |
2939 | | int32_t daysPerFile; |
2940 | | int32_t daysToKeep0; |
2941 | | int32_t daysToKeep1; |
2942 | | int32_t daysToKeep2; |
2943 | | int32_t keepTimeOffset; |
2944 | | int32_t walFsyncPeriod; |
2945 | | int8_t walLevel; |
2946 | | int8_t strict; |
2947 | | int8_t cacheLast; |
2948 | | int8_t replications; |
2949 | | int32_t sstTrigger; |
2950 | | int32_t minRows; |
2951 | | int32_t walRetentionPeriod; |
2952 | | int32_t walRetentionSize; |
2953 | | int32_t ssKeepLocal; |
2954 | | int8_t ssCompact; |
2955 | | int32_t sqlLen; |
2956 | | char* sql; |
2957 | | int8_t withArbitrator; |
2958 | | // 1. add auto-compact parameters |
2959 | | int32_t compactInterval; |
2960 | | int32_t compactStartTime; |
2961 | | int32_t compactEndTime; |
2962 | | int8_t compactTimeOffset; |
2963 | | char encryptAlgrName[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
2964 | | int8_t isAudit; |
2965 | | int8_t allowDrop; |
2966 | | int8_t secureDelete; |
2967 | | int8_t securityLevel; |
2968 | | int32_t parallel; // group parallel concurrency limit for replica changes, 0 = unlimited |
2969 | | int32_t maxRows; |
2970 | | } SAlterDbReq; |
2971 | | |
2972 | | int32_t tSerializeSAlterDbReq(void* buf, int32_t bufLen, SAlterDbReq* pReq); |
2973 | | int32_t tDeserializeSAlterDbReq(void* buf, int32_t bufLen, SAlterDbReq* pReq); |
2974 | | void tFreeSAlterDbReq(SAlterDbReq* pReq); |
2975 | | |
2976 | | typedef struct { |
2977 | | char db[TSDB_DB_FNAME_LEN]; |
2978 | | int8_t ignoreNotExists; |
2979 | | int8_t force; |
2980 | | int32_t sqlLen; |
2981 | | char* sql; |
2982 | | } SDropDbReq; |
2983 | | |
2984 | | int32_t tSerializeSDropDbReq(void* buf, int32_t bufLen, SDropDbReq* pReq); |
2985 | | int32_t tDeserializeSDropDbReq(void* buf, int32_t bufLen, SDropDbReq* pReq); |
2986 | | void tFreeSDropDbReq(SDropDbReq* pReq); |
2987 | | |
2988 | | typedef struct { |
2989 | | char db[TSDB_DB_FNAME_LEN]; |
2990 | | int64_t uid; |
2991 | | } SDropDbRsp; |
2992 | | |
2993 | | int32_t tSerializeSDropDbRsp(void* buf, int32_t bufLen, SDropDbRsp* pRsp); |
2994 | | int32_t tDeserializeSDropDbRsp(void* buf, int32_t bufLen, SDropDbRsp* pRsp); |
2995 | | |
2996 | | typedef struct { |
2997 | | char name[TSDB_MOUNT_NAME_LEN]; |
2998 | | int64_t uid; |
2999 | | } SDropMountRsp; |
3000 | | |
3001 | | int32_t tSerializeSDropMountRsp(void* buf, int32_t bufLen, SDropMountRsp* pRsp); |
3002 | | int32_t tDeserializeSDropMountRsp(void* buf, int32_t bufLen, SDropMountRsp* pRsp); |
3003 | | |
3004 | | typedef struct { |
3005 | | char db[TSDB_DB_FNAME_LEN]; |
3006 | | int64_t dbId; |
3007 | | int32_t vgVersion; |
3008 | | int32_t numOfTable; // unit is TSDB_TABLE_NUM_UNIT |
3009 | | int64_t stateTs; // ms |
3010 | | } SUseDbReq; |
3011 | | |
3012 | | int32_t tSerializeSUseDbReq(void* buf, int32_t bufLen, SUseDbReq* pReq); |
3013 | | int32_t tDeserializeSUseDbReq(void* buf, int32_t bufLen, SUseDbReq* pReq); |
3014 | | |
3015 | | typedef struct { |
3016 | | char db[TSDB_DB_FNAME_LEN]; |
3017 | | int64_t uid; |
3018 | | int32_t vgVersion; |
3019 | | int32_t vgNum; |
3020 | | int16_t hashPrefix; |
3021 | | int16_t hashSuffix; |
3022 | | int8_t hashMethod; |
3023 | | union { |
3024 | | uint8_t flags; |
3025 | | struct { |
3026 | | uint8_t isMount : 1; // TS-5868 |
3027 | | uint8_t padding : 7; |
3028 | | }; |
3029 | | }; |
3030 | | SArray* pVgroupInfos; // Array of SVgroupInfo |
3031 | | int32_t errCode; |
3032 | | int64_t stateTs; // ms |
3033 | | int8_t precision; |
3034 | | } SUseDbRsp; |
3035 | | |
3036 | | int32_t tSerializeSUseDbRsp(void* buf, int32_t bufLen, const SUseDbRsp* pRsp); |
3037 | | int32_t tDeserializeSUseDbRsp(void* buf, int32_t bufLen, SUseDbRsp* pRsp); |
3038 | | int32_t tSerializeSUseDbRspImp(SEncoder* pEncoder, const SUseDbRsp* pRsp); |
3039 | | int32_t tDeserializeSUseDbRspImp(SDecoder* pDecoder, SUseDbRsp* pRsp); |
3040 | | void tFreeSUsedbRsp(SUseDbRsp* pRsp); |
3041 | | |
3042 | | typedef struct { |
3043 | | char db[TSDB_DB_FNAME_LEN]; |
3044 | | } SDbCfgReq; |
3045 | | |
3046 | | int32_t tSerializeSDbCfgReq(void* buf, int32_t bufLen, SDbCfgReq* pReq); |
3047 | | int32_t tDeserializeSDbCfgReq(void* buf, int32_t bufLen, SDbCfgReq* pReq); |
3048 | | |
3049 | | typedef struct { |
3050 | | char db[TSDB_DB_FNAME_LEN]; |
3051 | | } SSsMigrateDbReq; |
3052 | | |
3053 | | int32_t tSerializeSSsMigrateDbReq(void* buf, int32_t bufLen, SSsMigrateDbReq* pReq); |
3054 | | int32_t tDeserializeSSsMigrateDbReq(void* buf, int32_t bufLen, SSsMigrateDbReq* pReq); |
3055 | | |
3056 | | typedef struct { |
3057 | | int32_t ssMigrateId; |
3058 | | bool bAccepted; |
3059 | | } SSsMigrateDbRsp; |
3060 | | |
3061 | | int32_t tSerializeSSsMigrateDbRsp(void* buf, int32_t bufLen, SSsMigrateDbRsp* pRsp); |
3062 | | int32_t tDeserializeSSsMigrateDbRsp(void* buf, int32_t bufLen, SSsMigrateDbRsp* pRsp); |
3063 | | |
3064 | | // Request and response for TDMT_VND_LIST_SSMIGRATE_FILESETS |
3065 | | typedef struct { |
3066 | | int32_t ssMigrateId; |
3067 | | } SListSsMigrateFileSetsReq; |
3068 | | |
3069 | | int32_t tSerializeSListSsMigrateFileSetsReq(void* buf, int32_t bufLen, SListSsMigrateFileSetsReq* pReq); |
3070 | | int32_t tDeserializeSListSsMigrateFileSetsReq(void* buf, int32_t bufLen, SListSsMigrateFileSetsReq* pReq); |
3071 | | |
3072 | | typedef struct { |
3073 | | int32_t ssMigrateId; |
3074 | | int32_t vgId; // vgroup id |
3075 | | SArray* pFileSets; // SArray<int32_t> |
3076 | | } SListSsMigrateFileSetsRsp; |
3077 | | |
3078 | | int32_t tSerializeSListSsMigrateFileSetsRsp(void* buf, int32_t bufLen, SListSsMigrateFileSetsRsp* pRsp); |
3079 | | int32_t tDeserializeSListSsMigrateFileSetsRsp(void* buf, int32_t bufLen, SListSsMigrateFileSetsRsp* pRsp); |
3080 | | void tFreeSListSsMigrateFileSetsRsp(SListSsMigrateFileSetsRsp* pRsp); |
3081 | | |
3082 | | // Request and response for TDMT_VND_SSMIGRATE_FILESET |
3083 | | typedef struct { |
3084 | | int32_t ssMigrateId; |
3085 | | int32_t nodeId; // node id of the leader vnode, filled by vnode |
3086 | | int32_t fid; |
3087 | | int64_t startTimeSec; |
3088 | | } SSsMigrateFileSetReq; |
3089 | | |
3090 | | int32_t tSerializeSSsMigrateFileSetReq(void* buf, int32_t bufLen, SSsMigrateFileSetReq* pReq); |
3091 | | int32_t tDeserializeSSsMigrateFileSetReq(void* buf, int32_t bufLen, SSsMigrateFileSetReq* pReq); |
3092 | | |
3093 | | typedef struct { |
3094 | | int32_t ssMigrateId; |
3095 | | int32_t nodeId; // node id of the leader vnode |
3096 | | int32_t vgId; |
3097 | | int32_t fid; |
3098 | | } SSsMigrateFileSetRsp; |
3099 | | |
3100 | | int32_t tSerializeSSsMigrateFileSetRsp(void* buf, int32_t bufLen, SSsMigrateFileSetRsp* pRsp); |
3101 | | int32_t tDeserializeSSsMigrateFileSetRsp(void* buf, int32_t bufLen, SSsMigrateFileSetRsp* pRsp); |
3102 | | |
3103 | | #define SSMIGRATE_FILESET_STATE_IN_PROGRESS 0 |
3104 | | #define SSMIGRATE_FILESET_STATE_SUCCEEDED 1 |
3105 | | #define SSMIGRATE_FILESET_STATE_COMPACT 2 |
3106 | | #define SSMIGRATE_FILESET_STATE_SKIPPED 3 |
3107 | | #define SSMIGRATE_FILESET_STATE_FAILED 4 |
3108 | | |
3109 | | // Request and response for TDMT_VND_QUERY_SSMIGRATE_PROGRESS and TDMT_VND_FOLLOWER_SSMIGRATE |
3110 | | // Note this struct is reused as both request and response in TDMT_VND_QUERY_SSMIGRATE_PROGRESS, |
3111 | | // while as a request, the 'state' field is not used. |
3112 | | // This struct is also used in TDMT_VND_FOLLOWER_SSMIGRATE as request, which don't need a response. |
3113 | | typedef struct { |
3114 | | int32_t ssMigrateId; // ss migrate id |
3115 | | int32_t nodeId; // node id of the leader vnode |
3116 | | int32_t vgId; // vgroup id |
3117 | | int32_t fid; // file set id |
3118 | | int32_t state; // SSMIGRATE_FILESET_STATE_* |
3119 | | } SSsMigrateProgress; |
3120 | | |
3121 | | int tSerializeSSsMigrateProgress(void* buf, int32_t bufLen, SSsMigrateProgress* pProgress); |
3122 | | int tDeserializeSSsMigrateProgress(void* buf, int32_t bufLen, SSsMigrateProgress* pProgress); |
3123 | | |
3124 | | // Request for TDMT_MND_KILL_SSMIGRATE |
3125 | | typedef struct { |
3126 | | int32_t ssMigrateId; |
3127 | | int32_t sqlLen; |
3128 | | char* sql; |
3129 | | } SKillSsMigrateReq; |
3130 | | |
3131 | | int32_t tSerializeSKillSsMigrateReq(void* buf, int32_t bufLen, SKillSsMigrateReq* pReq); |
3132 | | int32_t tDeserializeSKillSsMigrateReq(void* buf, int32_t bufLen, SKillSsMigrateReq* pReq); |
3133 | | void tFreeSKillSsMigrateReq(SKillSsMigrateReq* pReq); |
3134 | | |
3135 | | // Request for TDMT_VND_KILL_SSMIGRATE |
3136 | | typedef struct { |
3137 | | int32_t ssMigrateId; |
3138 | | } SVnodeKillSsMigrateReq; |
3139 | | |
3140 | | int32_t tSerializeSVnodeKillSsMigrateReq(void* buf, int32_t bufLen, SVnodeKillSsMigrateReq* pReq); |
3141 | | int32_t tDeserializeSVnodeKillSsMigrateReq(void* buf, int32_t bufLen, SVnodeKillSsMigrateReq* pReq); |
3142 | | |
3143 | | typedef struct { |
3144 | | int32_t vgId; |
3145 | | int64_t keepVersion; |
3146 | | } SMndSetVgroupKeepVersionReq; |
3147 | | |
3148 | | int32_t tSerializeSMndSetVgroupKeepVersionReq(void* buf, int32_t bufLen, SMndSetVgroupKeepVersionReq* pReq); |
3149 | | int32_t tDeserializeSMndSetVgroupKeepVersionReq(void* buf, int32_t bufLen, SMndSetVgroupKeepVersionReq* pReq); |
3150 | | |
3151 | | typedef struct { |
3152 | | int32_t timestampSec; |
3153 | | int32_t ttlDropMaxCount; |
3154 | | int32_t nUids; |
3155 | | SArray* pTbUids; |
3156 | | } SVDropTtlTableReq; |
3157 | | |
3158 | | int32_t tSerializeSVDropTtlTableReq(void* buf, int32_t bufLen, SVDropTtlTableReq* pReq); |
3159 | | int32_t tDeserializeSVDropTtlTableReq(void* buf, int32_t bufLen, SVDropTtlTableReq* pReq); |
3160 | | |
3161 | | typedef struct { |
3162 | | char db[TSDB_DB_FNAME_LEN]; |
3163 | | int64_t dbId; |
3164 | | int64_t ownerId; |
3165 | | int32_t cfgVersion; |
3166 | | int32_t numOfVgroups; |
3167 | | int32_t numOfStables; |
3168 | | int32_t buffer; |
3169 | | int32_t cacheSize; |
3170 | | int32_t cacheShardBits; |
3171 | | int32_t pageSize; |
3172 | | int32_t pages; |
3173 | | int32_t daysPerFile; |
3174 | | int32_t daysToKeep0; |
3175 | | int32_t daysToKeep1; |
3176 | | int32_t daysToKeep2; |
3177 | | int32_t keepTimeOffset; |
3178 | | int32_t minRows; |
3179 | | int32_t maxRows; |
3180 | | int32_t walFsyncPeriod; |
3181 | | int16_t hashPrefix; |
3182 | | int16_t hashSuffix; |
3183 | | int8_t hashMethod; |
3184 | | int8_t walLevel; |
3185 | | int8_t precision; |
3186 | | int8_t compression; |
3187 | | int8_t replications; |
3188 | | int8_t strict; |
3189 | | int8_t cacheLast; |
3190 | | int8_t encryptAlgr; |
3191 | | char algorithmsId[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
3192 | | int32_t ssChunkSize; |
3193 | | int32_t ssKeepLocal; |
3194 | | int8_t ssCompact; |
3195 | | union { |
3196 | | uint8_t flags; |
3197 | | struct { |
3198 | | uint8_t isMount : 1; // TS-5868 |
3199 | | uint8_t allowDrop : 1; // TS-7232 |
3200 | | uint8_t securityLevel : 3; // 6671585124 |
3201 | | uint8_t padding : 3; |
3202 | | }; |
3203 | | }; |
3204 | | int8_t compactTimeOffset; |
3205 | | int32_t compactInterval; |
3206 | | int32_t compactStartTime; |
3207 | | int32_t compactEndTime; |
3208 | | int32_t tsdbPageSize; |
3209 | | int32_t walRetentionPeriod; |
3210 | | int32_t walRollPeriod; |
3211 | | int64_t walRetentionSize; |
3212 | | int64_t walSegmentSize; |
3213 | | int32_t numOfRetensions; |
3214 | | SArray* pRetensions; |
3215 | | int8_t schemaless; |
3216 | | int16_t sstTrigger; |
3217 | | int8_t withArbitrator; |
3218 | | int8_t isAudit; |
3219 | | int8_t secureDelete; |
3220 | | } SDbCfgRsp; |
3221 | | |
3222 | | typedef SDbCfgRsp SDbCfgInfo; |
3223 | | |
3224 | | int32_t tSerializeSDbCfgRspImpl(SEncoder* encoder, const SDbCfgRsp* pRsp); |
3225 | | int32_t tSerializeSDbCfgRsp(void* buf, int32_t bufLen, const SDbCfgRsp* pRsp); |
3226 | | int32_t tDeserializeSDbCfgRsp(void* buf, int32_t bufLen, SDbCfgRsp* pRsp); |
3227 | | int32_t tDeserializeSDbCfgRspImpl(SDecoder* decoder, SDbCfgRsp* pRsp); |
3228 | | void tFreeSDbCfgRsp(SDbCfgRsp* pRsp); |
3229 | | |
3230 | | typedef struct { |
3231 | | int32_t rowNum; |
3232 | | } SQnodeListReq; |
3233 | | |
3234 | | int32_t tSerializeSQnodeListReq(void* buf, int32_t bufLen, SQnodeListReq* pReq); |
3235 | | int32_t tDeserializeSQnodeListReq(void* buf, int32_t bufLen, SQnodeListReq* pReq); |
3236 | | |
3237 | | typedef struct { |
3238 | | int32_t rowNum; |
3239 | | } SDnodeListReq; |
3240 | | |
3241 | | int32_t tSerializeSDnodeListReq(void* buf, int32_t bufLen, SDnodeListReq* pReq); |
3242 | | |
3243 | | typedef struct { |
3244 | | int32_t useless; // useless |
3245 | | } SServerVerReq; |
3246 | | |
3247 | | int32_t tSerializeSServerVerReq(void* buf, int32_t bufLen, SServerVerReq* pReq); |
3248 | | // int32_t tDeserializeSServerVerReq(void* buf, int32_t bufLen, SServerVerReq* pReq); |
3249 | | |
3250 | | typedef struct { |
3251 | | char ver[TSDB_VERSION_LEN]; |
3252 | | } SServerVerRsp; |
3253 | | |
3254 | | int32_t tSerializeSServerVerRsp(void* buf, int32_t bufLen, SServerVerRsp* pRsp); |
3255 | | int32_t tDeserializeSServerVerRsp(void* buf, int32_t bufLen, SServerVerRsp* pRsp); |
3256 | | |
3257 | | typedef struct SQueryNodeAddr { |
3258 | | int32_t nodeId; // vgId or qnodeId |
3259 | | SEpSet epSet; |
3260 | | } SQueryNodeAddr; |
3261 | | |
3262 | | typedef struct { |
3263 | | SQueryNodeAddr addr; |
3264 | | uint64_t load; |
3265 | | } SQueryNodeLoad; |
3266 | | |
3267 | | typedef struct { |
3268 | | SArray* qnodeList; // SArray<SQueryNodeLoad> |
3269 | | } SQnodeListRsp; |
3270 | | |
3271 | | int32_t tSerializeSQnodeListRsp(void* buf, int32_t bufLen, SQnodeListRsp* pRsp); |
3272 | | int32_t tDeserializeSQnodeListRsp(void* buf, int32_t bufLen, SQnodeListRsp* pRsp); |
3273 | | void tFreeSQnodeListRsp(SQnodeListRsp* pRsp); |
3274 | | |
3275 | | |
3276 | | typedef struct SDownstreamSourceNode { |
3277 | | ENodeType type; |
3278 | | SQueryNodeAddr addr; |
3279 | | uint64_t clientId; |
3280 | | uint64_t taskId; |
3281 | | uint64_t sId; |
3282 | | uint64_t srcTaskId; |
3283 | | int32_t execId; |
3284 | | int32_t fetchMsgType; |
3285 | | bool localExec; |
3286 | | uint64_t producerQueryId; // Zero means the legacy same-query producer. |
3287 | | bool allowFollowerRead; |
3288 | | } SDownstreamSourceNode; |
3289 | | |
3290 | 0 | #define DOWNSTREAM_SOURCE_LOCAL_BLOCK_FLAG (1U << 30) |
3291 | | #define DOWNSTREAM_SOURCE_FETCH_TYPE(type) ((type) & ~DOWNSTREAM_SOURCE_LOCAL_BLOCK_FLAG) |
3292 | | |
3293 | | |
3294 | | |
3295 | | typedef struct SDNodeAddr { |
3296 | | int32_t nodeId; // dnodeId |
3297 | | SEpSet epSet; |
3298 | | } SDNodeAddr; |
3299 | | |
3300 | | typedef struct { |
3301 | | SArray* dnodeList; // SArray<SDNodeAddr> |
3302 | | } SDnodeListRsp; |
3303 | | |
3304 | | int32_t tSerializeSDnodeListRsp(void* buf, int32_t bufLen, SDnodeListRsp* pRsp); |
3305 | | int32_t tDeserializeSDnodeListRsp(void* buf, int32_t bufLen, SDnodeListRsp* pRsp); |
3306 | | void tFreeSDnodeListRsp(SDnodeListRsp* pRsp); |
3307 | | |
3308 | | typedef struct { |
3309 | | SArray* pTsmas; // SArray<STableTSMAInfo*> |
3310 | | } STableTSMAInfoRsp; |
3311 | | |
3312 | | typedef struct { |
3313 | | SUseDbRsp* useDbRsp; |
3314 | | SDbCfgRsp* cfgRsp; |
3315 | | STableTSMAInfoRsp* pTsmaRsp; |
3316 | | int32_t dbTsmaVersion; |
3317 | | char db[TSDB_DB_FNAME_LEN]; |
3318 | | int64_t dbId; |
3319 | | } SDbHbRsp; |
3320 | | |
3321 | | typedef struct { |
3322 | | SArray* pArray; // Array of SDbHbRsp |
3323 | | } SDbHbBatchRsp; |
3324 | | |
3325 | | int32_t tSerializeSDbHbBatchRsp(void* buf, int32_t bufLen, SDbHbBatchRsp* pRsp); |
3326 | | int32_t tDeserializeSDbHbBatchRsp(void* buf, int32_t bufLen, SDbHbBatchRsp* pRsp); |
3327 | | void tFreeSDbHbBatchRsp(SDbHbBatchRsp* pRsp); |
3328 | | |
3329 | | typedef struct { |
3330 | | SArray* pArray; // Array of SGetUserAuthRsp |
3331 | | } SUserAuthBatchRsp; |
3332 | | |
3333 | | int32_t tSerializeSUserAuthBatchRsp(void* buf, int32_t bufLen, SUserAuthBatchRsp* pRsp); |
3334 | | int32_t tDeserializeSUserAuthBatchRsp(void* buf, int32_t bufLen, SUserAuthBatchRsp* pRsp); |
3335 | | void tFreeSUserAuthBatchRsp(SUserAuthBatchRsp* pRsp); |
3336 | | |
3337 | | typedef struct { |
3338 | | char db[TSDB_DB_FNAME_LEN]; |
3339 | | STimeWindow timeRange; |
3340 | | int32_t sqlLen; |
3341 | | char* sql; |
3342 | | SArray* vgroupIds; |
3343 | | int32_t compactId; |
3344 | | int8_t metaOnly; |
3345 | | int8_t force; |
3346 | | } SCompactDbReq; |
3347 | | |
3348 | | int32_t tSerializeSCompactDbReq(void* buf, int32_t bufLen, SCompactDbReq* pReq); |
3349 | | int32_t tDeserializeSCompactDbReq(void* buf, int32_t bufLen, SCompactDbReq* pReq); |
3350 | | void tFreeSCompactDbReq(SCompactDbReq* pReq); |
3351 | | |
3352 | | typedef struct { |
3353 | | union { |
3354 | | int32_t compactId; |
3355 | | int32_t id; |
3356 | | }; |
3357 | | int8_t bAccepted; |
3358 | | } SCompactDbRsp; |
3359 | | |
3360 | | int32_t tSerializeSCompactDbRsp(void* buf, int32_t bufLen, SCompactDbRsp* pRsp); |
3361 | | int32_t tDeserializeSCompactDbRsp(void* buf, int32_t bufLen, SCompactDbRsp* pRsp); |
3362 | | |
3363 | | typedef struct { |
3364 | | union { |
3365 | | int32_t compactId; |
3366 | | int32_t id; |
3367 | | }; |
3368 | | int8_t force; |
3369 | | int32_t sqlLen; |
3370 | | char* sql; |
3371 | | } SKillCompactReq; |
3372 | | |
3373 | | int32_t tSerializeSKillCompactReq(void* buf, int32_t bufLen, SKillCompactReq* pReq); |
3374 | | int32_t tDeserializeSKillCompactReq(void* buf, int32_t bufLen, SKillCompactReq* pReq); |
3375 | | void tFreeSKillCompactReq(SKillCompactReq* pReq); |
3376 | | |
3377 | | // ==================== Cluster-level backup/restore ==================== |
3378 | | // client -> mnode: start a backup. Phase 2 only wires cluster-level FULL backup; |
3379 | | // isFull and dbName are reserved for later phases. |
3380 | | typedef struct { |
3381 | | int32_t dnodeId; // dnode that owns backupRoot and runs the agent |
3382 | | char backupRoot[TSDB_MOUNT_PATH_LEN]; |
3383 | | int8_t isFull; // reserved: 1 = full, 0 = incremental |
3384 | | int64_t backupChainId; // reserved: target chain for incremental; 0 = latest |
3385 | | char dbName[TSDB_DB_FNAME_LEN]; // reserved: empty = whole cluster |
3386 | | int8_t hasPassword; |
3387 | | char password[TSDB_PASSWORD_LEN]; |
3388 | | int32_t parallel; // vgroup backup parallelism; >= 1, 1 = serial |
3389 | | int32_t sqlLen; |
3390 | | char* sql; |
3391 | | } SBackupReq; |
3392 | | |
3393 | | int32_t tSerializeSBackupReq(void* buf, int32_t bufLen, SBackupReq* pReq); |
3394 | | int32_t tDeserializeSBackupReq(void* buf, int32_t bufLen, SBackupReq* pReq); |
3395 | | void tFreeSBackupReq(SBackupReq* pReq); |
3396 | | |
3397 | | typedef struct { |
3398 | | int64_t chainId; // backup chain id assigned by mnode |
3399 | | int64_t backupId; // individual backup id within the chain |
3400 | | int8_t bAccepted; |
3401 | | } SBackupRsp; |
3402 | | |
3403 | | int32_t tSerializeSBackupRsp(void* buf, int32_t bufLen, SBackupRsp* pRsp); |
3404 | | int32_t tDeserializeSBackupRsp(void* buf, int32_t bufLen, SBackupRsp* pRsp); |
3405 | | |
3406 | | typedef struct { |
3407 | | int64_t backupId; |
3408 | | int32_t sqlLen; |
3409 | | char* sql; |
3410 | | } SKillBackupReq; |
3411 | | |
3412 | | int32_t tSerializeSKillBackupReq(void* buf, int32_t bufLen, SKillBackupReq* pReq); |
3413 | | int32_t tDeserializeSKillBackupReq(void* buf, int32_t bufLen, SKillBackupReq* pReq); |
3414 | | void tFreeSKillBackupReq(SKillBackupReq* pReq); |
3415 | | |
3416 | | typedef struct { |
3417 | | int32_t vgId; |
3418 | | int64_t dbUid; |
3419 | | char dbName[TSDB_DB_FNAME_LEN]; |
3420 | | int8_t numOfDnodes; |
3421 | | int32_t dnodeIds[TSDB_MAX_REPLICA]; |
3422 | | } SBackupVgroupInfo; |
3423 | | |
3424 | | typedef struct { |
3425 | | int64_t streamId; |
3426 | | int32_t snodeDnodeId; |
3427 | | } SBackupStreamSnodeInfo; |
3428 | | |
3429 | | typedef struct { |
3430 | | int32_t id; |
3431 | | int8_t isSnode; |
3432 | | int8_t isMnode; |
3433 | | } SBackupDnodeInfo; |
3434 | | |
3435 | | // mnode -> target dnode agent: dispatch a backup job |
3436 | | typedef struct { |
3437 | | int64_t chainId; // resolved chain id assigned/selected by mnode |
3438 | | int64_t backupId; |
3439 | | int32_t dnodeId; |
3440 | | char backupRoot[TSDB_MOUNT_PATH_LEN]; |
3441 | | int8_t isFull; |
3442 | | char dbName[TSDB_DB_FNAME_LEN]; // reserved: empty = whole cluster |
3443 | | int8_t hasPassword; |
3444 | | char password[TSDB_PASSWORD_LEN]; |
3445 | | int32_t parallel; // vgroup backup parallelism; >= 1, 1 = serial |
3446 | | SArray *dnodes; // SBackupDnodeInfo, sorted ascending by id |
3447 | | SArray *streamSnodes; // SBackupStreamSnodeInfo |
3448 | | SArray *vgroups; // SBackupVgroupInfo |
3449 | | } SBackupDnodeReq; |
3450 | | |
3451 | | int32_t tSerializeSBackupDnodeReq(void* buf, int32_t bufLen, SBackupDnodeReq* pReq); |
3452 | | int32_t tDeserializeSBackupDnodeReq(void* buf, int32_t bufLen, SBackupDnodeReq* pReq); |
3453 | | void tFreeSBackupDnodeReq(SBackupDnodeReq* pReq); |
3454 | | |
3455 | | // mnode <-> dnode agent: query backup progress |
3456 | | typedef struct { |
3457 | | int64_t chainId; |
3458 | | int64_t backupId; |
3459 | | } SBackupProgressReq; |
3460 | | |
3461 | | int32_t tSerializeSBackupProgressReq(void* buf, int32_t bufLen, SBackupProgressReq* pReq); |
3462 | | int32_t tDeserializeSBackupProgressReq(void* buf, int32_t bufLen, SBackupProgressReq* pReq); |
3463 | | |
3464 | | typedef struct { |
3465 | | int64_t chainId; |
3466 | | int64_t backupId; |
3467 | | int8_t finished; // 1 = the agent-side task has finished (success or failure) |
3468 | | int64_t totalSize; // bytes written so far |
3469 | | int32_t totalVgroups; |
3470 | | int32_t finishedVgroups; |
3471 | | int32_t code; // agent-side result code; 0 = success |
3472 | | } SBackupProgressRsp; |
3473 | | |
3474 | | int32_t tSerializeSBackupProgressRsp(void* buf, int32_t bufLen, SBackupProgressRsp* pRsp); |
3475 | | int32_t tDeserializeSBackupProgressRsp(void* buf, int32_t bufLen, SBackupProgressRsp* pRsp); |
3476 | | |
3477 | | // dnode agent -> mnode: pull mnode metadata for backup |
3478 | | typedef struct { |
3479 | | int64_t chainId; |
3480 | | int64_t backupId; |
3481 | | } SBackupMetaReq; |
3482 | | |
3483 | | int32_t tSerializeSBackupMetaReq(void* buf, int32_t bufLen, SBackupMetaReq* pReq); |
3484 | | int32_t tDeserializeSBackupMetaReq(void* buf, int32_t bufLen, SBackupMetaReq* pReq); |
3485 | | |
3486 | | // One packaged file within a backup unit. relPath is relative to the unit's |
3487 | | // directory (e.g. "sdb.data", "mnode.json", "sync/raft_config.json"), so the |
3488 | | // agent can recreate the exact tree. Reusable across mnode/vnode/snode units. |
3489 | | typedef struct { |
3490 | | char relPath[TSDB_FILENAME_LEN]; |
3491 | | int32_t dataLen; |
3492 | | void* data; |
3493 | | } SBackupFile; |
3494 | | |
3495 | | typedef struct { |
3496 | | int64_t sdbEndVersion; // sdb.data end version at snapshot time |
3497 | | int32_t numOfFiles; // number of valid entries in files[] |
3498 | | SBackupFile files[4]; // sdb.data + mnode.json + sync raft config/store |
3499 | | } SBackupMetaRsp; |
3500 | | |
3501 | | int32_t tSerializeSBackupMetaRsp(void* buf, int32_t bufLen, SBackupMetaRsp* pRsp); |
3502 | | int32_t tDeserializeSBackupMetaRsp(void* buf, int32_t bufLen, SBackupMetaRsp* pRsp); |
3503 | | void tFreeSBackupMetaRsp(SBackupMetaRsp* pRsp); |
3504 | | |
3505 | | // dnode backup agent -> mnode: resolve the current leader immediately before |
3506 | | // starting this vgroup's snapshot. The returned endpoint is the sole source |
3507 | | // for that snapshot session. |
3508 | | typedef struct { |
3509 | | int64_t chainId; |
3510 | | int64_t backupId; |
3511 | | int32_t vgId; |
3512 | | } SBackupVgroupLeaderReq; |
3513 | | |
3514 | | typedef struct { |
3515 | | int32_t vgId; |
3516 | | int32_t leaderDnodeId; |
3517 | | SEpSet leaderEpSet; |
3518 | | } SBackupVgroupLeaderRsp; |
3519 | | |
3520 | | int32_t tSerializeSBackupVgroupLeaderReq(void* buf, int32_t bufLen, SBackupVgroupLeaderReq* pReq); |
3521 | | int32_t tDeserializeSBackupVgroupLeaderReq(void* buf, int32_t bufLen, SBackupVgroupLeaderReq* pReq); |
3522 | | int32_t tSerializeSBackupVgroupLeaderRsp(void* buf, int32_t bufLen, SBackupVgroupLeaderRsp* pRsp); |
3523 | | int32_t tDeserializeSBackupVgroupLeaderRsp(void* buf, int32_t bufLen, SBackupVgroupLeaderRsp* pRsp); |
3524 | | |
3525 | | // dnode backup agent -> SNode dnode: package the requested stream checkpoints. |
3526 | | typedef struct { |
3527 | | int32_t dnodeId; |
3528 | | SArray* streamIds; // int64_t |
3529 | | } SBackupSnodeReq; |
3530 | | |
3531 | | typedef struct { |
3532 | | SArray* files; // SBackupFile |
3533 | | } SBackupSnodeRsp; |
3534 | | |
3535 | | int32_t tSerializeSBackupSnodeReq(void* buf, int32_t bufLen, SBackupSnodeReq* pReq); |
3536 | | int32_t tDeserializeSBackupSnodeReq(void* buf, int32_t bufLen, SBackupSnodeReq* pReq); |
3537 | | void tFreeSBackupSnodeReq(SBackupSnodeReq* pReq); |
3538 | | int32_t tSerializeSBackupSnodeRsp(void* buf, int32_t bufLen, SBackupSnodeRsp* pRsp); |
3539 | | int32_t tDeserializeSBackupSnodeRsp(void* buf, int32_t bufLen, SBackupSnodeRsp* pRsp); |
3540 | | void tFreeSBackupSnodeRsp(SBackupSnodeRsp* pRsp); |
3541 | | |
3542 | | // Check column/tag reference by privilege (for RENAME COLUMN/TAG on normal/virtual tables) |
3543 | | typedef struct { |
3544 | | char tbFName[TSDB_TABLE_FNAME_LEN]; |
3545 | | col_id_t colId; |
3546 | | char colName[TSDB_COL_NAME_LEN]; |
3547 | | } SMndCheckColRefReq; |
3548 | | |
3549 | | typedef struct { |
3550 | | int32_t code; // TSDB_CODE_SUCCESS or error code (e.g., TSDB_CODE_MND_COL_REF_BY_USER_PRIV) |
3551 | | } SMndCheckColRefRsp; |
3552 | | |
3553 | | int32_t tSerializeSMndCheckColRefReq(void* buf, int32_t bufLen, SMndCheckColRefReq* pReq); |
3554 | | int32_t tDeserializeSMndCheckColRefReq(void* buf, int32_t bufLen, SMndCheckColRefReq* pReq); |
3555 | | int32_t tSerializeSMndCheckColRefRsp(void* buf, int32_t bufLen, SMndCheckColRefRsp* pRsp); |
3556 | | int32_t tDeserializeSMndCheckColRefRsp(void* buf, int32_t bufLen, SMndCheckColRefRsp* pRsp); |
3557 | | |
3558 | | typedef enum { |
3559 | | BACKUP_VNODE_SNAP_BEGIN = 1, |
3560 | | BACKUP_VNODE_SNAP_FETCH = 2, |
3561 | | BACKUP_VNODE_SNAP_RELEASE = 3, |
3562 | | } EBackupVnodeSnapOp; |
3563 | | |
3564 | | // vnode write queue: establish a committed boundary after all preceding writes |
3565 | | typedef struct { |
3566 | | int32_t vgId; |
3567 | | } SVnodeSyncCommitReq; |
3568 | | |
3569 | | int32_t tSerializeSVnodeSyncCommitReq(void* buf, int32_t bufLen, SVnodeSyncCommitReq* pReq); |
3570 | | int32_t tDeserializeSVnodeSyncCommitReq(void* buf, int32_t bufLen, SVnodeSyncCommitReq* pReq); |
3571 | | |
3572 | | // dnode agent -> vnode leader: manage one backup snapshot session |
3573 | | typedef struct { |
3574 | | int32_t vgId; |
3575 | | int64_t chainId; |
3576 | | int64_t backupId; |
3577 | | int8_t isFull; |
3578 | | int8_t op; |
3579 | | } SBackupVnodeSnapReq; |
3580 | | |
3581 | | typedef struct { |
3582 | | int32_t vgId; |
3583 | | int64_t snapshotIndex; |
3584 | | int8_t eof; |
3585 | | int32_t dataLen; |
3586 | | void* data; |
3587 | | } SBackupVnodeSnapRsp; |
3588 | | |
3589 | | int32_t tSerializeSBackupVnodeSnapReq(void* buf, int32_t bufLen, SBackupVnodeSnapReq* pReq); |
3590 | | int32_t tDeserializeSBackupVnodeSnapReq(void* buf, int32_t bufLen, SBackupVnodeSnapReq* pReq); |
3591 | | int32_t tSerializeSBackupVnodeSnapRsp(void* buf, int32_t bufLen, SBackupVnodeSnapRsp* pRsp); |
3592 | | int32_t tDeserializeSBackupVnodeSnapRsp(void* buf, int32_t bufLen, SBackupVnodeSnapRsp* pRsp); |
3593 | | void tFreeSBackupVnodeSnapRsp(SBackupVnodeSnapRsp* pRsp); |
3594 | | |
3595 | | typedef SCompactDbRsp STrimDbRsp; // reuse structs |
3596 | | typedef SKillCompactReq SKillRetentionReq; // reuse structs |
3597 | | |
3598 | | typedef struct { |
3599 | | char name[TSDB_FUNC_NAME_LEN]; |
3600 | | int8_t igExists; |
3601 | | int8_t funcType; |
3602 | | int8_t scriptType; |
3603 | | int8_t outputType; |
3604 | | int32_t outputLen; |
3605 | | int32_t bufSize; |
3606 | | int32_t codeLen; |
3607 | | int64_t signature; |
3608 | | char* pComment; |
3609 | | char* pCode; |
3610 | | int8_t orReplace; |
3611 | | } SCreateFuncReq; |
3612 | | |
3613 | | int32_t tSerializeSCreateFuncReq(void* buf, int32_t bufLen, SCreateFuncReq* pReq); |
3614 | | int32_t tDeserializeSCreateFuncReq(void* buf, int32_t bufLen, SCreateFuncReq* pReq); |
3615 | | void tFreeSCreateFuncReq(SCreateFuncReq* pReq); |
3616 | | |
3617 | | typedef struct { |
3618 | | char name[TSDB_FUNC_NAME_LEN]; |
3619 | | int8_t igNotExists; |
3620 | | } SDropFuncReq; |
3621 | | |
3622 | | int32_t tSerializeSDropFuncReq(void* buf, int32_t bufLen, SDropFuncReq* pReq); |
3623 | | int32_t tDeserializeSDropFuncReq(void* buf, int32_t bufLen, SDropFuncReq* pReq); |
3624 | | |
3625 | | typedef struct { |
3626 | | int32_t numOfFuncs; |
3627 | | bool ignoreCodeComment; |
3628 | | SArray* pFuncNames; |
3629 | | } SRetrieveFuncReq; |
3630 | | |
3631 | | int32_t tSerializeSRetrieveFuncReq(void* buf, int32_t bufLen, SRetrieveFuncReq* pReq); |
3632 | | int32_t tDeserializeSRetrieveFuncReq(void* buf, int32_t bufLen, SRetrieveFuncReq* pReq); |
3633 | | void tFreeSRetrieveFuncReq(SRetrieveFuncReq* pReq); |
3634 | | |
3635 | | typedef struct { |
3636 | | char name[TSDB_FUNC_NAME_LEN]; |
3637 | | int8_t funcType; |
3638 | | int8_t scriptType; |
3639 | | int8_t outputType; |
3640 | | int32_t outputLen; |
3641 | | int32_t bufSize; |
3642 | | int64_t signature; |
3643 | | int32_t commentSize; |
3644 | | int32_t codeSize; |
3645 | | char* pComment; |
3646 | | char* pCode; |
3647 | | } SFuncInfo; |
3648 | | |
3649 | | typedef struct { |
3650 | | int32_t funcVersion; |
3651 | | int64_t funcCreatedTime; |
3652 | | } SFuncExtraInfo; |
3653 | | |
3654 | | typedef struct { |
3655 | | int32_t numOfFuncs; |
3656 | | SArray* pFuncInfos; |
3657 | | SArray* pFuncExtraInfos; |
3658 | | } SRetrieveFuncRsp; |
3659 | | |
3660 | | int32_t tSerializeSRetrieveFuncRsp(void* buf, int32_t bufLen, SRetrieveFuncRsp* pRsp); |
3661 | | int32_t tDeserializeSRetrieveFuncRsp(void* buf, int32_t bufLen, SRetrieveFuncRsp* pRsp); |
3662 | | void tFreeSFuncInfo(SFuncInfo* pInfo); |
3663 | | void tFreeSRetrieveFuncRsp(SRetrieveFuncRsp* pRsp); |
3664 | | |
3665 | | typedef struct { |
3666 | | int32_t statusInterval; |
3667 | | /* |
3668 | | Local timezone UTC offset in seconds (east-positive, e.g. +28800 for |
3669 | | Asia/Shanghai). Derived from taosGetLocalTimezoneOffset() on each |
3670 | | status report. Paired with the timezone string in |
3671 | | mndCheckClusterCfgPara: a mismatch is reported only when both the |
3672 | | timezone string AND this offset differ. |
3673 | | */ |
3674 | | int64_t checkTime; |
3675 | | char timezone[TD_TIMEZONE_LEN]; // tsTimezone |
3676 | | char locale[TD_LOCALE_LEN]; // tsLocale |
3677 | | char charset[TD_LOCALE_LEN]; // tsCharset |
3678 | | int8_t ttlChangeOnWrite; |
3679 | | int8_t enableWhiteList; |
3680 | | int8_t encryptionKeyStat; |
3681 | | uint32_t encryptionKeyChksum; |
3682 | | SMonitorParas monitorParas; |
3683 | | int32_t statusIntervalMs; |
3684 | | } SClusterCfg; |
3685 | | |
3686 | | typedef struct { |
3687 | | int32_t openVnodes; |
3688 | | int32_t dropVnodes; |
3689 | | int32_t totalVnodes; |
3690 | | int32_t masterNum; |
3691 | | int64_t numOfSelectReqs; |
3692 | | int64_t numOfInsertReqs; |
3693 | | int64_t numOfInsertSuccessReqs; |
3694 | | int64_t numOfBatchInsertReqs; |
3695 | | int64_t numOfBatchInsertSuccessReqs; |
3696 | | int64_t errors; |
3697 | | } SVnodesStat; |
3698 | | |
3699 | | // Progress (byte-level) of a single snapshot-send target. One entry per destDnodeId, reported to |
3700 | | // the mnode via SVnodeLoad, so the mnode can display progress on the column matching the target |
3701 | | // follower's dnodeId, fixing the "misaligned display" problem. |
3702 | | typedef struct { |
3703 | | int32_t destDnodeId; // target follower dnodeId |
3704 | | int64_t snapTotalSize; // total snapshot bytes being sent to this target |
3705 | | int64_t snapTransferredSize; // snapshot bytes already sent to this target |
3706 | | } SVnodeSnapProgress; |
3707 | | |
3708 | | typedef struct { |
3709 | | int32_t vgId; |
3710 | | int8_t syncState; |
3711 | | int8_t syncRestore; |
3712 | | int64_t syncTerm; |
3713 | | int64_t roleTimeMs; |
3714 | | int64_t startTimeMs; |
3715 | | int8_t syncCanRead; |
3716 | | int64_t cacheUsage; |
3717 | | int64_t numOfTables; |
3718 | | int64_t numOfTimeSeries; |
3719 | | int64_t totalStorage; |
3720 | | int64_t compStorage; |
3721 | | int64_t pointsWritten; |
3722 | | int64_t numOfSelectReqs; |
3723 | | int64_t numOfInsertReqs; |
3724 | | int64_t numOfInsertSuccessReqs; |
3725 | | int64_t numOfBatchInsertReqs; |
3726 | | int64_t numOfBatchInsertSuccessReqs; |
3727 | | int32_t numOfCachedTables; |
3728 | | int32_t learnerProgress; // use one reservered |
3729 | | int64_t syncAppliedIndex; |
3730 | | int64_t syncCommitIndex; |
3731 | | int64_t bufferSegmentUsed; |
3732 | | int64_t bufferSegmentSize; |
3733 | | int32_t snapSeq; |
3734 | | int64_t syncTotalIndex; |
3735 | | int8_t snapshotSending; // 1 if this vnode is currently sending a snapshot |
3736 | | // Per-target snapshot-send progress: SArray<SVnodeSnapProgress>, grouped by target follower dnodeId. |
3737 | | // Replaces the former single scalar snapTotalSize/snapTransferredSize so the mnode can display |
3738 | | // progress per target. |
3739 | | SArray* pSnapProgress; |
3740 | | } SVnodeLoad; |
3741 | | |
3742 | | typedef struct { |
3743 | | int64_t total_requests; |
3744 | | int64_t total_rows; |
3745 | | int64_t total_bytes; |
3746 | | double write_size; |
3747 | | double cache_hit_ratio; |
3748 | | int64_t rpc_queue_wait; |
3749 | | int64_t preprocess_time; |
3750 | | |
3751 | | int64_t memory_table_size; |
3752 | | int64_t commit_count; |
3753 | | int64_t merge_count; |
3754 | | double commit_time; |
3755 | | double merge_time; |
3756 | | int64_t block_commit_time; |
3757 | | int64_t memtable_wait_time; |
3758 | | } SVnodeMetrics; |
3759 | | |
3760 | | typedef struct { |
3761 | | int32_t vgId; |
3762 | | int64_t numOfTables; |
3763 | | int64_t memSize; |
3764 | | int64_t l1Size; |
3765 | | int64_t l2Size; |
3766 | | int64_t l3Size; |
3767 | | int64_t cacheSize; |
3768 | | int64_t walSize; |
3769 | | int64_t metaSize; |
3770 | | int64_t rawDataSize; |
3771 | | int64_t ssSize; |
3772 | | const char* dbname; |
3773 | | int8_t estimateRawData; |
3774 | | } SDbSizeStatisInfo; |
3775 | | |
3776 | | typedef struct SLastCacheStats { |
3777 | | int32_t dnodeId; |
3778 | | int64_t blockCacheCapacity; |
3779 | | int64_t blockCacheUsage; |
3780 | | int64_t blockCachePinnedUsage; |
3781 | | int64_t estimateTableReadersMem; |
3782 | | int64_t curSizeActiveMemTable; |
3783 | | int64_t curSizeAllMemTables; |
3784 | | int32_t numImmutableMemTable; |
3785 | | bool memTableFlushPending; |
3786 | | int32_t numRunningFlushes; |
3787 | | bool compactionPending; |
3788 | | int32_t numRunningCompactions; |
3789 | | int64_t estimatePendingCompactionBytes; |
3790 | | bool isWriteStopped; |
3791 | | int64_t actualDelayedWriteRate; |
3792 | | int32_t numFilesAtLevel0; |
3793 | | int64_t totalSstFilesSize; |
3794 | | int64_t estimateNumKeys; |
3795 | | int32_t numLiveVersions; |
3796 | | int32_t backgroundErrors; |
3797 | | } SLastCacheStats; |
3798 | | |
3799 | | typedef struct { |
3800 | | int32_t vgId; |
3801 | | int64_t nTimeSeries; |
3802 | | } SVnodeLoadLite; |
3803 | | |
3804 | | typedef struct { |
3805 | | int8_t syncState; |
3806 | | int64_t syncTerm; |
3807 | | int8_t syncRestore; |
3808 | | int64_t roleTimeMs; |
3809 | | } SMnodeLoad; |
3810 | | |
3811 | | typedef struct { |
3812 | | int32_t dnodeId; |
3813 | | int64_t numOfProcessedQuery; |
3814 | | int64_t numOfProcessedCQuery; |
3815 | | int64_t numOfProcessedFetch; |
3816 | | int64_t numOfProcessedDrop; |
3817 | | int64_t numOfProcessedNotify; |
3818 | | int64_t numOfProcessedHb; |
3819 | | int64_t numOfProcessedDelete; |
3820 | | int64_t cacheDataSize; |
3821 | | int64_t numOfQueryInQueue; |
3822 | | int64_t numOfFetchInQueue; |
3823 | | int64_t timeInQueryQueue; |
3824 | | int64_t timeInFetchQueue; |
3825 | | } SQnodeLoad; |
3826 | | |
3827 | | typedef struct { |
3828 | | int32_t sver; // software version |
3829 | | int64_t dnodeVer; // dnode table version in sdb |
3830 | | int32_t dnodeId; |
3831 | | int64_t clusterId; |
3832 | | int64_t rebootTime; |
3833 | | int64_t updateTime; |
3834 | | float numOfCores; |
3835 | | int32_t numOfSupportVnodes; |
3836 | | int32_t numOfDiskCfg; |
3837 | | int64_t memTotal; |
3838 | | int64_t memAvail; |
3839 | | char dnodeEp[TSDB_EP_LEN]; |
3840 | | char machineId[TSDB_MACHINE_ID_LEN + 1]; |
3841 | | SMnodeLoad mload; |
3842 | | SQnodeLoad qload; |
3843 | | SClusterCfg clusterCfg; |
3844 | | SArray* pVloads; // array of SVnodeLoad |
3845 | | int32_t statusSeq; |
3846 | | int64_t ipWhiteVer; |
3847 | | int64_t timeWhiteVer; |
3848 | | int64_t analVer; |
3849 | | int64_t timestamp; |
3850 | | char auditDB[TSDB_DB_FNAME_LEN]; |
3851 | | char auditToken[TSDB_TOKEN_LEN]; |
3852 | | SEpSet auditEpSet; |
3853 | | int32_t auditVgId; |
3854 | | SArray* pTxnActiveQueries; // array of STxnActiveQuery, optional (NULL if no idle txns) |
3855 | | } SStatusReq; |
3856 | | |
3857 | | int32_t tSerializeSStatusReq(void* buf, int32_t bufLen, SStatusReq* pReq); |
3858 | | int32_t tDeserializeSStatusReq(void* buf, int32_t bufLen, SStatusReq* pReq); |
3859 | | void tFreeSStatusReq(SStatusReq* pReq); |
3860 | | // Free an SArray of SVnodeLoad. Each SVnodeLoad may embed a per-target snapshot |
3861 | | // progress array (pSnapProgress) allocated in vnodeGetLoad(); it must be freed |
3862 | | // before destroying the outer array, otherwise pSnapProgress leaks. Use this |
3863 | | // helper anywhere an SVnodeLoad array is destroyed to avoid such leaks. |
3864 | | void tFreeSVnodeLoadArray(SArray* pVloads); |
3865 | | |
3866 | | typedef struct { |
3867 | | int32_t forceReadConfig; |
3868 | | int32_t cver; |
3869 | | SArray* array; |
3870 | | } SConfigReq; |
3871 | | |
3872 | | int32_t tSerializeSConfigReq(void* buf, int32_t bufLen, SConfigReq* pReq); |
3873 | | int32_t tDeserializeSConfigReq(void* buf, int32_t bufLen, SConfigReq* pReq); |
3874 | | void tFreeSConfigReq(SConfigReq* pReq); |
3875 | | |
3876 | | typedef struct { |
3877 | | int32_t dnodeId; |
3878 | | char machineId[TSDB_MACHINE_ID_LEN + 1]; |
3879 | | } SDnodeInfoReq; |
3880 | | |
3881 | | int32_t tSerializeSDnodeInfoReq(void* buf, int32_t bufLen, SDnodeInfoReq* pReq); |
3882 | | int32_t tDeserializeSDnodeInfoReq(void* buf, int32_t bufLen, SDnodeInfoReq* pReq); |
3883 | | |
3884 | | typedef enum { |
3885 | | MONITOR_TYPE_COUNTER = 0, |
3886 | | MONITOR_TYPE_SLOW_LOG = 1, |
3887 | | } MONITOR_TYPE; |
3888 | | |
3889 | | typedef struct { |
3890 | | int32_t contLen; |
3891 | | char* pCont; |
3892 | | MONITOR_TYPE type; |
3893 | | } SStatisReq; |
3894 | | |
3895 | | int32_t tSerializeSStatisReq(void* buf, int32_t bufLen, SStatisReq* pReq); |
3896 | | int32_t tDeserializeSStatisReq(void* buf, int32_t bufLen, SStatisReq* pReq); |
3897 | | void tFreeSStatisReq(SStatisReq* pReq); |
3898 | | |
3899 | | typedef struct { |
3900 | | char db[TSDB_DB_FNAME_LEN]; |
3901 | | char table[TSDB_TABLE_NAME_LEN]; |
3902 | | char operation[AUDIT_OPERATION_LEN]; |
3903 | | int32_t sqlLen; |
3904 | | char* pSql; |
3905 | | double duration; |
3906 | | int64_t affectedRows; |
3907 | | } SAuditReq; |
3908 | | int32_t tSerializeSAuditReq(void* buf, int32_t bufLen, SAuditReq* pReq); |
3909 | | int32_t tDeserializeSAuditReq(void* buf, int32_t bufLen, SAuditReq* pReq); |
3910 | | void tFreeSAuditReq(SAuditReq* pReq); |
3911 | | |
3912 | | typedef struct { |
3913 | | SArray* auditArr; |
3914 | | } SBatchAuditReq; |
3915 | | int32_t tSerializeSBatchAuditReq(void* buf, int32_t bufLen, SBatchAuditReq* pReq); |
3916 | | int32_t tDeserializeSBatchAuditReq(void* buf, int32_t bufLen, SBatchAuditReq* pReq); |
3917 | | void tFreeSBatchAuditReq(SBatchAuditReq* pReq); |
3918 | | |
3919 | | typedef struct { |
3920 | | int32_t dnodeId; |
3921 | | int64_t clusterId; |
3922 | | SArray* pVloads; |
3923 | | } SNotifyReq; |
3924 | | |
3925 | | int32_t tSerializeSNotifyReq(void* buf, int32_t bufLen, SNotifyReq* pReq); |
3926 | | int32_t tDeserializeSNotifyReq(void* buf, int32_t bufLen, SNotifyReq* pReq); |
3927 | | void tFreeSNotifyReq(SNotifyReq* pReq); |
3928 | | |
3929 | | typedef struct { |
3930 | | int32_t dnodeId; |
3931 | | int64_t clusterId; |
3932 | | } SDnodeCfg; |
3933 | | |
3934 | | typedef struct { |
3935 | | int32_t id; |
3936 | | int8_t isMnode; |
3937 | | SEp ep; |
3938 | | } SDnodeEp; |
3939 | | |
3940 | | typedef struct { |
3941 | | int32_t id; |
3942 | | int8_t isMnode; |
3943 | | int8_t offlineReason; |
3944 | | SEp ep; |
3945 | | char active[TSDB_ACTIVE_KEY_LEN]; |
3946 | | char connActive[TSDB_CONN_ACTIVE_KEY_LEN]; |
3947 | | } SDnodeInfo; |
3948 | | |
3949 | | typedef struct { |
3950 | | int64_t dnodeVer; |
3951 | | SDnodeCfg dnodeCfg; |
3952 | | SArray* pDnodeEps; // Array of SDnodeEp |
3953 | | int32_t statusSeq; |
3954 | | int64_t ipWhiteVer; |
3955 | | int64_t analVer; |
3956 | | int64_t timeWhiteVer; |
3957 | | char auditDB[TSDB_DB_FNAME_LEN]; |
3958 | | char auditToken[TSDB_TOKEN_LEN]; |
3959 | | SEpSet auditEpSet; |
3960 | | int32_t auditVgId; |
3961 | | } SStatusRsp; |
3962 | | |
3963 | | int32_t tSerializeSStatusRsp(void* buf, int32_t bufLen, SStatusRsp* pRsp); |
3964 | | int32_t tDeserializeSStatusRsp(void* buf, int32_t bufLen, SStatusRsp* pRsp); |
3965 | | void tFreeSStatusRsp(SStatusRsp* pRsp); |
3966 | | |
3967 | | typedef struct { |
3968 | | int32_t forceReadConfig; |
3969 | | int32_t isConifgVerified; |
3970 | | int32_t isVersionVerified; |
3971 | | int32_t cver; |
3972 | | SArray* array; |
3973 | | } SConfigRsp; |
3974 | | |
3975 | | int32_t tSerializeSConfigRsp(void* buf, int32_t bufLen, SConfigRsp* pRsp); |
3976 | | int32_t tDeserializeSConfigRsp(void* buf, int32_t bufLen, SConfigRsp* pRsp); |
3977 | | void tFreeSConfigRsp(SConfigRsp* pRsp); |
3978 | | |
3979 | | typedef struct { |
3980 | | int32_t dnodeId; |
3981 | | int32_t keyVersion; // Local key version |
3982 | | } SKeySyncReq; |
3983 | | |
3984 | | int32_t tSerializeSKeySyncReq(void* buf, int32_t bufLen, SKeySyncReq* pReq); |
3985 | | int32_t tDeserializeSKeySyncReq(void* buf, int32_t bufLen, SKeySyncReq* pReq); |
3986 | | |
3987 | | typedef struct { |
3988 | | int32_t keyVersion; // mnode's key version |
3989 | | int8_t needUpdate; // 1 if dnode needs to update keys |
3990 | | int32_t encryptionKeyStatus; // Encryption key status (TSDB_ENCRYPT_KEY_STAT_*) |
3991 | | char svrKey[129]; // Server key (if needUpdate) |
3992 | | char dbKey[129]; // Database key (if needUpdate) |
3993 | | char cfgKey[129]; // Config key (if needUpdate) |
3994 | | char metaKey[129]; // Metadata key (if needUpdate) |
3995 | | char dataKey[129]; // Data key (if needUpdate) |
3996 | | int32_t algorithm; // Encryption algorithm for master keys |
3997 | | int32_t cfgAlgorithm; // Encryption algorithm for CFG_KEY |
3998 | | int32_t metaAlgorithm; // Encryption algorithm for META_KEY |
3999 | | int64_t createTime; // Key creation time |
4000 | | int64_t svrKeyUpdateTime; // Server key update time |
4001 | | int64_t dbKeyUpdateTime; // Database key update time |
4002 | | } SKeySyncRsp; |
4003 | | |
4004 | | int32_t tSerializeSKeySyncRsp(void* buf, int32_t bufLen, SKeySyncRsp* pRsp); |
4005 | | int32_t tDeserializeSKeySyncRsp(void* buf, int32_t bufLen, SKeySyncRsp* pRsp); |
4006 | | |
4007 | | typedef struct { |
4008 | | int32_t reserved; |
4009 | | } SMTimerReq; |
4010 | | |
4011 | | int32_t tSerializeSMTimerMsg(void* buf, int32_t bufLen, SMTimerReq* pReq); |
4012 | | // int32_t tDeserializeSMTimerMsg(void* buf, int32_t bufLen, SMTimerReq* pReq); |
4013 | | |
4014 | | typedef struct SOrphanTask { |
4015 | | int64_t streamId; |
4016 | | int32_t taskId; |
4017 | | int32_t nodeId; |
4018 | | } SOrphanTask; |
4019 | | |
4020 | | typedef struct SMStreamDropOrphanMsg { |
4021 | | SArray* pList; // SArray<SOrphanTask> |
4022 | | } SMStreamDropOrphanMsg; |
4023 | | |
4024 | | int32_t tSerializeDropOrphanTaskMsg(void* buf, int32_t bufLen, SMStreamDropOrphanMsg* pMsg); |
4025 | | int32_t tDeserializeDropOrphanTaskMsg(void* buf, int32_t bufLen, SMStreamDropOrphanMsg* pMsg); |
4026 | | void tDestroyDropOrphanTaskMsg(SMStreamDropOrphanMsg* pMsg); |
4027 | | |
4028 | | typedef struct { |
4029 | | int32_t id; |
4030 | | uint16_t port; // node sync Port |
4031 | | char fqdn[TSDB_FQDN_LEN]; // node FQDN |
4032 | | } SReplica; |
4033 | | |
4034 | | typedef struct { |
4035 | | int32_t vgId; |
4036 | | char db[TSDB_DB_FNAME_LEN]; |
4037 | | int64_t dbUid; |
4038 | | int32_t vgVersion; |
4039 | | int32_t numOfStables; |
4040 | | int32_t buffer; |
4041 | | int32_t pageSize; |
4042 | | int32_t pages; |
4043 | | int32_t cacheLastSize; |
4044 | | int32_t cacheLastShardBits; // Number of shards for last cache LRU, -1 for auto |
4045 | | int32_t daysPerFile; |
4046 | | int32_t daysToKeep0; |
4047 | | int32_t daysToKeep1; |
4048 | | int32_t daysToKeep2; |
4049 | | int32_t keepTimeOffset; |
4050 | | int32_t minRows; |
4051 | | int32_t maxRows; |
4052 | | int32_t walFsyncPeriod; |
4053 | | uint32_t hashBegin; |
4054 | | uint32_t hashEnd; |
4055 | | int8_t hashMethod; |
4056 | | int8_t walLevel; |
4057 | | int8_t precision; |
4058 | | int8_t compression; |
4059 | | int8_t strict; |
4060 | | int8_t cacheLast; |
4061 | | int8_t isTsma; |
4062 | | int8_t replica; |
4063 | | int8_t selfIndex; |
4064 | | SReplica replicas[TSDB_MAX_REPLICA]; |
4065 | | int32_t numOfRetensions; |
4066 | | SArray* pRetensions; // SRetention |
4067 | | void* pTsma; |
4068 | | int32_t walRetentionPeriod; |
4069 | | int64_t walRetentionSize; |
4070 | | int32_t walRollPeriod; |
4071 | | int64_t walSegmentSize; |
4072 | | int16_t sstTrigger; |
4073 | | int16_t hashPrefix; |
4074 | | int16_t hashSuffix; |
4075 | | int32_t tsdbPageSize; |
4076 | | int32_t ssChunkSize; |
4077 | | int32_t ssKeepLocal; |
4078 | | int8_t ssCompact; |
4079 | | int64_t reserved[6]; |
4080 | | int8_t learnerReplica; |
4081 | | int8_t learnerSelfIndex; |
4082 | | SReplica learnerReplicas[TSDB_MAX_LEARNER_REPLICA]; |
4083 | | int32_t changeVersion; |
4084 | | int8_t encryptAlgorithm; |
4085 | | char encryptAlgrName[TSDB_ENCRYPT_ALGR_NAME_LEN]; |
4086 | | union { |
4087 | | uint8_t flags; |
4088 | | struct { |
4089 | | uint8_t isAudit : 1; |
4090 | | uint8_t allowDrop : 1; |
4091 | | uint8_t securityLevel : 3; // 6671585124 |
4092 | | uint8_t padding : 3; |
4093 | | }; |
4094 | | }; |
4095 | | int8_t secureDelete; |
4096 | | } SCreateVnodeReq; |
4097 | | |
4098 | | int32_t tSerializeSCreateVnodeReq(void* buf, int32_t bufLen, SCreateVnodeReq* pReq); |
4099 | | int32_t tDeserializeSCreateVnodeReq(void* buf, int32_t bufLen, SCreateVnodeReq* pReq); |
4100 | | int32_t tFreeSCreateVnodeReq(SCreateVnodeReq* pReq); |
4101 | | |
4102 | | typedef struct { |
4103 | | union { |
4104 | | int32_t compactId; |
4105 | | int32_t id; |
4106 | | }; |
4107 | | int32_t vgId; |
4108 | | int32_t dnodeId; |
4109 | | } SQueryCompactProgressReq; |
4110 | | |
4111 | | int32_t tSerializeSQueryCompactProgressReq(void* buf, int32_t bufLen, SQueryCompactProgressReq* pReq); |
4112 | | int32_t tDeserializeSQueryCompactProgressReq(void* buf, int32_t bufLen, SQueryCompactProgressReq* pReq); |
4113 | | |
4114 | | typedef struct { |
4115 | | union { |
4116 | | int32_t compactId; |
4117 | | int32_t id; |
4118 | | }; |
4119 | | int32_t vgId; |
4120 | | int32_t dnodeId; |
4121 | | int32_t numberFileset; |
4122 | | int32_t finished; |
4123 | | int32_t progress; |
4124 | | int64_t remainingTime; |
4125 | | } SQueryCompactProgressRsp; |
4126 | | |
4127 | | int32_t tSerializeSQueryCompactProgressRsp(void* buf, int32_t bufLen, SQueryCompactProgressRsp* pReq); |
4128 | | int32_t tDeserializeSQueryCompactProgressRsp(void* buf, int32_t bufLen, SQueryCompactProgressRsp* pReq); |
4129 | | |
4130 | | // Snap send progress query (mnode -> dnode, dnode -> mnode RSP) |
4131 | | typedef struct { |
4132 | | int32_t fid; |
4133 | | int32_t fileCount; |
4134 | | int32_t finishedFileCount; |
4135 | | int64_t totalSize; |
4136 | | int64_t readSize; |
4137 | | int64_t startTime; // ms timestamp |
4138 | | int64_t sver; |
4139 | | int64_t ever; |
4140 | | int8_t transferType; // SNAP_DATA_TSDB(2) or SNAP_DATA_RAW(14) |
4141 | | } SSnapSendFileSetInfo; |
4142 | | |
4143 | | typedef struct { |
4144 | | int32_t vgId; |
4145 | | int32_t dnodeId; |
4146 | | int32_t totalFileSets; |
4147 | | int32_t finishedFileSets; |
4148 | | int64_t startTime; // ms timestamp of reader open |
4149 | | int32_t fileSetCount; // length of pFileSetInfos |
4150 | | SSnapSendFileSetInfo *pFileSetInfos; |
4151 | | } SSnapSendVnodeInfo; |
4152 | | |
4153 | | typedef struct { |
4154 | | int32_t dnodeId; |
4155 | | int32_t numOfVnodes; |
4156 | | SSnapSendVnodeInfo *pVnodeInfos; // array of numOfVnodes elements |
4157 | | } SDnodeQuerySnapSendProgressRsp; |
4158 | | |
4159 | | int32_t tSerializeSDnodeQuerySnapSendProgressRsp(void *buf, int32_t bufLen, SDnodeQuerySnapSendProgressRsp *pRsp); |
4160 | | int32_t tDeserializeSDnodeQuerySnapSendProgressRsp(void *buf, int32_t bufLen, SDnodeQuerySnapSendProgressRsp *pRsp); |
4161 | | void tFreeSDnodeQuerySnapSendProgressRsp(SDnodeQuerySnapSendProgressRsp *pRsp); |
4162 | | typedef struct { |
4163 | | int32_t compactId; |
4164 | | } SDnodeQueryCompactProgressReq; |
4165 | | |
4166 | | int32_t tSerializeSDnodeQueryCompactProgressReq(void *buf, int32_t bufLen, SDnodeQueryCompactProgressReq *pReq); |
4167 | | int32_t tDeserializeSDnodeQueryCompactProgressReq(void *buf, int32_t bufLen, SDnodeQueryCompactProgressReq *pReq); |
4168 | | |
4169 | | typedef struct { |
4170 | | int32_t dnodeId; |
4171 | | int32_t numOfVnodes; |
4172 | | SQueryCompactProgressRsp *vnodeProgress; // array of numOfVnodes elements |
4173 | | } SDnodeQueryCompactProgressRsp; |
4174 | | |
4175 | | int32_t tSerializeSDnodeQueryCompactProgressRsp(void *buf, int32_t bufLen, SDnodeQueryCompactProgressRsp *pRsp); |
4176 | | int32_t tDeserializeSDnodeQueryCompactProgressRsp(void *buf, int32_t bufLen, SDnodeQueryCompactProgressRsp *pRsp); |
4177 | | void tFreeSDnodeQueryCompactProgressRsp(SDnodeQueryCompactProgressRsp *pRsp); |
4178 | | typedef SQueryCompactProgressReq SQueryRetentionProgressReq; |
4179 | | typedef SQueryCompactProgressRsp SQueryRetentionProgressRsp; |
4180 | | |
4181 | | typedef struct { |
4182 | | int32_t vgId; |
4183 | | int32_t dnodeId; |
4184 | | int64_t dbUid; |
4185 | | char db[TSDB_DB_FNAME_LEN]; |
4186 | | int64_t reserved[8]; |
4187 | | } SDropVnodeReq; |
4188 | | |
4189 | | int32_t tSerializeSDropVnodeReq(void* buf, int32_t bufLen, SDropVnodeReq* pReq); |
4190 | | int32_t tDeserializeSDropVnodeReq(void* buf, int32_t bufLen, SDropVnodeReq* pReq); |
4191 | | |
4192 | | typedef struct { |
4193 | | char colName[TSDB_COL_NAME_LEN]; |
4194 | | char stb[TSDB_TABLE_FNAME_LEN]; |
4195 | | int64_t stbUid; |
4196 | | int64_t dbUid; |
4197 | | int64_t reserved[8]; |
4198 | | } SDropIndexReq; |
4199 | | |
4200 | | int32_t tSerializeSDropIdxReq(void* buf, int32_t bufLen, SDropIndexReq* pReq); |
4201 | | int32_t tDeserializeSDropIdxReq(void* buf, int32_t bufLen, SDropIndexReq* pReq); |
4202 | | |
4203 | | typedef struct { |
4204 | | int64_t dbUid; |
4205 | | char db[TSDB_DB_FNAME_LEN]; |
4206 | | union { |
4207 | | int64_t compactStartTime; |
4208 | | int64_t startTime; |
4209 | | }; |
4210 | | |
4211 | | STimeWindow tw; |
4212 | | union { |
4213 | | int32_t compactId; |
4214 | | int32_t id; |
4215 | | }; |
4216 | | int8_t metaOnly; |
4217 | | union { |
4218 | | uint16_t flags; |
4219 | | struct { |
4220 | | uint16_t optrType : 3; // ETsdbOpType |
4221 | | uint16_t triggerType : 1; // ETriggerType 0 manual, 1 auto |
4222 | | uint16_t reserved : 12; |
4223 | | }; |
4224 | | }; |
4225 | | int8_t force; // force compact |
4226 | | } SCompactVnodeReq; |
4227 | | |
4228 | | int32_t tSerializeSCompactVnodeReq(void* buf, int32_t bufLen, SCompactVnodeReq* pReq); |
4229 | | int32_t tDeserializeSCompactVnodeReq(void* buf, int32_t bufLen, SCompactVnodeReq* pReq); |
4230 | | |
4231 | | typedef struct { |
4232 | | union { |
4233 | | int32_t compactId; |
4234 | | int32_t taskId; |
4235 | | }; |
4236 | | int32_t vgId; |
4237 | | int32_t dnodeId; |
4238 | | } SVKillCompactReq; |
4239 | | |
4240 | | int32_t tSerializeSVKillCompactReq(void* buf, int32_t bufLen, SVKillCompactReq* pReq); |
4241 | | int32_t tDeserializeSVKillCompactReq(void* buf, int32_t bufLen, SVKillCompactReq* pReq); |
4242 | | |
4243 | | typedef SVKillCompactReq SVKillRetentionReq; |
4244 | | |
4245 | | typedef struct { |
4246 | | char db[TSDB_DB_FNAME_LEN]; |
4247 | | int32_t maxSpeed; |
4248 | | int32_t sqlLen; |
4249 | | char* sql; |
4250 | | SArray* vgroupIds; |
4251 | | STimeWindow tw; // unit is second |
4252 | | union { |
4253 | | uint32_t flags; |
4254 | | struct { |
4255 | | uint32_t optrType : 3; // ETsdbOpType |
4256 | | uint32_t triggerType : 1; // ETriggerType 0 manual, 1 auto |
4257 | | uint32_t reserved : 28; |
4258 | | }; |
4259 | | }; |
4260 | | } STrimDbReq; |
4261 | | |
4262 | | int32_t tSerializeSTrimDbReq(void* buf, int32_t bufLen, STrimDbReq* pReq); |
4263 | | int32_t tDeserializeSTrimDbReq(void* buf, int32_t bufLen, STrimDbReq* pReq); |
4264 | | void tFreeSTrimDbReq(STrimDbReq* pReq); |
4265 | | |
4266 | | typedef SCompactVnodeReq SVTrimDbReq; // reuse SCompactVnodeReq, add task monitor since 3.3.8.0 |
4267 | | |
4268 | | int32_t tSerializeSVTrimDbReq(void* buf, int32_t bufLen, SVTrimDbReq* pReq); |
4269 | | int32_t tDeserializeSVTrimDbReq(void* buf, int32_t bufLen, SVTrimDbReq* pReq); |
4270 | | |
4271 | | typedef struct { |
4272 | | int32_t vgVersion; |
4273 | | int32_t buffer; |
4274 | | int32_t pageSize; |
4275 | | int32_t pages; |
4276 | | int32_t cacheLastSize; |
4277 | | int32_t cacheLastShardBits; // Number of shards for last cache LRU, -1 for auto |
4278 | | int32_t daysPerFile; |
4279 | | int32_t daysToKeep0; |
4280 | | int32_t daysToKeep1; |
4281 | | int32_t daysToKeep2; |
4282 | | int32_t keepTimeOffset; |
4283 | | int32_t walFsyncPeriod; |
4284 | | int8_t walLevel; |
4285 | | int8_t strict; |
4286 | | int8_t cacheLast; |
4287 | | int64_t reserved[7]; |
4288 | | // 1st modification |
4289 | | int16_t sttTrigger; |
4290 | | int32_t minRows; |
4291 | | // 2nd modification |
4292 | | int32_t walRetentionPeriod; |
4293 | | int32_t walRetentionSize; |
4294 | | int32_t ssKeepLocal; |
4295 | | int8_t ssCompact; |
4296 | | int8_t allowDrop; |
4297 | | int8_t secureDelete; |
4298 | | int8_t securityLevel; |
4299 | | int32_t maxRows; |
4300 | | } SAlterVnodeConfigReq; |
4301 | | |
4302 | | int32_t tSerializeSAlterVnodeConfigReq(void* buf, int32_t bufLen, SAlterVnodeConfigReq* pReq); |
4303 | | int32_t tDeserializeSAlterVnodeConfigReq(void* buf, int32_t bufLen, SAlterVnodeConfigReq* pReq); |
4304 | | |
4305 | | typedef struct { |
4306 | | int32_t vgId; |
4307 | | int8_t strict; |
4308 | | int8_t selfIndex; |
4309 | | int8_t replica; |
4310 | | SReplica replicas[TSDB_MAX_REPLICA]; |
4311 | | int64_t reserved[8]; |
4312 | | int8_t learnerSelfIndex; |
4313 | | int8_t learnerReplica; |
4314 | | SReplica learnerReplicas[TSDB_MAX_LEARNER_REPLICA]; |
4315 | | int32_t changeVersion; |
4316 | | int32_t electBaseLine; |
4317 | | } SAlterVnodeReplicaReq, SAlterVnodeTypeReq, SCheckLearnCatchupReq, SAlterVnodeElectBaselineReq; |
4318 | | |
4319 | | int32_t tSerializeSAlterVnodeReplicaReq(void* buf, int32_t bufLen, SAlterVnodeReplicaReq* pReq); |
4320 | | int32_t tDeserializeSAlterVnodeReplicaReq(void* buf, int32_t bufLen, SAlterVnodeReplicaReq* pReq); |
4321 | | |
4322 | | typedef struct { |
4323 | | int32_t vgId; |
4324 | | int8_t disable; |
4325 | | } SDisableVnodeWriteReq; |
4326 | | |
4327 | | int32_t tSerializeSDisableVnodeWriteReq(void* buf, int32_t bufLen, SDisableVnodeWriteReq* pReq); |
4328 | | int32_t tDeserializeSDisableVnodeWriteReq(void* buf, int32_t bufLen, SDisableVnodeWriteReq* pReq); |
4329 | | |
4330 | | typedef struct { |
4331 | | int32_t srcVgId; |
4332 | | int32_t dstVgId; |
4333 | | uint32_t hashBegin; |
4334 | | uint32_t hashEnd; |
4335 | | int32_t changeVersion; |
4336 | | int32_t reserved; |
4337 | | } SAlterVnodeHashRangeReq; |
4338 | | |
4339 | | int32_t tSerializeSAlterVnodeHashRangeReq(void* buf, int32_t bufLen, SAlterVnodeHashRangeReq* pReq); |
4340 | | int32_t tDeserializeSAlterVnodeHashRangeReq(void* buf, int32_t bufLen, SAlterVnodeHashRangeReq* pReq); |
4341 | | |
4342 | 0 | #define REQ_OPT_TBNAME 0x0 |
4343 | 0 | #define REQ_OPT_TBUID 0x01 |
4344 | | typedef struct { |
4345 | | SMsgHead header; |
4346 | | char dbFName[TSDB_DB_FNAME_LEN]; |
4347 | | char tbName[TSDB_TABLE_NAME_LEN]; |
4348 | | uint8_t option; |
4349 | | uint8_t autoCreateCtb; |
4350 | | int64_t txnId; // batch meta txn: same-txn visibility for PRE_CREATE entries |
4351 | | } STableInfoReq; |
4352 | | |
4353 | | int32_t tSerializeSTableInfoReq(void* buf, int32_t bufLen, STableInfoReq* pReq); |
4354 | | int32_t tDeserializeSTableInfoReq(void* buf, int32_t bufLen, STableInfoReq* pReq); |
4355 | | |
4356 | | typedef struct { |
4357 | | int8_t metaClone; // create local clone of the cached table meta |
4358 | | int32_t numOfVgroups; |
4359 | | int32_t numOfTables; |
4360 | | int32_t numOfUdfs; |
4361 | | char tableNames[]; |
4362 | | } SMultiTableInfoReq; |
4363 | | |
4364 | | // todo refactor |
4365 | | typedef struct SVgroupInfo { |
4366 | | int32_t vgId; |
4367 | | uint32_t hashBegin; |
4368 | | uint32_t hashEnd; |
4369 | | SEpSet epSet; |
4370 | | union { |
4371 | | int32_t numOfTable; // unit is TSDB_TABLE_NUM_UNIT |
4372 | | int32_t taskId; // used in stream |
4373 | | }; |
4374 | | } SVgroupInfo; |
4375 | | |
4376 | | typedef struct { |
4377 | | int32_t numOfVgroups; |
4378 | | SVgroupInfo vgroups[]; |
4379 | | } SVgroupsInfo; |
4380 | | |
4381 | | typedef struct { |
4382 | | STableMetaRsp* pMeta; |
4383 | | } SMAlterStbRsp; |
4384 | | |
4385 | | int32_t tEncodeSMAlterStbRsp(SEncoder* pEncoder, const SMAlterStbRsp* pRsp); |
4386 | | int32_t tDecodeSMAlterStbRsp(SDecoder* pDecoder, SMAlterStbRsp* pRsp); |
4387 | | void tFreeSMAlterStbRsp(SMAlterStbRsp* pRsp); |
4388 | | |
4389 | | int32_t tSerializeSTableMetaRsp(void* buf, int32_t bufLen, STableMetaRsp* pRsp); |
4390 | | int32_t tDeserializeSTableMetaRsp(void* buf, int32_t bufLen, STableMetaRsp* pRsp); |
4391 | | void tFreeSTableMetaRsp(void* pRsp); |
4392 | | void tFreeSTableIndexRsp(void* info); |
4393 | | |
4394 | | typedef struct { |
4395 | | SArray* pMetaRsp; // Array of STableMetaRsp |
4396 | | SArray* pIndexRsp; // Array of STableIndexRsp; |
4397 | | } SSTbHbRsp; |
4398 | | |
4399 | | int32_t tSerializeSSTbHbRsp(void* buf, int32_t bufLen, SSTbHbRsp* pRsp); |
4400 | | int32_t tDeserializeSSTbHbRsp(void* buf, int32_t bufLen, SSTbHbRsp* pRsp); |
4401 | | void tFreeSSTbHbRsp(SSTbHbRsp* pRsp); |
4402 | | |
4403 | | typedef struct { |
4404 | | SArray* pViewRsp; // Array of SViewMetaRsp*; |
4405 | | } SViewHbRsp; |
4406 | | |
4407 | | int32_t tSerializeSViewHbRsp(void* buf, int32_t bufLen, SViewHbRsp* pRsp); |
4408 | | int32_t tDeserializeSViewHbRsp(void* buf, int32_t bufLen, SViewHbRsp* pRsp); |
4409 | | void tFreeSViewHbRsp(SViewHbRsp* pRsp); |
4410 | | |
4411 | | typedef struct { |
4412 | | int32_t numOfTables; |
4413 | | int32_t numOfVgroup; |
4414 | | int32_t numOfUdf; |
4415 | | int32_t contLen; |
4416 | | int8_t compressed; // denote if compressed or not |
4417 | | int32_t rawLen; // size before compress |
4418 | | uint8_t metaClone; // make meta clone after retrieve meta from mnode |
4419 | | char meta[]; |
4420 | | } SMultiTableMeta; |
4421 | | |
4422 | | typedef struct { |
4423 | | int32_t dataLen; |
4424 | | char name[TSDB_TABLE_FNAME_LEN]; |
4425 | | char* data; |
4426 | | } STagData; |
4427 | | |
4428 | | typedef struct { |
4429 | | int32_t opType; |
4430 | | uint32_t valLen; |
4431 | | char* val; |
4432 | | } SShowVariablesReq; |
4433 | | |
4434 | | int32_t tSerializeSShowVariablesReq(void* buf, int32_t bufLen, SShowVariablesReq* pReq); |
4435 | | int32_t tDeserializeSShowVariablesReq(void* buf, int32_t bufLen, SShowVariablesReq* pReq); |
4436 | | void tFreeSShowVariablesReq(SShowVariablesReq* pReq); |
4437 | | |
4438 | | typedef struct { |
4439 | | char name[TSDB_CONFIG_OPTION_LEN + 1]; |
4440 | | char value[TSDB_CONFIG_PATH_LEN + 1]; |
4441 | | char scope[TSDB_CONFIG_SCOPE_LEN + 1]; |
4442 | | char category[TSDB_CONFIG_CATEGORY_LEN + 1]; |
4443 | | char info[TSDB_CONFIG_INFO_LEN + 1]; |
4444 | | char reboot[TSDB_CONFIG_REBOOT_LEN + 1]; |
4445 | | } SVariablesInfo; |
4446 | | |
4447 | | typedef struct { |
4448 | | SArray* variables; // SArray<SVariablesInfo> |
4449 | | } SShowVariablesRsp; |
4450 | | |
4451 | | int32_t tSerializeSShowVariablesRsp(void* buf, int32_t bufLen, SShowVariablesRsp* pReq); |
4452 | | int32_t tDeserializeSShowVariablesRsp(void* buf, int32_t bufLen, SShowVariablesRsp* pReq); |
4453 | | |
4454 | | void tFreeSShowVariablesRsp(SShowVariablesRsp* pRsp); |
4455 | | |
4456 | | /* |
4457 | | * sql: show tables like '%a_%' |
4458 | | * payload is the query condition, e.g., '%a_%' |
4459 | | * payloadLen is the length of payload |
4460 | | */ |
4461 | | typedef struct { |
4462 | | int32_t type; |
4463 | | char db[TSDB_DB_FNAME_LEN]; |
4464 | | int32_t payloadLen; |
4465 | | char* payload; |
4466 | | } SShowReq; |
4467 | | |
4468 | | int32_t tSerializeSShowReq(void* buf, int32_t bufLen, SShowReq* pReq); |
4469 | | // int32_t tDeserializeSShowReq(void* buf, int32_t bufLen, SShowReq* pReq); |
4470 | | void tFreeSShowReq(SShowReq* pReq); |
4471 | | |
4472 | | typedef struct { |
4473 | | int64_t showId; |
4474 | | STableMetaRsp tableMeta; |
4475 | | } SShowRsp, SVShowTablesRsp; |
4476 | | |
4477 | | // int32_t tSerializeSShowRsp(void* buf, int32_t bufLen, SShowRsp* pRsp); |
4478 | | // int32_t tDeserializeSShowRsp(void* buf, int32_t bufLen, SShowRsp* pRsp); |
4479 | | // void tFreeSShowRsp(SShowRsp* pRsp); |
4480 | | |
4481 | | typedef struct { |
4482 | | char db[TSDB_DB_FNAME_LEN]; |
4483 | | char tb[TSDB_TABLE_NAME_LEN]; |
4484 | | char user[TSDB_USER_LEN]; |
4485 | | char filterTb[TSDB_TABLE_NAME_LEN]; // for ins_columns |
4486 | | int64_t showId; |
4487 | | int64_t compactId; // for compact |
4488 | | int64_t txnId; // batch meta txn: same-txn visibility |
4489 | | bool withFull; // for show users full |
4490 | | int8_t xnodeDsnOutputMode; |
4491 | | int8_t xnodeRetrieveFilterType; |
4492 | | int64_t xnodeRetrieveFilterValue; |
4493 | | } SRetrieveTableReq; |
4494 | | |
4495 | | typedef enum { |
4496 | | XNODE_DSN_OUTPUT_DEFAULT = 0, |
4497 | | XNODE_DSN_OUTPUT_ENCRYPTED = 1, |
4498 | | } EXnodeDsnOutputMode; |
4499 | | |
4500 | | typedef enum { |
4501 | | XNODE_RETRIEVE_FILTER_NONE = 0, |
4502 | | XNODE_RETRIEVE_FILTER_ID_EQ = 1, |
4503 | | XNODE_RETRIEVE_FILTER_TASK_ID_EQ = 2, |
4504 | | } EXnodeRetrieveFilterType; |
4505 | | |
4506 | | typedef struct SSysTableSchema { |
4507 | | int8_t type; |
4508 | | col_id_t colId; |
4509 | | int32_t bytes; |
4510 | | } SSysTableSchema; |
4511 | | |
4512 | | int32_t tSerializeSRetrieveTableReq(void* buf, int32_t bufLen, SRetrieveTableReq* pReq); |
4513 | | int32_t tDeserializeSRetrieveTableReq(void* buf, int32_t bufLen, SRetrieveTableReq* pReq); |
4514 | | // Checks that the xnode retrieve options are consistent with the requested system table. |
4515 | | // Defined in common/src/systable.c, next to the schemas the rules are derived from. |
4516 | | int32_t tValidateSRetrieveTableReq(const SRetrieveTableReq* pReq); |
4517 | | |
4518 | | #define RETRIEVE_TABLE_RSP_VERSION 0 |
4519 | | #define RETRIEVE_TABLE_RSP_TMQ_VERSION 1 |
4520 | | #define RETRIEVE_TABLE_RSP_TMQ_RAW_VERSION 2 |
4521 | | |
4522 | | typedef struct { |
4523 | | int64_t useconds; |
4524 | | int8_t completed; // all results are returned to client |
4525 | | int8_t precision; |
4526 | | int8_t compressed; |
4527 | | int8_t streamBlockType; |
4528 | | int32_t payloadLen; |
4529 | | int32_t compLen; |
4530 | | int32_t numOfBlocks; |
4531 | | int64_t numOfRows; // from int32_t change to int64_t |
4532 | | int64_t numOfCols; |
4533 | | int64_t skey; |
4534 | | int64_t ekey; |
4535 | | int64_t version; // for stream |
4536 | | TSKEY watermark; // for stream |
4537 | | char parTbName[TSDB_TABLE_NAME_LEN]; // for stream |
4538 | | char data[]; |
4539 | | } SRetrieveTableRsp; |
4540 | | |
4541 | | #define PAYLOAD_PREFIX_LEN ((sizeof(int32_t)) << 1) |
4542 | | |
4543 | | #define SET_PAYLOAD_LEN(_p, _compLen, _fullLen) \ |
4544 | | do { \ |
4545 | | ((int32_t*)(_p))[0] = (_compLen); \ |
4546 | | ((int32_t*)(_p))[1] = (_fullLen); \ |
4547 | | } while (0); |
4548 | | |
4549 | | typedef struct { |
4550 | | int64_t version; |
4551 | | int64_t numOfRows; |
4552 | | int8_t compressed; |
4553 | | int8_t precision; |
4554 | | char data[]; |
4555 | | } SRetrieveTableRspForTmq; |
4556 | | |
4557 | | typedef struct { |
4558 | | int64_t handle; |
4559 | | int64_t useconds; |
4560 | | int8_t completed; // all results are returned to client |
4561 | | int8_t precision; |
4562 | | int8_t compressed; |
4563 | | int32_t compLen; |
4564 | | int32_t numOfRows; |
4565 | | int32_t fullLen; |
4566 | | char data[]; |
4567 | | } SRetrieveMetaTableRsp; |
4568 | | |
4569 | | typedef struct SExplainCorrelationStat { |
4570 | | int32_t templateId; |
4571 | | uint64_t inputRows; |
4572 | | uint64_t calls; |
4573 | | int64_t elapsedUs; |
4574 | | } SExplainCorrelationStat; |
4575 | | |
4576 | | typedef struct SExplainExecInfo { |
4577 | | /* the number of rows returned */ |
4578 | | uint64_t numOfRows; |
4579 | | uint32_t verboseLen; |
4580 | | void* verboseInfo; |
4581 | | |
4582 | | /* the timestamp when the operator is created */ |
4583 | | TSKEY execCreate; |
4584 | | /* the first timestamp when the operator's next interface is called */ |
4585 | | TSKEY execStart; |
4586 | | /* the timestamp when the first row is returned */ |
4587 | | TSKEY execFirstRow; |
4588 | | /* the timestamp when the last row is returned */ |
4589 | | TSKEY execLastRow; |
4590 | | /* the number of times the operator's next interface is called */ |
4591 | | uint32_t execTimes; |
4592 | | /** |
4593 | | the time elapsed for executing the operator's next interface, |
4594 | | not including waiting time for data from downstream |
4595 | | */ |
4596 | | TSKEY execElapsed; |
4597 | | /* the time elapsed for waiting for data from downstream */ |
4598 | | TSKEY inputWaitElapsed; |
4599 | | /* the time elapsed for waiting call from upstream */ |
4600 | | TSKEY outputWaitElapsed; |
4601 | | /* the number of rows input */ |
4602 | | uint64_t inputRows; |
4603 | | |
4604 | | int32_t vgId; |
4605 | | uint32_t correlationStatNum; |
4606 | | SExplainCorrelationStat* pCorrelationStats; |
4607 | | } SExplainExecInfo; |
4608 | | |
4609 | | typedef struct { |
4610 | | int32_t numOfPlans; |
4611 | | SExplainExecInfo* subplanInfo; |
4612 | | } SExplainRsp; |
4613 | | |
4614 | | typedef struct { |
4615 | | SExplainRsp rsp; |
4616 | | uint64_t qId; |
4617 | | uint64_t cId; |
4618 | | uint64_t tId; |
4619 | | int64_t rId; |
4620 | | int32_t eId; |
4621 | | } SExplainLocalRsp; |
4622 | | |
4623 | | typedef struct STableScanAnalyzeInfo { |
4624 | | int64_t totalBlocks; |
4625 | | int64_t fileLoadBlocks; |
4626 | | double fileLoadElapsed; |
4627 | | int64_t sttLoadBlocks; |
4628 | | double sttLoadElapsed; |
4629 | | int64_t memLoadBlocks; |
4630 | | double memLoadElapsed; |
4631 | | int64_t smaLoadBlocks; |
4632 | | double smaLoadElapsed; |
4633 | | int64_t composedBlocks; |
4634 | | double composedElapsed; |
4635 | | |
4636 | | uint64_t checkRows; |
4637 | | |
4638 | | uint64_t skipBlocks; |
4639 | | uint64_t filterOutBlocks; |
4640 | | double filterTime; |
4641 | | } STableScanAnalyzeInfo; |
4642 | | |
4643 | | int32_t tSerializeSExplainRsp(void* buf, int32_t bufLen, SExplainRsp* pRsp); |
4644 | | int32_t tDeserializeSExplainRsp(void* buf, int32_t bufLen, SExplainRsp* pRsp); |
4645 | | void tFreeSExplainRsp(SExplainRsp* pRsp); |
4646 | | |
4647 | | typedef struct { |
4648 | | char config[TSDB_DNODE_CONFIG_LEN]; |
4649 | | char value[TSDB_CLUSTER_VALUE_LEN]; |
4650 | | int32_t sqlLen; |
4651 | | char* sql; |
4652 | | } SMCfgClusterReq; |
4653 | | |
4654 | | int32_t tSerializeSMCfgClusterReq(void* buf, int32_t bufLen, SMCfgClusterReq* pReq); |
4655 | | int32_t tDeserializeSMCfgClusterReq(void* buf, int32_t bufLen, SMCfgClusterReq* pReq); |
4656 | | void tFreeSMCfgClusterReq(SMCfgClusterReq* pReq); |
4657 | | |
4658 | | typedef struct { |
4659 | | char fqdn[TSDB_FQDN_LEN]; // end point, hostname:port |
4660 | | int32_t port; |
4661 | | int32_t sqlLen; |
4662 | | char* sql; |
4663 | | } SCreateDnodeReq; |
4664 | | |
4665 | | int32_t tSerializeSCreateDnodeReq(void* buf, int32_t bufLen, SCreateDnodeReq* pReq); |
4666 | | int32_t tDeserializeSCreateDnodeReq(void* buf, int32_t bufLen, SCreateDnodeReq* pReq); |
4667 | | void tFreeSCreateDnodeReq(SCreateDnodeReq* pReq); |
4668 | | |
4669 | | typedef struct { |
4670 | | int32_t dnodeId; |
4671 | | char fqdn[TSDB_FQDN_LEN]; |
4672 | | int32_t port; |
4673 | | int8_t force; |
4674 | | int8_t unsafe; |
4675 | | int32_t sqlLen; |
4676 | | char* sql; |
4677 | | } SDropDnodeReq; |
4678 | | |
4679 | | int32_t tSerializeSDropDnodeReq(void* buf, int32_t bufLen, SDropDnodeReq* pReq); |
4680 | | int32_t tDeserializeSDropDnodeReq(void* buf, int32_t bufLen, SDropDnodeReq* pReq); |
4681 | | void tFreeSDropDnodeReq(SDropDnodeReq* pReq); |
4682 | | |
4683 | | enum { |
4684 | | RESTORE_TYPE__ALL = 1, |
4685 | | RESTORE_TYPE__MNODE, |
4686 | | RESTORE_TYPE__VNODE, |
4687 | | RESTORE_TYPE__QNODE, |
4688 | | }; |
4689 | | |
4690 | | typedef struct { |
4691 | | int32_t dnodeId; |
4692 | | int8_t restoreType; |
4693 | | int32_t sqlLen; |
4694 | | char* sql; |
4695 | | int32_t vgId; |
4696 | | // parallel: upper limit on the number of vnodes restored in parallel. 0 means no limit (backward compatible). |
4697 | | int32_t parallel; |
4698 | | } SRestoreDnodeReq; |
4699 | | |
4700 | | int32_t tSerializeSRestoreDnodeReq(void* buf, int32_t bufLen, SRestoreDnodeReq* pReq); |
4701 | | int32_t tDeserializeSRestoreDnodeReq(void* buf, int32_t bufLen, SRestoreDnodeReq* pReq); |
4702 | | void tFreeSRestoreDnodeReq(SRestoreDnodeReq* pReq); |
4703 | | |
4704 | | typedef struct { |
4705 | | int32_t dnodeId; |
4706 | | char config[TSDB_DNODE_CONFIG_LEN]; |
4707 | | char value[TSDB_DNODE_VALUE_LEN]; |
4708 | | int32_t sqlLen; |
4709 | | char* sql; |
4710 | | } SMCfgDnodeReq; |
4711 | | |
4712 | | int32_t tSerializeSMCfgDnodeReq(void* buf, int32_t bufLen, SMCfgDnodeReq* pReq); |
4713 | | int32_t tDeserializeSMCfgDnodeReq(void* buf, int32_t bufLen, SMCfgDnodeReq* pReq); |
4714 | | void tFreeSMCfgDnodeReq(SMCfgDnodeReq* pReq); |
4715 | | |
4716 | | typedef struct { |
4717 | | int8_t keyType; // 0: SVR_KEY, 1: DB_KEY |
4718 | | char newKey[ENCRYPT_KEY_LEN + 1]; |
4719 | | int32_t sqlLen; |
4720 | | char* sql; |
4721 | | } SMAlterEncryptKeyReq; |
4722 | | |
4723 | | int32_t tSerializeSMAlterEncryptKeyReq(void* buf, int32_t bufLen, SMAlterEncryptKeyReq* pReq); |
4724 | | int32_t tDeserializeSMAlterEncryptKeyReq(void* buf, int32_t bufLen, SMAlterEncryptKeyReq* pReq); |
4725 | | void tFreeSMAlterEncryptKeyReq(SMAlterEncryptKeyReq* pReq); |
4726 | | |
4727 | | typedef struct { |
4728 | | int32_t days; |
4729 | | char strategy[ENCRYPT_KEY_EXPIRE_STRATEGY_LEN + 1]; |
4730 | | int32_t sqlLen; |
4731 | | char* sql; |
4732 | | } SMAlterKeyExpirationReq; |
4733 | | |
4734 | | int32_t tSerializeSMAlterKeyExpirationReq(void* buf, int32_t bufLen, SMAlterKeyExpirationReq* pReq); |
4735 | | int32_t tDeserializeSMAlterKeyExpirationReq(void* buf, int32_t bufLen, SMAlterKeyExpirationReq* pReq); |
4736 | | void tFreeSMAlterKeyExpirationReq(SMAlterKeyExpirationReq* pReq); |
4737 | | |
4738 | | typedef struct { |
4739 | | char config[TSDB_DNODE_CONFIG_LEN]; |
4740 | | char value[TSDB_DNODE_VALUE_LEN]; |
4741 | | int32_t version; |
4742 | | } SDCfgDnodeReq; |
4743 | | |
4744 | | int32_t tSerializeSDCfgDnodeReq(void* buf, int32_t bufLen, SDCfgDnodeReq* pReq); |
4745 | | int32_t tDeserializeSDCfgDnodeReq(void* buf, int32_t bufLen, SDCfgDnodeReq* pReq); |
4746 | | |
4747 | | typedef struct { |
4748 | | int32_t dnodeId; |
4749 | | int32_t sqlLen; |
4750 | | char* sql; |
4751 | | } SMCreateMnodeReq, SMDropMnodeReq, SDDropMnodeReq, SMCreateQnodeReq, SMDropQnodeReq, SDCreateQnodeReq, SDDropQnodeReq, |
4752 | | SMCreateSnodeReq, SMDropSnodeReq, SDDropSnodeReq; |
4753 | | |
4754 | | int32_t tSerializeSCreateDropMQSNodeReq(void* buf, int32_t bufLen, SMCreateQnodeReq* pReq); |
4755 | | int32_t tDeserializeSCreateDropMQSNodeReq(void* buf, int32_t bufLen, SMCreateQnodeReq* pReq); |
4756 | | |
4757 | | typedef struct { |
4758 | | int32_t nodeId; |
4759 | | SEpSet epSet; |
4760 | | } SNodeEpSet; |
4761 | | |
4762 | | typedef struct { |
4763 | | int32_t snodeId; |
4764 | | SNodeEpSet leaders[2]; |
4765 | | SNodeEpSet replica; |
4766 | | int32_t sqlLen; |
4767 | | char* sql; |
4768 | | } SDCreateSnodeReq; |
4769 | | |
4770 | | int32_t tSerializeSDCreateSNodeReq(void* buf, int32_t bufLen, SDCreateSnodeReq* pReq); |
4771 | | int32_t tDeserializeSDCreateSNodeReq(void* buf, int32_t bufLen, SDCreateSnodeReq* pReq); |
4772 | | void tFreeSDCreateSnodeReq(SDCreateSnodeReq* pReq); |
4773 | | |
4774 | | void tFreeSMCreateQnodeReq(SMCreateQnodeReq* pReq); |
4775 | | void tFreeSDDropQnodeReq(SDDropQnodeReq* pReq); |
4776 | | typedef struct { |
4777 | | int8_t replica; |
4778 | | SReplica replicas[TSDB_MAX_REPLICA]; |
4779 | | int8_t learnerReplica; |
4780 | | SReplica learnerReplicas[TSDB_MAX_LEARNER_REPLICA]; |
4781 | | int64_t lastIndex; |
4782 | | int8_t encrypted; // Whether sdb.data is encrypted (0=false, 1=true) |
4783 | | } SDCreateMnodeReq, SDAlterMnodeReq, SDAlterMnodeTypeReq; |
4784 | | |
4785 | | int32_t tSerializeSDCreateMnodeReq(void* buf, int32_t bufLen, SDCreateMnodeReq* pReq); |
4786 | | int32_t tDeserializeSDCreateMnodeReq(void* buf, int32_t bufLen, SDCreateMnodeReq* pReq); |
4787 | | |
4788 | | typedef struct { |
4789 | | int32_t urlLen; |
4790 | | int32_t sqlLen; |
4791 | | char* url; |
4792 | | char* sql; |
4793 | | } SMCreateAnodeReq; |
4794 | | |
4795 | | int32_t tSerializeSMCreateAnodeReq(void* buf, int32_t bufLen, SMCreateAnodeReq* pReq); |
4796 | | int32_t tDeserializeSMCreateAnodeReq(void* buf, int32_t bufLen, SMCreateAnodeReq* pReq); |
4797 | | void tFreeSMCreateAnodeReq(SMCreateAnodeReq* pReq); |
4798 | | |
4799 | | typedef struct { |
4800 | | int32_t anodeId; |
4801 | | int32_t sqlLen; |
4802 | | char* sql; |
4803 | | } SMDropAnodeReq, SMUpdateAnodeReq; |
4804 | | |
4805 | | int32_t tSerializeSMDropAnodeReq(void* buf, int32_t bufLen, SMDropAnodeReq* pReq); |
4806 | | int32_t tDeserializeSMDropAnodeReq(void* buf, int32_t bufLen, SMDropAnodeReq* pReq); |
4807 | | void tFreeSMDropAnodeReq(SMDropAnodeReq* pReq); |
4808 | | int32_t tSerializeSMUpdateAnodeReq(void* buf, int32_t bufLen, SMUpdateAnodeReq* pReq); |
4809 | | int32_t tDeserializeSMUpdateAnodeReq(void* buf, int32_t bufLen, SMUpdateAnodeReq* pReq); |
4810 | | void tFreeSMUpdateAnodeReq(SMUpdateAnodeReq* pReq); |
4811 | | |
4812 | | typedef struct { |
4813 | | int32_t dnodeId; |
4814 | | int32_t bnodeProto; |
4815 | | int32_t sqlLen; |
4816 | | char* sql; |
4817 | | } SMCreateBnodeReq, SDCreateBnodeReq; |
4818 | | |
4819 | | int32_t tSerializeSMCreateBnodeReq(void* buf, int32_t bufLen, SMCreateBnodeReq* pReq); |
4820 | | int32_t tDeserializeSMCreateBnodeReq(void* buf, int32_t bufLen, SMCreateBnodeReq* pReq); |
4821 | | void tFreeSMCreateBnodeReq(SMCreateBnodeReq* pReq); |
4822 | | |
4823 | | typedef struct { |
4824 | | int32_t dnodeId; |
4825 | | int32_t sqlLen; |
4826 | | char* sql; |
4827 | | } SMDropBnodeReq, SDDropBnodeReq; |
4828 | | |
4829 | | int32_t tSerializeSMDropBnodeReq(void* buf, int32_t bufLen, SMDropBnodeReq* pReq); |
4830 | | int32_t tDeserializeSMDropBnodeReq(void* buf, int32_t bufLen, SMDropBnodeReq* pReq); |
4831 | | void tFreeSMDropBnodeReq(SMDropBnodeReq* pReq); |
4832 | | |
4833 | | typedef struct { |
4834 | | bool shouldFree; |
4835 | | int32_t len; |
4836 | | const char* ptr; |
4837 | | } CowStr; |
4838 | | /** |
4839 | | * @brief Create a CowStr object. |
4840 | | * |
4841 | | * @param len: length of the string. |
4842 | | * @param ptr: pointer to the string input. |
4843 | | * @param shouldClone: whether to clone the string. |
4844 | | * @return CowStr object. |
4845 | | */ |
4846 | | CowStr xCreateCowStr(int32_t len, const char* ptr, bool shouldClone); |
4847 | | /** |
4848 | | * @brief Set a CowStr object with given string. |
4849 | | * |
4850 | | * @param cow: pointer to the CowStr object. |
4851 | | * @param len: length of the string. |
4852 | | * @param ptr: pointer to the string input. |
4853 | | * @param shouldFree: whether to free the string. |
4854 | | */ |
4855 | | void xSetCowStr(CowStr* cow, int32_t len, const char* ptr, bool shouldFree); |
4856 | | /** |
4857 | | * @brief Clone a CowStr object without copy the string. |
4858 | | * |
4859 | | * @param cow: pointer to the CowStr object. |
4860 | | * @return CowStr object. |
4861 | | */ |
4862 | | CowStr xCloneRefCowStr(CowStr* cow); |
4863 | | /** |
4864 | | * @brief Convert a CowStr object to a string. |
4865 | | * |
4866 | | * @param cow: pointer to the CowStr object. |
4867 | | */ |
4868 | | char* xCowStrToStr(CowStr* cow); |
4869 | | /** |
4870 | | * @brief Deallocate a CowStr object. Clears the string and resets length to 0. |
4871 | | * |
4872 | | * @param cow: pointer to the CowStr object. |
4873 | | */ |
4874 | | void xFreeCowStr(CowStr* cow); |
4875 | | /** |
4876 | | * @brief Encode and push a CowStr object into the encoder. |
4877 | | * |
4878 | | * @param encoder |
4879 | | * @param cow |
4880 | | * @return int32_t |
4881 | | */ |
4882 | | int32_t xEncodeCowStr(SEncoder* encoder, CowStr* cow); |
4883 | | /** |
4884 | | * @brief Decode a CowStr from the encoder. |
4885 | | * |
4886 | | * @param decoder |
4887 | | * @param cow |
4888 | | * @param shouldClone |
4889 | | * @return int32_t |
4890 | | */ |
4891 | | int32_t xDecodeCowStr(SDecoder* decoder, CowStr* cow, bool shouldClone); |
4892 | | |
4893 | | typedef struct { |
4894 | | int32_t sqlLen; |
4895 | | int32_t urlLen; |
4896 | | int32_t userLen; |
4897 | | int32_t passLen; |
4898 | | int32_t passIsMd5; |
4899 | | char* sql; |
4900 | | char* url; |
4901 | | char* user; |
4902 | | char* pass; |
4903 | | CowStr token; |
4904 | | } SMCreateXnodeReq, SDCreateXnodeReq; |
4905 | | |
4906 | | int32_t tSerializeSMCreateXnodeReq(void* buf, int32_t bufLen, SMCreateXnodeReq* pReq); |
4907 | | int32_t tDeserializeSMCreateXnodeReq(void* buf, int32_t bufLen, SMCreateXnodeReq* pReq); |
4908 | | void tFreeSMCreateXnodeReq(SMCreateXnodeReq* pReq); |
4909 | | |
4910 | | typedef struct { |
4911 | | int32_t xnodeId; |
4912 | | int32_t force; |
4913 | | int32_t urlLen; |
4914 | | int32_t sqlLen; |
4915 | | char* url; |
4916 | | char* sql; |
4917 | | } SMDropXnodeReq, SDDropXnodeReq; |
4918 | | |
4919 | | int32_t tSerializeSMDropXnodeReq(void* buf, int32_t bufLen, SMDropXnodeReq* pReq); |
4920 | | int32_t tDeserializeSMDropXnodeReq(void* buf, int32_t bufLen, SMDropXnodeReq* pReq); |
4921 | | void tFreeSMDropXnodeReq(SMDropXnodeReq* pReq); |
4922 | | |
4923 | | typedef struct { |
4924 | | int32_t id; |
4925 | | CowStr token; |
4926 | | CowStr user; |
4927 | | CowStr pass; |
4928 | | int32_t urlLen; |
4929 | | int32_t sqlLen; |
4930 | | char* url; |
4931 | | char* sql; |
4932 | | } SMUpdateXnodeReq; |
4933 | | int32_t tSerializeSMUpdateXnodeReq(void* buf, int32_t bufLen, SMUpdateXnodeReq* pReq); |
4934 | | int32_t tDeserializeSMUpdateXnodeReq(void* buf, int32_t bufLen, SMUpdateXnodeReq* pReq); |
4935 | | void tFreeSMUpdateXnodeReq(SMUpdateXnodeReq* pReq); |
4936 | | |
4937 | | typedef struct { |
4938 | | int32_t xnodeId; |
4939 | | int32_t sqlLen; |
4940 | | char* sql; |
4941 | | } SMDrainXnodeReq; |
4942 | | int32_t tSerializeSMDrainXnodeReq(void* buf, int32_t bufLen, SMDrainXnodeReq* pReq); |
4943 | | int32_t tDeserializeSMDrainXnodeReq(void* buf, int32_t bufLen, SMDrainXnodeReq* pReq); |
4944 | | void tFreeSMDrainXnodeReq(SMDrainXnodeReq* pReq); |
4945 | | |
4946 | | typedef struct { |
4947 | | int32_t sqlLen; |
4948 | | char* sql; |
4949 | | } SMRestartXnodeReq; |
4950 | | int32_t tSerializeSMRestartXnodeReq(void* buf, int32_t bufLen, SMRestartXnodeReq* pReq); |
4951 | | int32_t tDeserializeSMRestartXnodeReq(void* buf, int32_t bufLen, SMRestartXnodeReq* pReq); |
4952 | | void tFreeSMRestartXnodeReq(SMRestartXnodeReq* pReq); |
4953 | | |
4954 | | typedef enum { |
4955 | | XNODE_TASK_SOURCE_DSN = 1, |
4956 | | XNODE_TASK_SOURCE_DATABASE, |
4957 | | XNODE_TASK_SOURCE_TOPIC, |
4958 | | } ENodeXTaskSourceType; |
4959 | | |
4960 | | typedef enum { |
4961 | | XNODE_TASK_SINK_DSN = 1, |
4962 | | XNODE_TASK_SINK_DATABASE, |
4963 | | } ENodeXTaskSinkType; |
4964 | | |
4965 | | typedef struct { |
4966 | | ENodeXTaskSourceType type; |
4967 | | CowStr cstr; |
4968 | | } xTaskSource; |
4969 | | /** |
4970 | | * @brief Deallocate a xTaskSource object. |
4971 | | * |
4972 | | * @param source ptr |
4973 | | */ |
4974 | | void xFreeTaskSource(xTaskSource* source); |
4975 | | /** |
4976 | | * @brief Create a xTaskSource object with cloned source string. |
4977 | | * |
4978 | | * @param sourceType: source type. |
4979 | | * @param len: length of source string. |
4980 | | * @param source: source string ptr. |
4981 | | * @return xTaskSource object |
4982 | | */ |
4983 | | xTaskSource xCreateClonedTaskSource(ENodeXTaskSourceType sourceType, int32_t len, char* ptr); |
4984 | | xTaskSource xCloneTaskSourceRef(xTaskSource* source); |
4985 | | xTaskSource xCreateTaskSource(ENodeXTaskSourceType sourceType, int32_t len, char* ptr); |
4986 | | const char* xGetTaskSourceTypeAsStr(xTaskSource* source); |
4987 | | const char* xGetTaskSourceStr(xTaskSource* source); |
4988 | | int32_t xSerializeTaskSource(SEncoder* encoder, xTaskSource* source); |
4989 | | int32_t xDeserializeTaskSource(SDecoder* decoder, xTaskSource* source); |
4990 | | |
4991 | | typedef struct { |
4992 | | ENodeXTaskSinkType type; |
4993 | | CowStr cstr; |
4994 | | } xTaskSink; |
4995 | | /** |
4996 | | * @brief Deallocate a xTaskSink object. |
4997 | | * |
4998 | | * @param sink ptr |
4999 | | */ |
5000 | | void xFreeTaskSink(xTaskSink* sink); |
5001 | | /** |
5002 | | * @brief Create a xTaskSink object with cloned name string. |
5003 | | * |
5004 | | * @param sinkType: sink type. |
5005 | | * @param len: length of sink string. |
5006 | | * @param ptr: sink string ptr. |
5007 | | * @return xTaskSink object |
5008 | | */ |
5009 | | xTaskSink xCreateClonedTaskSink(ENodeXTaskSinkType sinkType, int32_t len, char* ptr); |
5010 | | xTaskSink xCreateTaskSink(ENodeXTaskSinkType sinkType, int32_t len, char* ptr); |
5011 | | xTaskSink xCloneTaskSinkRef(xTaskSink* sink); |
5012 | | const char* xGetTaskSinkTypeAsStr(xTaskSink* sink); |
5013 | | const char* xGetTaskSinkStr(xTaskSink* sink); |
5014 | | int32_t xSerializeTaskSink(SEncoder* encoder, xTaskSink* sink); |
5015 | | int32_t xDeserializeTaskSink(SDecoder* decoder, xTaskSink* sink); |
5016 | | |
5017 | | typedef struct { |
5018 | | int32_t via; |
5019 | | CowStr parser; |
5020 | | // CowStr reason; |
5021 | | CowStr trigger; |
5022 | | CowStr health; |
5023 | | int32_t optionsNum; |
5024 | | CowStr options[TSDB_XNODE_TASK_OPTIONS_MAX_NUM]; |
5025 | | } xTaskOptions; |
5026 | | /** |
5027 | | * @brief Deallocate a xTaskOptions object. |
5028 | | * |
5029 | | * @param options ptr |
5030 | | */ |
5031 | | void xFreeTaskOptions(xTaskOptions* options); |
5032 | | void printXnodeTaskOptions(xTaskOptions* options); |
5033 | | int32_t xSerializeTaskOptions(SEncoder* encoder, xTaskOptions* options); |
5034 | | int32_t xDeserializeTaskOptions(SDecoder* decoder, xTaskOptions* options); |
5035 | | |
5036 | | typedef struct { |
5037 | | int32_t sqlLen; |
5038 | | char* sql; |
5039 | | int32_t xnodeId; |
5040 | | CowStr name; |
5041 | | xTaskSource source; |
5042 | | xTaskSink sink; |
5043 | | xTaskOptions options; |
5044 | | CowStr desiredState; |
5045 | | } SMCreateXnodeTaskReq; |
5046 | | int32_t tSerializeSMCreateXnodeTaskReq(void* buf, int32_t bufLen, SMCreateXnodeTaskReq* pReq); |
5047 | | int32_t tDeserializeSMCreateXnodeTaskReq(void* buf, int32_t bufLen, SMCreateXnodeTaskReq* pReq); |
5048 | | void tFreeSMCreateXnodeTaskReq(SMCreateXnodeTaskReq* pReq); |
5049 | | |
5050 | | typedef struct { |
5051 | | int32_t tid; |
5052 | | CowStr name; |
5053 | | int32_t via; |
5054 | | int32_t xnodeId; |
5055 | | CowStr status; |
5056 | | xTaskSource source; |
5057 | | xTaskSink sink; |
5058 | | CowStr parser; |
5059 | | CowStr reason; |
5060 | | CowStr desiredState; |
5061 | | CowStr updateName; |
5062 | | CowStr labels; |
5063 | | int32_t sqlLen; |
5064 | | char* sql; |
5065 | | } SMUpdateXnodeTaskReq; |
5066 | | int32_t tSerializeSMUpdateXnodeTaskReq(void* buf, int32_t bufLen, SMUpdateXnodeTaskReq* pReq); |
5067 | | int32_t tDeserializeSMUpdateXnodeTaskReq(void* buf, int32_t bufLen, SMUpdateXnodeTaskReq* pReq); |
5068 | | void tFreeSMUpdateXnodeTaskReq(SMUpdateXnodeTaskReq* pReq); |
5069 | | |
5070 | | typedef struct { |
5071 | | int32_t id; |
5072 | | bool force; |
5073 | | CowStr name; |
5074 | | int32_t sqlLen; |
5075 | | char* sql; |
5076 | | } SMDropXnodeTaskReq; |
5077 | | int32_t tSerializeSMDropXnodeTaskReq(void* buf, int32_t bufLen, SMDropXnodeTaskReq* pReq); |
5078 | | int32_t tDeserializeSMDropXnodeTaskReq(void* buf, int32_t bufLen, SMDropXnodeTaskReq* pReq); |
5079 | | void tFreeSMDropXnodeTaskReq(SMDropXnodeTaskReq* pReq); |
5080 | | |
5081 | | typedef struct { |
5082 | | int32_t tid; |
5083 | | CowStr name; |
5084 | | int32_t sqlLen; |
5085 | | char* sql; |
5086 | | } SMStartXnodeTaskReq, SMStopXnodeTaskReq; |
5087 | | int32_t tSerializeSMStartXnodeTaskReq(void* buf, int32_t bufLen, SMStartXnodeTaskReq* pReq); |
5088 | | int32_t tDeserializeSMStartXnodeTaskReq(void* buf, int32_t bufLen, SMStartXnodeTaskReq* pReq); |
5089 | | void tFreeSMStartXnodeTaskReq(SMStartXnodeTaskReq* pReq); |
5090 | | |
5091 | | int32_t tSerializeSMStopXnodeTaskReq(void* buf, int32_t bufLen, SMStopXnodeTaskReq* pReq); |
5092 | | int32_t tDeserializeSMStopXnodeTaskReq(void* buf, int32_t bufLen, SMStopXnodeTaskReq* pReq); |
5093 | | void tFreeSMStopXnodeTaskReq(SMStopXnodeTaskReq* pReq); |
5094 | | |
5095 | | typedef struct { |
5096 | | int32_t tid; |
5097 | | int32_t via; |
5098 | | int32_t xnodeId; |
5099 | | CowStr status; |
5100 | | CowStr desiredState; |
5101 | | CowStr config; |
5102 | | CowStr reason; |
5103 | | int32_t sqlLen; |
5104 | | char* sql; |
5105 | | } SMCreateXnodeJobReq; |
5106 | | int32_t tSerializeSMCreateXnodeJobReq(void* buf, int32_t bufLen, SMCreateXnodeJobReq* pReq); |
5107 | | int32_t tDeserializeSMCreateXnodeJobReq(void* buf, int32_t bufLen, SMCreateXnodeJobReq* pReq); |
5108 | | void tFreeSMCreateXnodeJobReq(SMCreateXnodeJobReq* pReq); |
5109 | | |
5110 | | typedef struct { |
5111 | | int32_t jid; |
5112 | | int32_t via; |
5113 | | int32_t xnodeId; |
5114 | | CowStr status; |
5115 | | CowStr desiredState; |
5116 | | int32_t configLen; |
5117 | | int32_t reasonLen; |
5118 | | int32_t sqlLen; |
5119 | | char* config; |
5120 | | char* reason; |
5121 | | char* sql; |
5122 | | } SMUpdateXnodeJobReq; |
5123 | | int32_t tSerializeSMUpdateXnodeJobReq(void* buf, int32_t bufLen, SMUpdateXnodeJobReq* pReq); |
5124 | | int32_t tDeserializeSMUpdateXnodeJobReq(void* buf, int32_t bufLen, SMUpdateXnodeJobReq* pReq); |
5125 | | void tFreeSMUpdateXnodeJobReq(SMUpdateXnodeJobReq* pReq); |
5126 | | |
5127 | | typedef struct { |
5128 | | int32_t jid; |
5129 | | int32_t xnodeId; |
5130 | | int32_t sqlLen; |
5131 | | char* sql; |
5132 | | } SMRebalanceXnodeJobReq; |
5133 | | int32_t tSerializeSMRebalanceXnodeJobReq(void* buf, int32_t bufLen, SMRebalanceXnodeJobReq* pReq); |
5134 | | int32_t tDeserializeSMRebalanceXnodeJobReq(void* buf, int32_t bufLen, SMRebalanceXnodeJobReq* pReq); |
5135 | | void tFreeSMRebalanceXnodeJobReq(SMRebalanceXnodeJobReq* pReq); |
5136 | | |
5137 | | typedef struct { |
5138 | | CowStr ast; |
5139 | | int32_t sqlLen; |
5140 | | char* sql; |
5141 | | } SMRebalanceXnodeJobsWhereReq; |
5142 | | int32_t tSerializeSMRebalanceXnodeJobsWhereReq(void* buf, int32_t bufLen, SMRebalanceXnodeJobsWhereReq* pReq); |
5143 | | int32_t tDeserializeSMRebalanceXnodeJobsWhereReq(void* buf, int32_t bufLen, SMRebalanceXnodeJobsWhereReq* pReq); |
5144 | | void tFreeSMRebalanceXnodeJobsWhereReq(SMRebalanceXnodeJobsWhereReq* pReq); |
5145 | | |
5146 | | typedef struct { |
5147 | | int32_t jid; |
5148 | | CowStr ast; |
5149 | | int32_t sqlLen; |
5150 | | char* sql; |
5151 | | } SMDropXnodeJobReq; |
5152 | | int32_t tSerializeSMDropXnodeJobReq(void* buf, int32_t bufLen, SMDropXnodeJobReq* pReq); |
5153 | | int32_t tDeserializeSMDropXnodeJobReq(void* buf, int32_t bufLen, SMDropXnodeJobReq* pReq); |
5154 | | void tFreeSMDropXnodeJobReq(SMDropXnodeJobReq* pReq); |
5155 | | |
5156 | | typedef struct { |
5157 | | int32_t sqlLen; |
5158 | | char* sql; |
5159 | | CowStr name; |
5160 | | CowStr status; |
5161 | | xTaskOptions options; |
5162 | | } SMCreateXnodeAgentReq; |
5163 | | int32_t tSerializeSMCreateXnodeAgentReq(void* buf, int32_t bufLen, SMCreateXnodeAgentReq* pReq); |
5164 | | int32_t tDeserializeSMCreateXnodeAgentReq(void* buf, int32_t bufLen, SMCreateXnodeAgentReq* pReq); |
5165 | | void tFreeSMCreateXnodeAgentReq(SMCreateXnodeAgentReq* pReq); |
5166 | | |
5167 | | typedef struct { |
5168 | | int32_t sqlLen; |
5169 | | char* sql; |
5170 | | int32_t id; |
5171 | | CowStr name; |
5172 | | xTaskOptions options; |
5173 | | } SMUpdateXnodeAgentReq; |
5174 | | int32_t tSerializeSMUpdateXnodeAgentReq(void* buf, int32_t bufLen, SMUpdateXnodeAgentReq* pReq); |
5175 | | int32_t tDeserializeSMUpdateXnodeAgentReq(void* buf, int32_t bufLen, SMUpdateXnodeAgentReq* pReq); |
5176 | | void tFreeSMUpdateXnodeAgentReq(SMUpdateXnodeAgentReq* pReq); |
5177 | | |
5178 | | typedef SMDropXnodeTaskReq SMDropXnodeAgentReq; |
5179 | | int32_t tSerializeSMDropXnodeAgentReq(void* buf, int32_t bufLen, SMDropXnodeAgentReq* pReq); |
5180 | | int32_t tDeserializeSMDropXnodeAgentReq(void* buf, int32_t bufLen, SMDropXnodeAgentReq* pReq); |
5181 | | void tFreeSMDropXnodeAgentReq(SMDropXnodeAgentReq* pReq); |
5182 | | |
5183 | | typedef struct { |
5184 | | int32_t vgId; |
5185 | | int32_t hbSeq; |
5186 | | } SVArbHbReqMember; |
5187 | | |
5188 | | typedef struct { |
5189 | | int32_t dnodeId; |
5190 | | char* arbToken; |
5191 | | int64_t arbTerm; |
5192 | | SArray* hbMembers; // SVArbHbReqMember |
5193 | | } SVArbHeartBeatReq; |
5194 | | |
5195 | | int32_t tSerializeSVArbHeartBeatReq(void* buf, int32_t bufLen, SVArbHeartBeatReq* pReq); |
5196 | | int32_t tDeserializeSVArbHeartBeatReq(void* buf, int32_t bufLen, SVArbHeartBeatReq* pReq); |
5197 | | void tFreeSVArbHeartBeatReq(SVArbHeartBeatReq* pReq); |
5198 | | |
5199 | | typedef struct { |
5200 | | int32_t vgId; |
5201 | | char memberToken[TSDB_ARB_TOKEN_SIZE]; |
5202 | | int32_t hbSeq; |
5203 | | } SVArbHbRspMember; |
5204 | | |
5205 | | typedef struct { |
5206 | | char arbToken[TSDB_ARB_TOKEN_SIZE]; |
5207 | | int32_t dnodeId; |
5208 | | SArray* hbMembers; // SVArbHbRspMember |
5209 | | } SVArbHeartBeatRsp; |
5210 | | |
5211 | | int32_t tSerializeSVArbHeartBeatRsp(void* buf, int32_t bufLen, SVArbHeartBeatRsp* pRsp); |
5212 | | int32_t tDeserializeSVArbHeartBeatRsp(void* buf, int32_t bufLen, SVArbHeartBeatRsp* pRsp); |
5213 | | void tFreeSVArbHeartBeatRsp(SVArbHeartBeatRsp* pRsp); |
5214 | | |
5215 | | typedef struct { |
5216 | | char* arbToken; |
5217 | | int64_t arbTerm; |
5218 | | char* member0Token; |
5219 | | char* member1Token; |
5220 | | } SVArbCheckSyncReq; |
5221 | | |
5222 | | int32_t tSerializeSVArbCheckSyncReq(void* buf, int32_t bufLen, SVArbCheckSyncReq* pReq); |
5223 | | int32_t tDeserializeSVArbCheckSyncReq(void* buf, int32_t bufLen, SVArbCheckSyncReq* pReq); |
5224 | | void tFreeSVArbCheckSyncReq(SVArbCheckSyncReq* pRsp); |
5225 | | |
5226 | | typedef struct { |
5227 | | char* arbToken; |
5228 | | char* member0Token; |
5229 | | char* member1Token; |
5230 | | int32_t vgId; |
5231 | | int32_t errCode; |
5232 | | } SVArbCheckSyncRsp; |
5233 | | |
5234 | | int32_t tSerializeSVArbCheckSyncRsp(void* buf, int32_t bufLen, SVArbCheckSyncRsp* pRsp); |
5235 | | int32_t tDeserializeSVArbCheckSyncRsp(void* buf, int32_t bufLen, SVArbCheckSyncRsp* pRsp); |
5236 | | void tFreeSVArbCheckSyncRsp(SVArbCheckSyncRsp* pRsp); |
5237 | | |
5238 | | typedef struct { |
5239 | | char* arbToken; |
5240 | | int64_t arbTerm; |
5241 | | char* memberToken; |
5242 | | int8_t force; |
5243 | | } SVArbSetAssignedLeaderReq; |
5244 | | |
5245 | | int32_t tSerializeSVArbSetAssignedLeaderReq(void* buf, int32_t bufLen, SVArbSetAssignedLeaderReq* pReq); |
5246 | | int32_t tDeserializeSVArbSetAssignedLeaderReq(void* buf, int32_t bufLen, SVArbSetAssignedLeaderReq* pReq); |
5247 | | void tFreeSVArbSetAssignedLeaderReq(SVArbSetAssignedLeaderReq* pReq); |
5248 | | |
5249 | | typedef struct { |
5250 | | char* data; |
5251 | | } SVAuditRecordReq; |
5252 | | int32_t tSerializeSVAuditRecordReq(void* buf, int32_t bufLen, SVAuditRecordReq* pReq); |
5253 | | int32_t tDeserializeSVAuditRecordReq(void* buf, int32_t bufLen, SVAuditRecordReq* pReq); |
5254 | | void tFreeSVAuditRecordReq(SVAuditRecordReq* pReq); |
5255 | | |
5256 | | typedef struct { |
5257 | | char* arbToken; |
5258 | | char* memberToken; |
5259 | | int32_t vgId; |
5260 | | } SVArbSetAssignedLeaderRsp; |
5261 | | |
5262 | | int32_t tSerializeSVArbSetAssignedLeaderRsp(void* buf, int32_t bufLen, SVArbSetAssignedLeaderRsp* pRsp); |
5263 | | int32_t tDeserializeSVArbSetAssignedLeaderRsp(void* buf, int32_t bufLen, SVArbSetAssignedLeaderRsp* pRsp); |
5264 | | void tFreeSVArbSetAssignedLeaderRsp(SVArbSetAssignedLeaderRsp* pRsp); |
5265 | | |
5266 | | typedef struct { |
5267 | | int32_t dnodeId; |
5268 | | char* token; |
5269 | | } SMArbUpdateGroupMember; |
5270 | | |
5271 | | typedef struct { |
5272 | | int32_t dnodeId; |
5273 | | char* token; |
5274 | | int8_t acked; |
5275 | | } SMArbUpdateGroupAssigned; |
5276 | | |
5277 | | typedef struct { |
5278 | | int32_t vgId; |
5279 | | int64_t dbUid; |
5280 | | SMArbUpdateGroupMember members[2]; |
5281 | | int8_t isSync; |
5282 | | int8_t assignedAcked; |
5283 | | SMArbUpdateGroupAssigned assignedLeader; |
5284 | | int64_t version; |
5285 | | int32_t code; |
5286 | | int64_t updateTimeMs; |
5287 | | } SMArbUpdateGroup; |
5288 | | |
5289 | | typedef struct { |
5290 | | SArray* updateArray; // SMArbUpdateGroup |
5291 | | } SMArbUpdateGroupBatchReq; |
5292 | | |
5293 | | int32_t tSerializeSMArbUpdateGroupBatchReq(void* buf, int32_t bufLen, SMArbUpdateGroupBatchReq* pReq); |
5294 | | int32_t tDeserializeSMArbUpdateGroupBatchReq(void* buf, int32_t bufLen, SMArbUpdateGroupBatchReq* pReq); |
5295 | | void tFreeSMArbUpdateGroupBatchReq(SMArbUpdateGroupBatchReq* pReq); |
5296 | | |
5297 | | typedef struct { |
5298 | | char queryStrId[TSDB_QUERY_ID_LEN]; |
5299 | | } SKillQueryReq; |
5300 | | |
5301 | | int32_t tSerializeSKillQueryReq(void* buf, int32_t bufLen, SKillQueryReq* pReq); |
5302 | | int32_t tDeserializeSKillQueryReq(void* buf, int32_t bufLen, SKillQueryReq* pReq); |
5303 | | |
5304 | | typedef struct { |
5305 | | uint32_t connId; |
5306 | | } SKillConnReq; |
5307 | | |
5308 | | int32_t tSerializeSKillConnReq(void* buf, int32_t bufLen, SKillConnReq* pReq); |
5309 | | int32_t tDeserializeSKillConnReq(void* buf, int32_t bufLen, SKillConnReq* pReq); |
5310 | | |
5311 | | typedef struct { |
5312 | | int64_t transId; |
5313 | | } SKillTransReq; |
5314 | | |
5315 | | int32_t tSerializeSKillTransReq(void* buf, int32_t bufLen, SKillTransReq* pReq); |
5316 | | int32_t tDeserializeSKillTransReq(void* buf, int32_t bufLen, SKillTransReq* pReq); |
5317 | | |
5318 | | // Distributed transaction: BEGIN / COMMIT / ROLLBACK |
5319 | | typedef struct { |
5320 | | int32_t useless; // placeholder |
5321 | | int32_t sqlLen; |
5322 | | char* sql; |
5323 | | } SBeginTransReq; |
5324 | | |
5325 | | int32_t tSerializeSBeginTransReq(void* buf, int32_t bufLen, SBeginTransReq* pReq); |
5326 | | int32_t tDeserializeSBeginTransReq(void* buf, int32_t bufLen, SBeginTransReq* pReq); |
5327 | | void tFreeSBeginTransReq(SBeginTransReq* pReq); |
5328 | | |
5329 | | typedef struct { |
5330 | | int32_t useless; // placeholder |
5331 | | int32_t sqlLen; |
5332 | | char* sql; |
5333 | | } SCommitTransReq; |
5334 | | |
5335 | | int32_t tSerializeSCommitTransReq(void* buf, int32_t bufLen, SCommitTransReq* pReq); |
5336 | | int32_t tDeserializeSCommitTransReq(void* buf, int32_t bufLen, SCommitTransReq* pReq); |
5337 | | void tFreeSCommitTransReq(SCommitTransReq* pReq); |
5338 | | |
5339 | | typedef struct { |
5340 | | int32_t useless; // placeholder |
5341 | | int32_t sqlLen; |
5342 | | char* sql; |
5343 | | } SRollbackTransReq; |
5344 | | |
5345 | | int32_t tSerializeSRollbackTransReq(void* buf, int32_t bufLen, SRollbackTransReq* pReq); |
5346 | | int32_t tDeserializeSRollbackTransReq(void* buf, int32_t bufLen, SRollbackTransReq* pReq); |
5347 | | void tFreeSRollbackTransReq(SRollbackTransReq* pReq); |
5348 | | |
5349 | | typedef struct { |
5350 | | int32_t useless; // useless |
5351 | | int32_t sqlLen; |
5352 | | char* sql; |
5353 | | } SBalanceVgroupReq; |
5354 | | |
5355 | | int32_t tSerializeSBalanceVgroupReq(void* buf, int32_t bufLen, SBalanceVgroupReq* pReq); |
5356 | | int32_t tDeserializeSBalanceVgroupReq(void* buf, int32_t bufLen, SBalanceVgroupReq* pReq); |
5357 | | void tFreeSBalanceVgroupReq(SBalanceVgroupReq* pReq); |
5358 | | |
5359 | | typedef struct { |
5360 | | int32_t useless; // reserved; empty request |
5361 | | } SFlushMnodeReq; |
5362 | | |
5363 | | int32_t tSerializeSFlushMnodeReq(void* buf, int32_t bufLen, SFlushMnodeReq* pReq); |
5364 | | int32_t tDeserializeSFlushMnodeReq(void* buf, int32_t bufLen, SFlushMnodeReq* pReq); |
5365 | | void tFreeSFlushMnodeReq(SFlushMnodeReq* pReq); |
5366 | | |
5367 | | typedef struct { |
5368 | | int32_t useless; // useless |
5369 | | int32_t sqlLen; |
5370 | | char* sql; |
5371 | | } SAssignLeaderReq; |
5372 | | |
5373 | | int32_t tSerializeSAssignLeaderReq(void* buf, int32_t bufLen, SAssignLeaderReq* pReq); |
5374 | | int32_t tDeserializeSAssignLeaderReq(void* buf, int32_t bufLen, SAssignLeaderReq* pReq); |
5375 | | void tFreeSAssignLeaderReq(SAssignLeaderReq* pReq); |
5376 | | typedef struct { |
5377 | | int32_t vgId1; |
5378 | | int32_t vgId2; |
5379 | | } SMergeVgroupReq; |
5380 | | |
5381 | | int32_t tSerializeSMergeVgroupReq(void* buf, int32_t bufLen, SMergeVgroupReq* pReq); |
5382 | | int32_t tDeserializeSMergeVgroupReq(void* buf, int32_t bufLen, SMergeVgroupReq* pReq); |
5383 | | |
5384 | | typedef struct { |
5385 | | int32_t vgId; |
5386 | | int32_t dnodeId1; |
5387 | | int32_t dnodeId2; |
5388 | | int32_t dnodeId3; |
5389 | | int32_t sqlLen; |
5390 | | char* sql; |
5391 | | } SRedistributeVgroupReq; |
5392 | | |
5393 | | int32_t tSerializeSRedistributeVgroupReq(void* buf, int32_t bufLen, SRedistributeVgroupReq* pReq); |
5394 | | int32_t tDeserializeSRedistributeVgroupReq(void* buf, int32_t bufLen, SRedistributeVgroupReq* pReq); |
5395 | | void tFreeSRedistributeVgroupReq(SRedistributeVgroupReq* pReq); |
5396 | | |
5397 | | typedef struct { |
5398 | | int32_t reserved; |
5399 | | int32_t vgId; |
5400 | | int32_t sqlLen; |
5401 | | char* sql; |
5402 | | char db[TSDB_DB_FNAME_LEN]; |
5403 | | } SBalanceVgroupLeaderReq; |
5404 | | |
5405 | | int32_t tSerializeSBalanceVgroupLeaderReq(void* buf, int32_t bufLen, SBalanceVgroupLeaderReq* pReq); |
5406 | | int32_t tDeserializeSBalanceVgroupLeaderReq(void* buf, int32_t bufLen, SBalanceVgroupLeaderReq* pReq); |
5407 | | void tFreeSBalanceVgroupLeaderReq(SBalanceVgroupLeaderReq* pReq); |
5408 | | |
5409 | | typedef struct { |
5410 | | int32_t vgId; |
5411 | | } SForceBecomeFollowerReq; |
5412 | | |
5413 | | int32_t tSerializeSForceBecomeFollowerReq(void* buf, int32_t bufLen, SForceBecomeFollowerReq* pReq); |
5414 | | // int32_t tDeserializeSForceBecomeFollowerReq(void* buf, int32_t bufLen, SForceBecomeFollowerReq* pReq); |
5415 | | |
5416 | | typedef struct { |
5417 | | int32_t vgId; |
5418 | | bool force; |
5419 | | } SSplitVgroupReq; |
5420 | | |
5421 | | int32_t tSerializeSSplitVgroupReq(void* buf, int32_t bufLen, SSplitVgroupReq* pReq); |
5422 | | int32_t tDeserializeSSplitVgroupReq(void* buf, int32_t bufLen, SSplitVgroupReq* pReq); |
5423 | | |
5424 | | typedef struct { |
5425 | | int32_t vgId; |
5426 | | int32_t dnodeId; |
5427 | | int32_t sqlLen; |
5428 | | char* sql; |
5429 | | } SCloseVnodeReq; |
5430 | | |
5431 | | int32_t tSerializeSCloseVnodeReq(void* buf, int32_t bufLen, SCloseVnodeReq* pReq); |
5432 | | int32_t tDeserializeSCloseVnodeReq(void* buf, int32_t bufLen, SCloseVnodeReq* pReq); |
5433 | | void tFreeSCloseVnodeReq(SCloseVnodeReq* pReq); |
5434 | | |
5435 | | typedef struct { |
5436 | | int32_t vgId; |
5437 | | int32_t dnodeId; |
5438 | | int32_t sqlLen; |
5439 | | char* sql; |
5440 | | } SOpenVnodeReq; |
5441 | | |
5442 | | int32_t tSerializeSOpenVnodeReq(void* buf, int32_t bufLen, SOpenVnodeReq* pReq); |
5443 | | int32_t tDeserializeSOpenVnodeReq(void* buf, int32_t bufLen, SOpenVnodeReq* pReq); |
5444 | | void tFreeSOpenVnodeReq(SOpenVnodeReq* pReq); |
5445 | | |
5446 | | typedef struct { |
5447 | | char user[TSDB_USER_LEN]; |
5448 | | char spi; |
5449 | | char encrypt; |
5450 | | char secret[TSDB_PASSWORD_LEN]; |
5451 | | char ckey[TSDB_PASSWORD_LEN]; |
5452 | | } SAuthReq, SAuthRsp; |
5453 | | |
5454 | | // int32_t tSerializeSAuthReq(void* buf, int32_t bufLen, SAuthReq* pReq); |
5455 | | // int32_t tDeserializeSAuthReq(void* buf, int32_t bufLen, SAuthReq* pReq); |
5456 | | |
5457 | | typedef struct { |
5458 | | int32_t statusCode; |
5459 | | char details[1024]; |
5460 | | } SServerStatusRsp; |
5461 | | |
5462 | | int32_t tSerializeSServerStatusRsp(void* buf, int32_t bufLen, SServerStatusRsp* pRsp); |
5463 | | int32_t tDeserializeSServerStatusRsp(void* buf, int32_t bufLen, SServerStatusRsp* pRsp); |
5464 | | |
5465 | | /** |
5466 | | * The layout of the query message payload is as following: |
5467 | | * +--------------------+---------------------------------+ |
5468 | | * |Sql statement | Physical plan | |
5469 | | * |(denoted by sqlLen) |(In JSON, denoted by contentLen) | |
5470 | | * +--------------------+---------------------------------+ |
5471 | | */ |
5472 | | typedef struct SCorrelationParamDef { |
5473 | | int32_t paramId; |
5474 | | SDataType dataType; |
5475 | | } SCorrelationParamDef; |
5476 | | |
5477 | | typedef struct SCorrelationWireValue { |
5478 | | int32_t paramId; |
5479 | | SDataType dataType; |
5480 | | bool isNull; |
5481 | | int32_t dataLen; // Exact byte length; zero when isNull is true. |
5482 | | uint8_t* pData; // May contain NUL; owned on decode/copy, borrowed on send. |
5483 | | } SCorrelationWireValue; |
5484 | | |
5485 | | typedef struct SCorrelationExecution { |
5486 | | uint64_t rootExecutionId; |
5487 | | uint64_t rootQueryId; |
5488 | | uint64_t rootClientId; |
5489 | | uint32_t executionGeneration; |
5490 | | uint64_t parentQueryId; |
5491 | | uint64_t parentClientId; |
5492 | | uint64_t parentTaskId; |
5493 | | uint64_t parentSeriesId; |
5494 | | int32_t parentExecId; |
5495 | | int32_t templateId; |
5496 | | uint64_t callOrdinal; |
5497 | | // Bounded NUL-terminated names copied into the task-session context. |
5498 | | char user[TSDB_USER_LEN]; |
5499 | | char dbFName[TSDB_DB_FNAME_LEN]; |
5500 | | char timezoneName[TD_TIMEZONE_LEN]; |
5501 | | char charsetName[TD_LOCALE_LEN]; |
5502 | | } SCorrelationExecution; |
5503 | | |
5504 | | typedef struct SSubQueryMsg { |
5505 | | SMsgHead header; |
5506 | | uint64_t sId; |
5507 | | uint64_t queryId; |
5508 | | uint64_t clientId; |
5509 | | uint64_t taskId; |
5510 | | int64_t refId; |
5511 | | int32_t execId; |
5512 | | int32_t msgMask; |
5513 | | int32_t subQType; |
5514 | | int8_t taskType; |
5515 | | int8_t explain; |
5516 | | int8_t needFetch; |
5517 | | int8_t compress; |
5518 | | int8_t firstDayOfWeek; |
5519 | | uint32_t sqlLen; |
5520 | | char* sql; |
5521 | | uint32_t msgLen; |
5522 | | char* msg; |
5523 | | SArray* subEndPoints; // subJobs's endpoints, element is SDownstreamSourceNode* |
5524 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
5525 | | SCorrelationExecution correlation; |
5526 | | SArray* pCorrelationParamDefs; // SCorrelationParamDef elements. |
5527 | | SArray* pCorrelationParamValues; // SCorrelationWireValue elements. |
5528 | | uint32_t correlationTemplatesLen; |
5529 | | char* pCorrelationTemplates; // Owned on decode; borrowed on send. |
5530 | | uint32_t correlationTimeInitLen; |
5531 | | char* pCorrelationTimeInit; // Owned on decode; borrowed on send. |
5532 | | SArray* pCorrelationNodeList; // SQueryNodeLoad candidates inherited by nested jobs. |
5533 | | // Set only by the scheduler for a pure VNode scan eligible for replica execution. |
5534 | | bool allowFollowerRead; |
5535 | | } SSubQueryMsg; |
5536 | | |
5537 | | int32_t tSerializeSSubQueryMsg(void* buf, int32_t bufLen, SSubQueryMsg* pReq); |
5538 | | int32_t tDeserializeSSubQueryMsg(void* buf, int32_t bufLen, SSubQueryMsg* pReq); |
5539 | | void tFreeSSubQueryMsg(SSubQueryMsg* pReq); |
5540 | | int32_t tValidateCorrelationParams(const SArray* pDefs, const SArray* pValues); |
5541 | | |
5542 | | typedef struct { |
5543 | | SMsgHead header; |
5544 | | uint64_t sId; |
5545 | | uint64_t queryId; |
5546 | | uint64_t taskId; |
5547 | | } SSinkDataReq; |
5548 | | |
5549 | | typedef struct { |
5550 | | SMsgHead header; |
5551 | | uint64_t sId; |
5552 | | uint64_t queryId; |
5553 | | uint64_t clientId; |
5554 | | uint64_t taskId; |
5555 | | int32_t execId; |
5556 | | int32_t taskType; |
5557 | | } SQueryContinueReq; |
5558 | | |
5559 | | typedef struct { |
5560 | | SMsgHead header; |
5561 | | uint64_t sId; |
5562 | | uint64_t queryId; |
5563 | | uint64_t taskId; |
5564 | | } SResReadyReq; |
5565 | | |
5566 | | typedef struct { |
5567 | | int32_t code; |
5568 | | char tbFName[TSDB_TABLE_FNAME_LEN]; |
5569 | | int32_t sversion; |
5570 | | int32_t tversion; |
5571 | | } SResReadyRsp; |
5572 | | |
5573 | | typedef enum { OP_GET_PARAM = 1, OP_NOTIFY_PARAM } SOperatorParamType; |
5574 | | |
5575 | | typedef struct SOperatorParam { |
5576 | | int32_t opType; |
5577 | | int32_t downstreamIdx; |
5578 | | void* value; |
5579 | | SArray* pChildren; // SArray<SOperatorParam*> |
5580 | | bool reUse; |
5581 | | } SOperatorParam; |
5582 | | |
5583 | | |
5584 | | int32_t tSerializeSOperatorParam(SEncoder *pEncoder, SOperatorParam *pOpParam); |
5585 | | int32_t tDeserializeSOperatorParam(SDecoder *pDecoder, SOperatorParam *pOpParam); |
5586 | | void freeOperatorParam(SOperatorParam* pParam, SOperatorParamType type); |
5587 | | |
5588 | | // virtual table's colId to origin table's colname |
5589 | | typedef struct SColIdNameKV { |
5590 | | col_id_t colId; |
5591 | | char colName[TSDB_COL_NAME_LEN]; |
5592 | | } SColIdNameKV; |
5593 | | |
5594 | | typedef struct SVTagCondEntry { |
5595 | | col_id_t colId; |
5596 | | int32_t tagCondLen; |
5597 | | char* tagCondJson; // heap, owned by SVTagCondRsp |
5598 | | } SVTagCondEntry; |
5599 | | |
5600 | | typedef struct SVtbColFilterCond { |
5601 | | col_id_t colId; |
5602 | | int32_t filterCondLen; |
5603 | | char* filterCondJson; // heap, owned by SVTagCondRsp |
5604 | | } SVtbColFilterCond; |
5605 | | |
5606 | | typedef struct SVTagCondReq { |
5607 | | SMsgHead header; |
5608 | | char dbFName[TSDB_DB_FNAME_LEN]; |
5609 | | int64_t uid; // virtual sub-table uid |
5610 | | } SVTagCondReq; |
5611 | | |
5612 | | typedef struct SVTagCondRsp { |
5613 | | int32_t numOfRefs; |
5614 | | SArray* pEntries; // SArray<SVTagCondEntry> |
5615 | | int32_t numOfFilterConds; |
5616 | | SArray* pFilterConds; // optional tail extension: SArray<SVtbColFilterCond> |
5617 | | } SVTagCondRsp; |
5618 | | |
5619 | | int32_t tSerializeSVTagCondReq(void* buf, int32_t bufLen, SVTagCondReq* pReq); |
5620 | | int32_t tDeserializeSVTagCondReq(void* buf, int32_t bufLen, SVTagCondReq* pReq); |
5621 | | int32_t tSerializeSVTagCondRsp(void* buf, int32_t bufLen, SVTagCondRsp* pRsp); |
5622 | | int32_t tDeserializeSVTagCondRsp(void* buf, int32_t bufLen, SVTagCondRsp* pRsp); |
5623 | | void tDestroySVTagCondRsp(void* rsp); |
5624 | | |
5625 | | #define COL_MASK_ON ((int8_t)0x1) |
5626 | | #define IS_MASK_ON(c) (((c)->flags & 0x01) == COL_MASK_ON) |
5627 | | #define COL_SET_MASK_ON(c) \ |
5628 | | do { \ |
5629 | | (c)->flags |= COL_MASK_ON; \ |
5630 | | } while (0) |
5631 | | |
5632 | | typedef struct SColNameFlag { |
5633 | | col_id_t colId; |
5634 | | char colName[TSDB_COL_NAME_LEN]; |
5635 | | int8_t flags; // 0x01: COL_MASK_ON |
5636 | | } SColNameFlag; |
5637 | | |
5638 | | typedef struct SColIdPair { |
5639 | | col_id_t vtbColId; |
5640 | | col_id_t orgColId; |
5641 | | SDataType type; |
5642 | | } SColIdPair; |
5643 | | |
5644 | | typedef struct SColIdSlotIdPair { |
5645 | | int32_t vtbSlotId; |
5646 | | col_id_t orgColId; |
5647 | | } SColIdSlotIdPair; |
5648 | | |
5649 | | typedef struct SOrgTbInfo { |
5650 | | int32_t vgId; |
5651 | | char tbName[TSDB_TABLE_FNAME_LEN]; |
5652 | | SArray* colMap; // SArray<SColIdNameKV> |
5653 | | uint8_t srcPrecision; // source DB precision; UINT8_MAX = unknown (use getVnodePrecision at runtime) |
5654 | | uint8_t dstPrecision; // vtable precision; UINT8_MAX = unknown |
5655 | | } SOrgTbInfo; |
5656 | | |
5657 | | typedef struct SForeignSourceInfo { |
5658 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
5659 | | char dbName[TSDB_DB_NAME_LEN]; |
5660 | | char tableName[TSDB_TABLE_NAME_LEN]; |
5661 | | SArray* colMap; // SArray<SColIdNameKV> |
5662 | | char* tagCond; // heap, owned; external series filter shared by this group (may be NULL) |
5663 | | int32_t tagCondLen; |
5664 | | uint64_t scanParamId; // stable identity of one external scan parameter group |
5665 | | int32_t filterCondLen; |
5666 | | char* filterCondJson; // serialized external column filter, heap owned |
5667 | | int64_t rowLimit; // optional per-stream top-N limit for VStb remote SQL; <=0 means unset |
5668 | | SNode* pPushedCond; // heap, owned; VStb local filter fragment safe to push to this foreign source |
5669 | | uint64_t virtualChildUid; // virtual child whose row is reconstructed from this remote table |
5670 | | } SForeignSourceInfo; |
5671 | | |
5672 | | void destroySOrgTbInfo(void *info); |
5673 | | void destroySForeignSourceInfo(void *info); |
5674 | | |
5675 | | typedef enum { |
5676 | | DYN_TYPE_STB_JOIN = 1, |
5677 | | DYN_TYPE_VSTB_SINGLE_SCAN, |
5678 | | DYN_TYPE_VSTB_BATCH_SCAN, |
5679 | | DYN_TYPE_VSTB_WIN_SCAN, |
5680 | | DYN_TYPE_TWO_PASS_RESCAN, // coord-driven vtable two-pass phase-2 rescan |
5681 | | } ETableScanDynType; |
5682 | | |
5683 | | typedef enum { |
5684 | | DYN_TYPE_SCAN_PARAM = 1, |
5685 | | NOTIFY_TYPE_SCAN_PARAM, |
5686 | | } ETableScanGetParamType; |
5687 | | |
5688 | | typedef struct STableScanOperatorParam { |
5689 | | ETableScanGetParamType paramType; |
5690 | | /* for building scan data source */ |
5691 | | bool tableSeq; |
5692 | | bool isNewParam; |
5693 | | uint64_t groupid; |
5694 | | SArray* pUidList; |
5695 | | SOrgTbInfo* pOrgTbInfo; |
5696 | | SArray* pBatchTbInfo; // SArray<SOrgTbInfo> |
5697 | | SArray* pTagList; |
5698 | | STimeWindow window; |
5699 | | ETableScanDynType dynType; |
5700 | | /* for notifying source step done */ |
5701 | | bool notifyToProcess; // received notify STEP DONE message |
5702 | | TSKEY notifyTs; // notify timestamp |
5703 | | int8_t notifyPhase; // EScanPhase of the source scan |
5704 | | uint64_t notifyScanGroupId; // source scan group identity |
5705 | | } STableScanOperatorParam; |
5706 | | |
5707 | | typedef struct STagScanOperatorParam { |
5708 | | tb_uid_t vcUid; |
5709 | | } STagScanOperatorParam; |
5710 | | |
5711 | | typedef struct SRefColIdGroup { |
5712 | | SArray* pSlotIdList; // SArray<int32_t> |
5713 | | } SRefColIdGroup; |
5714 | | |
5715 | | typedef struct SVTableScanOperatorParam { |
5716 | | uint64_t uid; |
5717 | | STimeWindow window; |
5718 | | SOperatorParam* pTagScanOp; |
5719 | | int32_t tagDownStreamId; |
5720 | | char tbName[TSDB_TABLE_NAME_LEN]; |
5721 | | SArray* pOpParamArray; // SArray<SOperatorParam> - internal Exchange params |
5722 | | SArray* pForeignParamArray; // SArray<SOperatorParam> - external FederatedScan params |
5723 | | SArray* pRefColGroups; // SArray<SRefColIdGroup> |
5724 | | SArray* pResolvedTags; // SArray<STagVal>, resolved tag values from source tables |
5725 | | } SVTableScanOperatorParam; |
5726 | | |
5727 | | typedef struct SSysTableScanVtbRefReq { |
5728 | | int32_t vgId; // target vnode id that owns the referenced table |
5729 | | char dbName[TSDB_DB_NAME_LEN]; // short database name of the referenced table |
5730 | | char tbName[TSDB_TABLE_NAME_LEN]; // referenced table name |
5731 | | char colName[TSDB_COL_NAME_LEN]; // referenced column name on the target table |
5732 | | } SSysTableScanVtbRefReq; |
5733 | | |
5734 | | typedef struct SSysTableScanOperatorParam { |
5735 | | SArray* pVtbRefReqs; // SArray<SSysTableScanVtbRefReq> |
5736 | | } SSysTableScanOperatorParam; |
5737 | | |
5738 | | typedef enum EForeignScanParamType { |
5739 | | FOREIGN_SCAN_PARAM_SINGLE = 0, |
5740 | | FOREIGN_SCAN_PARAM_BATCH, |
5741 | | } EForeignScanParamType; |
5742 | | |
5743 | | typedef struct SForeignTableInfo { |
5744 | | char dbName[TSDB_DB_NAME_LEN]; |
5745 | | char tableName[TSDB_TABLE_NAME_LEN]; |
5746 | | SArray* colMap; // SArray<SColIdNameKV> |
5747 | | int8_t dstPrecision; |
5748 | | char* tagCond; // heap, owned |
5749 | | int32_t tagCondLen; |
5750 | | uint64_t scanParamId; |
5751 | | int32_t filterCondLen; |
5752 | | char* filterCondJson; // serialized external column filter, heap owned |
5753 | | int64_t rowLimit; |
5754 | | char* pPushedCondJson; // serialized SNode, heap owned |
5755 | | SNode* pPushedCond; // runtime-only SNode, heap owned |
5756 | | uint64_t virtualChildUid; // virtual child whose row is reconstructed from this table |
5757 | | SArray* pVtbTagList; // runtime-only SArray<STagVal>, owned by the batch table |
5758 | | } SForeignTableInfo; |
5759 | | |
5760 | | typedef struct SForeignScanOperatorParam { |
5761 | | EForeignScanParamType paramType; |
5762 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
5763 | | int64_t sourceMetaVersion; |
5764 | | char dbName[TSDB_DB_NAME_LEN]; |
5765 | | char tableName[TSDB_TABLE_NAME_LEN]; |
5766 | | SArray* colMap; // SArray<SColIdNameKV> |
5767 | | // Destination precision for TIMESTAMP columns of the virtual table this |
5768 | | // dispatch targets. Set by the upstream VTable scan operator from the |
5769 | | // input block's ts slot precision. -1 means unset (legacy path). |
5770 | | int8_t dstPrecision; |
5771 | | char* tagCond; // heap, owned; external series filter pushed into the remote SQL (may be NULL) |
5772 | | int32_t tagCondLen; |
5773 | | uint64_t scanParamId; |
5774 | | int32_t filterCondLen; |
5775 | | char* filterCondJson; // serialized external column filter, heap owned in standalone params |
5776 | | int64_t rowLimit; // optional per-stream top-N limit for VStb remote SQL; <=0 means unset |
5777 | | SNode* pPushedCond; // heap, owned; optional VStb data filter pushed into the remote SQL |
5778 | | SArray* pBatchTables; // SArray<SForeignTableInfo>, owned in batch mode |
5779 | | int32_t groupId; // virtual-table group; zero when the query has no grouping |
5780 | | STimeWindow window; // common half-open scan range applied to every table in the batch |
5781 | | bool isNewParam; // true when FederatedScan must start this batch from its first table |
5782 | | uint64_t virtualChildUid; // runtime-only discriminator for one table view inside a batch |
5783 | | bool hasVtbGroupId; // runtime-only full-width virtual-table group id discriminator |
5784 | | uint64_t vtbGroupId; // runtime-only; never encoded by the legacy batch codec |
5785 | | SArray* pVtbTagList; // runtime-only borrowed tag payload for the active table view |
5786 | | // Runtime-only: consumer accepts timestamp order changes between batch tables. |
5787 | | bool allowUnorderedBatch; |
5788 | | } SForeignScanOperatorParam; |
5789 | | typedef struct SMergeOperatorParam { |
5790 | | int32_t winNum; |
5791 | | bool mergeSameCols; |
5792 | | bool activeSourcesOnly; // runtime-only scoped row-merge dispatch |
5793 | | } SMergeOperatorParam; |
5794 | | |
5795 | | typedef struct SAggOperatorParam { |
5796 | | bool needCleanRes; |
5797 | | } SAggOperatorParam; |
5798 | | |
5799 | | typedef struct SExternalWindowOperatorParam { |
5800 | | SArray* ExtWins; // SArray<SExtWinTimeWindow> |
5801 | | SArray* pNullOutputSlots; // SArray<int32_t>, aggregate outputs not owned by this execution unit |
5802 | | } SExternalWindowOperatorParam; |
5803 | | |
5804 | | typedef struct SDynQueryCtrlOperatorParam { |
5805 | | STimeWindow window; |
5806 | | } SDynQueryCtrlOperatorParam; |
5807 | | |
5808 | | struct SStreamRuntimeFuncInfo; |
5809 | | typedef struct SStreamContextFrames SStreamContextFrames; |
5810 | | typedef struct SStreamFetchContextSelection SStreamFetchContextSelection; |
5811 | | typedef struct { |
5812 | | SMsgHead header; |
5813 | | uint64_t sId; |
5814 | | uint64_t queryId; |
5815 | | uint64_t clientId; |
5816 | | uint64_t taskId; |
5817 | | uint64_t srcTaskId; // used for subQ |
5818 | | uint64_t blockIdx; // used for subQ |
5819 | | int32_t execId; |
5820 | | SOperatorParam* pOpParam; |
5821 | | |
5822 | | // used for new-stream |
5823 | | struct SStreamRuntimeFuncInfo* pStRtFuncInfo; |
5824 | | bool reset; |
5825 | | bool dynTbname; |
5826 | | bool forceFetchCompleted; |
5827 | | bool phase2Rescan; // vtable two-pass: remote origin reuses reader and rescans |
5828 | | bool reuseReader; |
5829 | | bool readerGroupMode; |
5830 | | bool readerDimensionBatch; |
5831 | | bool runnerEogBatch; |
5832 | | uint64_t readerFetchId; |
5833 | | SStreamContextFrames* pContextFrames; // optional owned validated frame copy |
5834 | | // Set only by the scheduler for a pure VNode scan eligible for replica execution. |
5835 | | bool allowFollowerRead; |
5836 | | // used for new-stream |
5837 | | } SResFetchReq; |
5838 | | |
5839 | 0 | #define SRES_FETCH_FOLLOWER_READ_FRAME_VERSION 1 |
5840 | 0 | #define SRES_FETCH_FOLLOWER_READ_FRAME_MAGIC UINT32_C(0x46525244) |
5841 | | |
5842 | | int32_t tSerializeSResFetchReq(void* buf, int32_t bufLen, SResFetchReq* pReq, bool needStreamRtInfo, bool needStreamGrpInfo); |
5843 | | int32_t tDeserializeSResFetchReq(void* buf, int32_t bufLen, SResFetchReq* pReq); |
5844 | | int32_t tDeserializeSResFetchReqWithContextFrames(void* buf, int32_t bufLen, SResFetchReq* pReq); |
5845 | | int32_t tBuildStreamRunnerFetchReq(SResFetchReq* pReq, const SStreamContextFrames* pFrames, void** ppBuf, |
5846 | | int32_t* pLen); |
5847 | | int32_t tBuildStreamReaderFetchReq(SResFetchReq* pReq, void** ppBuf, int32_t* pLen); |
5848 | | int32_t tBuildStreamPreparedFetchReq(SResFetchReq* pReq, const struct SStreamRuntimeFuncInfo* pBatch, |
5849 | | const SStreamFetchContextSelection* pSelection, void** ppBuf, int32_t* pLen); |
5850 | | void tDestroySResFetchReq(SResFetchReq* pReq); |
5851 | | typedef struct { |
5852 | | SMsgHead header; |
5853 | | uint64_t clientId; |
5854 | | } SSchTasksStatusReq; |
5855 | | |
5856 | | typedef struct { |
5857 | | uint64_t queryId; |
5858 | | uint64_t clientId; |
5859 | | uint64_t taskId; |
5860 | | int64_t refId; |
5861 | | int32_t subJobId; |
5862 | | int32_t execId; |
5863 | | int8_t status; |
5864 | | } STaskStatus; |
5865 | | |
5866 | | typedef struct { |
5867 | | int64_t refId; |
5868 | | SArray* taskStatus; // SArray<STaskStatus> |
5869 | | } SSchedulerStatusRsp; |
5870 | | |
5871 | | typedef struct { |
5872 | | uint64_t queryId; |
5873 | | uint64_t taskId; |
5874 | | int8_t action; |
5875 | | } STaskAction; |
5876 | | |
5877 | | typedef struct SQueryNodeEpId { |
5878 | | int32_t nodeId; // vgId or qnodeId |
5879 | | SEp ep; |
5880 | | } SQueryNodeEpId; |
5881 | | |
5882 | | typedef struct { |
5883 | | SMsgHead header; |
5884 | | uint64_t clientId; |
5885 | | SQueryNodeEpId epId; |
5886 | | SArray* taskAction; // SArray<STaskAction> |
5887 | | } SSchedulerHbReq; |
5888 | | |
5889 | | int32_t tSerializeSSchedulerHbReq(void* buf, int32_t bufLen, SSchedulerHbReq* pReq); |
5890 | | int32_t tDeserializeSSchedulerHbReq(void* buf, int32_t bufLen, SSchedulerHbReq* pReq); |
5891 | | void tFreeSSchedulerHbReq(SSchedulerHbReq* pReq); |
5892 | | |
5893 | | typedef struct { |
5894 | | SQueryNodeEpId epId; |
5895 | | SArray* taskStatus; // SArray<STaskStatus> |
5896 | | } SSchedulerHbRsp; |
5897 | | |
5898 | | int32_t tSerializeSSchedulerHbRsp(void* buf, int32_t bufLen, SSchedulerHbRsp* pRsp); |
5899 | | int32_t tDeserializeSSchedulerHbRsp(void* buf, int32_t bufLen, SSchedulerHbRsp* pRsp); |
5900 | | void tFreeSSchedulerHbRsp(SSchedulerHbRsp* pRsp); |
5901 | | |
5902 | | typedef struct { |
5903 | | SMsgHead header; |
5904 | | uint64_t sId; |
5905 | | uint64_t queryId; |
5906 | | uint64_t clientId; |
5907 | | uint64_t taskId; |
5908 | | int64_t refId; |
5909 | | int32_t execId; |
5910 | | } STaskCancelReq; |
5911 | | |
5912 | | typedef struct { |
5913 | | int32_t code; |
5914 | | } STaskCancelRsp; |
5915 | | |
5916 | | typedef struct { |
5917 | | SMsgHead header; |
5918 | | uint64_t sId; |
5919 | | uint64_t queryId; |
5920 | | uint64_t clientId; |
5921 | | uint64_t taskId; |
5922 | | int64_t refId; |
5923 | | int32_t execId; |
5924 | | } STaskDropReq; |
5925 | | |
5926 | | int32_t tSerializeSTaskDropReq(void* buf, int32_t bufLen, STaskDropReq* pReq); |
5927 | | int32_t tDeserializeSTaskDropReq(void* buf, int32_t bufLen, STaskDropReq* pReq); |
5928 | | |
5929 | | typedef enum { |
5930 | | TASK_NOTIFY_FINISHED = 1, |
5931 | | } ETaskNotifyType; |
5932 | | |
5933 | | typedef struct { |
5934 | | SMsgHead header; |
5935 | | uint64_t sId; |
5936 | | uint64_t queryId; |
5937 | | uint64_t clientId; |
5938 | | uint64_t taskId; |
5939 | | int64_t refId; |
5940 | | int32_t execId; |
5941 | | ETaskNotifyType type; |
5942 | | } STaskNotifyReq; |
5943 | | |
5944 | | int32_t tSerializeSTaskNotifyReq(void* buf, int32_t bufLen, STaskNotifyReq* pReq); |
5945 | | int32_t tDeserializeSTaskNotifyReq(void* buf, int32_t bufLen, STaskNotifyReq* pReq); |
5946 | | |
5947 | | int32_t tSerializeSQueryTableRsp(void* buf, int32_t bufLen, SQueryTableRsp* pRsp); |
5948 | | int32_t tDeserializeSQueryTableRsp(void* buf, int32_t bufLen, SQueryTableRsp* pRsp); |
5949 | | |
5950 | | typedef struct { |
5951 | | int32_t code; |
5952 | | } STaskDropRsp; |
5953 | | |
5954 | | #define STREAM_TRIGGER_AT_ONCE 1 |
5955 | | #define STREAM_TRIGGER_WINDOW_CLOSE 2 |
5956 | | #define STREAM_TRIGGER_MAX_DELAY 3 |
5957 | | #define STREAM_TRIGGER_FORCE_WINDOW_CLOSE 4 |
5958 | | #define STREAM_TRIGGER_CONTINUOUS_WINDOW_CLOSE 5 |
5959 | | |
5960 | | #define STREAM_DEFAULT_IGNORE_EXPIRED 1 |
5961 | | #define STREAM_FILL_HISTORY_ON 1 |
5962 | | #define STREAM_FILL_HISTORY_OFF 0 |
5963 | | #define STREAM_DEFAULT_FILL_HISTORY STREAM_FILL_HISTORY_OFF |
5964 | | #define STREAM_DEFAULT_IGNORE_UPDATE 1 |
5965 | | #define STREAM_CREATE_STABLE_TRUE 1 |
5966 | | #define STREAM_CREATE_STABLE_FALSE 0 |
5967 | | |
5968 | | typedef struct SVgroupVer { |
5969 | | int32_t vgId; |
5970 | | int64_t ver; |
5971 | | } SVgroupVer; |
5972 | | |
5973 | | enum { |
5974 | | TOPIC_SUB_TYPE__DB = 1, |
5975 | | TOPIC_SUB_TYPE__TABLE, |
5976 | | TOPIC_SUB_TYPE__COLUMN, |
5977 | | }; |
5978 | | |
5979 | 0 | #define DEFAULT_MAX_POLL_INTERVAL 300000 |
5980 | 0 | #define DEFAULT_SESSION_TIMEOUT 12000 |
5981 | | #define DEFAULT_MAX_POLL_WAIT_TIME 1000 |
5982 | | #define DEFAULT_MIN_POLL_ROWS 4096 |
5983 | | |
5984 | | typedef struct { |
5985 | | char name[TSDB_TOPIC_FNAME_LEN]; // accout.topic |
5986 | | int8_t igExists; |
5987 | | int8_t subType; |
5988 | | int8_t withMeta; |
5989 | | char* sql; |
5990 | | char subDbName[TSDB_DB_FNAME_LEN]; |
5991 | | char* ast; |
5992 | | char subStbName[TSDB_TABLE_FNAME_LEN]; |
5993 | | int8_t reload; |
5994 | | } SCMCreateTopicReq; |
5995 | | |
5996 | | int32_t tSerializeSCMCreateTopicReq(void* buf, int32_t bufLen, const SCMCreateTopicReq* pReq); |
5997 | | int32_t tDeserializeSCMCreateTopicReq(void* buf, int32_t bufLen, SCMCreateTopicReq* pReq); |
5998 | | void tFreeSCMCreateTopicReq(SCMCreateTopicReq* pReq); |
5999 | | |
6000 | | typedef struct { |
6001 | | int64_t consumerId; |
6002 | | } SMqConsumerRecoverMsg, SMqConsumerClearMsg; |
6003 | | |
6004 | | typedef struct { |
6005 | | int64_t consumerId; |
6006 | | char cgroup[TSDB_CGROUP_LEN]; |
6007 | | char clientId[TSDB_CLIENT_ID_LEN]; |
6008 | | char user[TSDB_USER_LEN]; |
6009 | | char fqdn[TSDB_FQDN_LEN]; |
6010 | | SArray* topicNames; // SArray<char**> |
6011 | | |
6012 | | int8_t withTbName; |
6013 | | int8_t autoCommit; |
6014 | | int32_t autoCommitInterval; |
6015 | | int8_t resetOffsetCfg; |
6016 | | int8_t enableReplay; |
6017 | | int8_t enableBatchMeta; |
6018 | | int32_t sessionTimeoutMs; |
6019 | | int32_t maxPollIntervalMs; |
6020 | | int64_t ownerId; |
6021 | | } SCMSubscribeReq; |
6022 | | |
6023 | 0 | static FORCE_INLINE int32_t tSerializeSCMSubscribeReq(void** buf, const SCMSubscribeReq* pReq) { |
6024 | 0 | int32_t tlen = 0; |
6025 | 0 | tlen += taosEncodeFixedI64(buf, pReq->consumerId); |
6026 | 0 | tlen += taosEncodeString(buf, pReq->cgroup); |
6027 | 0 | tlen += taosEncodeString(buf, pReq->clientId); |
6028 | 0 |
|
6029 | 0 | int32_t topicNum = taosArrayGetSize(pReq->topicNames); |
6030 | 0 | tlen += taosEncodeFixedI32(buf, topicNum); |
6031 | 0 |
|
6032 | 0 | for (int32_t i = 0; i < topicNum; i++) { |
6033 | 0 | tlen += taosEncodeString(buf, (char*)taosArrayGetP(pReq->topicNames, i)); |
6034 | 0 | } |
6035 | 0 |
|
6036 | 0 | tlen += taosEncodeFixedI8(buf, pReq->withTbName); |
6037 | 0 | tlen += taosEncodeFixedI8(buf, pReq->autoCommit); |
6038 | 0 | tlen += taosEncodeFixedI32(buf, pReq->autoCommitInterval); |
6039 | 0 | tlen += taosEncodeFixedI8(buf, pReq->resetOffsetCfg); |
6040 | 0 | tlen += taosEncodeFixedI8(buf, pReq->enableReplay); |
6041 | 0 | tlen += taosEncodeFixedI8(buf, pReq->enableBatchMeta); |
6042 | 0 | tlen += taosEncodeFixedI32(buf, pReq->sessionTimeoutMs); |
6043 | 0 | tlen += taosEncodeFixedI32(buf, pReq->maxPollIntervalMs); |
6044 | 0 | tlen += taosEncodeString(buf, pReq->user); |
6045 | 0 | tlen += taosEncodeString(buf, pReq->fqdn); |
6046 | 0 |
|
6047 | 0 | return tlen; |
6048 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parser.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parTranslater.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parUtil.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parAstParser.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parAuthenticator.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parCalcConst.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parInsertSql.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parInsertUtil.c:tSerializeSCMSubscribeReq Unexecuted instantiation: taos_lemon_sql.tab.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parAstCreater.c:tSerializeSCMSubscribeReq Unexecuted instantiation: parInsertSml.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planner.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planLogicCreater.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planOptimizer.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planPhysiCreater.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planScaleOut.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planSpliter.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planUtil.c:tSerializeSCMSubscribeReq Unexecuted instantiation: planValidator.c:tSerializeSCMSubscribeReq Unexecuted instantiation: catalog.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgAsync.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgCache.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgDbg.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgRemote.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgRent.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ctgUtil.c:tSerializeSCMSubscribeReq Unexecuted instantiation: extConnector.c:tSerializeSCMSubscribeReq Unexecuted instantiation: extDialect.c:tSerializeSCMSubscribeReq Unexecuted instantiation: extDialectDefaults.c:tSerializeSCMSubscribeReq Unexecuted instantiation: functionMgt.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tudf.c:tSerializeSCMSubscribeReq Unexecuted instantiation: builtins.c:tSerializeSCMSubscribeReq Unexecuted instantiation: builtinsimpl.c:tSerializeSCMSubscribeReq Unexecuted instantiation: spillDistinctSet.c:tSerializeSCMSubscribeReq Unexecuted instantiation: thistogram.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tpercentile.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tavgfunction.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tminmax.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tminmaxavx.c:tSerializeSCMSubscribeReq Unexecuted instantiation: filter.c:tSerializeSCMSubscribeReq Unexecuted instantiation: scalar.c:tSerializeSCMSubscribeReq Unexecuted instantiation: sclfunc.c:tSerializeSCMSubscribeReq Unexecuted instantiation: sclvector.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesCloneFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesCodeFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesEqualFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesMatchFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesMsgFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesRemotePlanToSQL.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesToSQLFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesTraverseFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: nodesUtilFuncs.c:tSerializeSCMSubscribeReq Unexecuted instantiation: extTypeMap.c:tSerializeSCMSubscribeReq Unexecuted instantiation: queryUtil.c:tSerializeSCMSubscribeReq Unexecuted instantiation: querymsg.c:tSerializeSCMSubscribeReq Unexecuted instantiation: trans.c:tSerializeSCMSubscribeReq Unexecuted instantiation: transCli.c:tSerializeSCMSubscribeReq Unexecuted instantiation: transComm.c:tSerializeSCMSubscribeReq Unexecuted instantiation: transSasl.c:tSerializeSCMSubscribeReq Unexecuted instantiation: transSvr.c:tSerializeSCMSubscribeReq Unexecuted instantiation: transTLS.c:tSerializeSCMSubscribeReq Unexecuted instantiation: thttp.c:tSerializeSCMSubscribeReq Unexecuted instantiation: geomFunc.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tconfig.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tdigest.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tlog.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tmempool.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tpagedbuf.c:tSerializeSCMSubscribeReq Unexecuted instantiation: mpDirect.c:tSerializeSCMSubscribeReq Unexecuted instantiation: extCapability.c:tSerializeSCMSubscribeReq Unexecuted instantiation: systable.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tanalytics.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tdatablock.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tdataformat.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tglobal.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tmisce.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tname.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tpriv.c:tSerializeSCMSubscribeReq Unexecuted instantiation: ttime.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tvariant.c:tSerializeSCMSubscribeReq Unexecuted instantiation: streamMsg.c:tSerializeSCMSubscribeReq Unexecuted instantiation: streamWindowPlan.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tmsg.c:tSerializeSCMSubscribeReq Unexecuted instantiation: xnode.c:tSerializeSCMSubscribeReq Unexecuted instantiation: tencrypt.c:tSerializeSCMSubscribeReq Unexecuted instantiation: streamJson.c:tSerializeSCMSubscribeReq Unexecuted instantiation: crypt.c:tSerializeSCMSubscribeReq |
6049 | | |
6050 | | int32_t tDeserializeSCMSubscribeReq(void* buf, SCMSubscribeReq* pReq, int32_t len); |
6051 | | |
6052 | | typedef struct { |
6053 | | char key[TSDB_SUBSCRIBE_KEY_LEN]; |
6054 | | SArray* removedConsumers; // SArray<int64_t> |
6055 | | SArray* newConsumers; // SArray<int64_t> |
6056 | | } SMqRebInfo; |
6057 | | |
6058 | 0 | static FORCE_INLINE SMqRebInfo* tNewSMqRebSubscribe(const char* key) { |
6059 | 0 | SMqRebInfo* pRebInfo = (SMqRebInfo*)taosMemoryCalloc(1, sizeof(SMqRebInfo)); |
6060 | 0 | if (pRebInfo == NULL) { |
6061 | 0 | return NULL; |
6062 | 0 | } |
6063 | 0 | tstrncpy(pRebInfo->key, key, TSDB_SUBSCRIBE_KEY_LEN); |
6064 | 0 | pRebInfo->removedConsumers = taosArrayInit(0, sizeof(int64_t)); |
6065 | 0 | if (pRebInfo->removedConsumers == NULL) { |
6066 | 0 | goto _err; |
6067 | 0 | } |
6068 | 0 | pRebInfo->newConsumers = taosArrayInit(0, sizeof(int64_t)); |
6069 | 0 | if (pRebInfo->newConsumers == NULL) { |
6070 | 0 | goto _err; |
6071 | 0 | } |
6072 | 0 | return pRebInfo; |
6073 | 0 | _err: |
6074 | 0 | taosArrayDestroy(pRebInfo->removedConsumers); |
6075 | 0 | taosArrayDestroy(pRebInfo->newConsumers); |
6076 | 0 | taosMemoryFreeClear(pRebInfo); |
6077 | 0 | return NULL; |
6078 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tNewSMqRebSubscribe Unexecuted instantiation: parser.c:tNewSMqRebSubscribe Unexecuted instantiation: parTranslater.c:tNewSMqRebSubscribe Unexecuted instantiation: parUtil.c:tNewSMqRebSubscribe Unexecuted instantiation: parAstParser.c:tNewSMqRebSubscribe Unexecuted instantiation: parAuthenticator.c:tNewSMqRebSubscribe Unexecuted instantiation: parCalcConst.c:tNewSMqRebSubscribe Unexecuted instantiation: parInsertSql.c:tNewSMqRebSubscribe Unexecuted instantiation: parInsertUtil.c:tNewSMqRebSubscribe Unexecuted instantiation: taos_lemon_sql.tab.c:tNewSMqRebSubscribe Unexecuted instantiation: parAstCreater.c:tNewSMqRebSubscribe Unexecuted instantiation: parInsertSml.c:tNewSMqRebSubscribe Unexecuted instantiation: planner.c:tNewSMqRebSubscribe Unexecuted instantiation: planLogicCreater.c:tNewSMqRebSubscribe Unexecuted instantiation: planOptimizer.c:tNewSMqRebSubscribe Unexecuted instantiation: planPhysiCreater.c:tNewSMqRebSubscribe Unexecuted instantiation: planScaleOut.c:tNewSMqRebSubscribe Unexecuted instantiation: planSpliter.c:tNewSMqRebSubscribe Unexecuted instantiation: planUtil.c:tNewSMqRebSubscribe Unexecuted instantiation: planValidator.c:tNewSMqRebSubscribe Unexecuted instantiation: catalog.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgAsync.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgCache.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgDbg.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgRemote.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgRent.c:tNewSMqRebSubscribe Unexecuted instantiation: ctgUtil.c:tNewSMqRebSubscribe Unexecuted instantiation: extConnector.c:tNewSMqRebSubscribe Unexecuted instantiation: extDialect.c:tNewSMqRebSubscribe Unexecuted instantiation: extDialectDefaults.c:tNewSMqRebSubscribe Unexecuted instantiation: functionMgt.c:tNewSMqRebSubscribe Unexecuted instantiation: tudf.c:tNewSMqRebSubscribe Unexecuted instantiation: builtins.c:tNewSMqRebSubscribe Unexecuted instantiation: builtinsimpl.c:tNewSMqRebSubscribe Unexecuted instantiation: spillDistinctSet.c:tNewSMqRebSubscribe Unexecuted instantiation: thistogram.c:tNewSMqRebSubscribe Unexecuted instantiation: tpercentile.c:tNewSMqRebSubscribe Unexecuted instantiation: tavgfunction.c:tNewSMqRebSubscribe Unexecuted instantiation: tminmax.c:tNewSMqRebSubscribe Unexecuted instantiation: tminmaxavx.c:tNewSMqRebSubscribe Unexecuted instantiation: filter.c:tNewSMqRebSubscribe Unexecuted instantiation: scalar.c:tNewSMqRebSubscribe Unexecuted instantiation: sclfunc.c:tNewSMqRebSubscribe Unexecuted instantiation: sclvector.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesCloneFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesCodeFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesEqualFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesMatchFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesMsgFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesRemotePlanToSQL.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesToSQLFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesTraverseFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: nodesUtilFuncs.c:tNewSMqRebSubscribe Unexecuted instantiation: extTypeMap.c:tNewSMqRebSubscribe Unexecuted instantiation: queryUtil.c:tNewSMqRebSubscribe Unexecuted instantiation: querymsg.c:tNewSMqRebSubscribe Unexecuted instantiation: trans.c:tNewSMqRebSubscribe Unexecuted instantiation: transCli.c:tNewSMqRebSubscribe Unexecuted instantiation: transComm.c:tNewSMqRebSubscribe Unexecuted instantiation: transSasl.c:tNewSMqRebSubscribe Unexecuted instantiation: transSvr.c:tNewSMqRebSubscribe Unexecuted instantiation: transTLS.c:tNewSMqRebSubscribe Unexecuted instantiation: thttp.c:tNewSMqRebSubscribe Unexecuted instantiation: geomFunc.c:tNewSMqRebSubscribe Unexecuted instantiation: tconfig.c:tNewSMqRebSubscribe Unexecuted instantiation: tdigest.c:tNewSMqRebSubscribe Unexecuted instantiation: tlog.c:tNewSMqRebSubscribe Unexecuted instantiation: tmempool.c:tNewSMqRebSubscribe Unexecuted instantiation: tpagedbuf.c:tNewSMqRebSubscribe Unexecuted instantiation: mpDirect.c:tNewSMqRebSubscribe Unexecuted instantiation: extCapability.c:tNewSMqRebSubscribe Unexecuted instantiation: systable.c:tNewSMqRebSubscribe Unexecuted instantiation: tanalytics.c:tNewSMqRebSubscribe Unexecuted instantiation: tdatablock.c:tNewSMqRebSubscribe Unexecuted instantiation: tdataformat.c:tNewSMqRebSubscribe Unexecuted instantiation: tglobal.c:tNewSMqRebSubscribe Unexecuted instantiation: tmisce.c:tNewSMqRebSubscribe Unexecuted instantiation: tname.c:tNewSMqRebSubscribe Unexecuted instantiation: tpriv.c:tNewSMqRebSubscribe Unexecuted instantiation: ttime.c:tNewSMqRebSubscribe Unexecuted instantiation: tvariant.c:tNewSMqRebSubscribe Unexecuted instantiation: streamMsg.c:tNewSMqRebSubscribe Unexecuted instantiation: streamWindowPlan.c:tNewSMqRebSubscribe Unexecuted instantiation: tmsg.c:tNewSMqRebSubscribe Unexecuted instantiation: xnode.c:tNewSMqRebSubscribe Unexecuted instantiation: tencrypt.c:tNewSMqRebSubscribe Unexecuted instantiation: streamJson.c:tNewSMqRebSubscribe Unexecuted instantiation: crypt.c:tNewSMqRebSubscribe |
6079 | | |
6080 | | typedef struct { |
6081 | | int64_t streamId; |
6082 | | int64_t checkpointId; |
6083 | | char streamName[TSDB_STREAM_FNAME_LEN]; |
6084 | | } SMStreamDoCheckpointMsg; |
6085 | | |
6086 | | typedef struct { |
6087 | | int64_t status; |
6088 | | } SMVSubscribeRsp; |
6089 | | |
6090 | | typedef struct { |
6091 | | char name[TSDB_TOPIC_FNAME_LEN]; |
6092 | | int8_t igNotExists; |
6093 | | int32_t sqlLen; |
6094 | | char* sql; |
6095 | | int8_t force; |
6096 | | } SMDropTopicReq; |
6097 | | |
6098 | | int32_t tSerializeSMDropTopicReq(void* buf, int32_t bufLen, SMDropTopicReq* pReq); |
6099 | | int32_t tDeserializeSMDropTopicReq(void* buf, int32_t bufLen, SMDropTopicReq* pReq); |
6100 | | void tFreeSMDropTopicReq(SMDropTopicReq* pReq); |
6101 | | |
6102 | | typedef struct { |
6103 | | char name[TSDB_TOPIC_FNAME_LEN]; |
6104 | | int8_t igNotExists; |
6105 | | int32_t sqlLen; |
6106 | | char* sql; |
6107 | | } SMReloadTopicReq; |
6108 | | |
6109 | | int32_t tSerializeSMReloadTopicReq(void* buf, int32_t bufLen, SMReloadTopicReq* pReq); |
6110 | | int32_t tDeserializeSMReloadTopicReq(void* buf, int32_t bufLen, SMReloadTopicReq* pReq); |
6111 | | void tFreeSMReloadTopicReq(SMReloadTopicReq* pReq); |
6112 | | |
6113 | | typedef struct { |
6114 | | char topic[TSDB_TOPIC_FNAME_LEN]; |
6115 | | char cgroup[TSDB_CGROUP_LEN]; |
6116 | | int8_t igNotExists; |
6117 | | int8_t force; |
6118 | | } SMDropCgroupReq; |
6119 | | |
6120 | | int32_t tSerializeSMDropCgroupReq(void* buf, int32_t bufLen, SMDropCgroupReq* pReq); |
6121 | | int32_t tDeserializeSMDropCgroupReq(void* buf, int32_t bufLen, SMDropCgroupReq* pReq); |
6122 | | |
6123 | | typedef struct { |
6124 | | int8_t reserved; |
6125 | | } SMDropCgroupRsp; |
6126 | | |
6127 | | typedef struct { |
6128 | | char name[TSDB_TABLE_FNAME_LEN]; |
6129 | | int8_t alterType; |
6130 | | SSchema schema; |
6131 | | } SAlterTopicReq; |
6132 | | |
6133 | | typedef struct { |
6134 | | SMsgHead head; |
6135 | | char name[TSDB_TABLE_FNAME_LEN]; |
6136 | | int64_t tuid; |
6137 | | int32_t sverson; |
6138 | | int32_t execLen; |
6139 | | char* executor; |
6140 | | int32_t sqlLen; |
6141 | | char* sql; |
6142 | | } SDCreateTopicReq; |
6143 | | |
6144 | | typedef struct { |
6145 | | SMsgHead head; |
6146 | | char name[TSDB_TABLE_FNAME_LEN]; |
6147 | | int64_t tuid; |
6148 | | } SDDropTopicReq; |
6149 | | |
6150 | | typedef struct { |
6151 | | char* name; |
6152 | | int64_t uid; |
6153 | | int64_t interval[2]; |
6154 | | int8_t intervalUnit; |
6155 | | int16_t nFuncs; |
6156 | | col_id_t* funcColIds; // column ids specified by user |
6157 | | func_id_t* funcIds; // function ids specified by user |
6158 | | } SRSmaParam; |
6159 | | |
6160 | | int32_t tEncodeSRSmaParam(SEncoder* pCoder, const SRSmaParam* pRSmaParam); |
6161 | | int32_t tDecodeSRSmaParam(SDecoder* pCoder, SRSmaParam* pRSmaParam); |
6162 | | |
6163 | | // TDMT_VND_CREATE_STB ============== |
6164 | | typedef struct SVCreateStbReq { |
6165 | | char* name; |
6166 | | tb_uid_t suid; |
6167 | | int8_t rollup; |
6168 | | SSchemaWrapper schemaRow; |
6169 | | SSchemaWrapper schemaTag; |
6170 | | SRSmaParam rsmaParam; |
6171 | | int32_t alterOriDataLen; |
6172 | | void* alterOriData; |
6173 | | int8_t source; |
6174 | | int8_t colCmpred; |
6175 | | SColCmprWrapper colCmpr; |
6176 | | int64_t keep; |
6177 | | int64_t ownerId; |
6178 | | txn_id_t txnId; // batch-meta-txn: STB belongs to this txn (VNode marks as PRE_CREATE) |
6179 | | SExtSchema* pExtSchemas; |
6180 | | int8_t virtualStb; |
6181 | | int8_t secureDelete; |
6182 | | int8_t securityLevel; |
6183 | | // VST inheritance |
6184 | | int8_t numParents; |
6185 | | int64_t parentSuids[TSDB_MAX_VST_PARENTS]; |
6186 | | int16_t ownColStart; |
6187 | | int16_t ownTagStart; |
6188 | | // parent full names, resolved from parentSuids on the mnode when building the |
6189 | | // WAL entry, so the TMQ meta path (which has no catalog/connection handle and |
6190 | | // no suid index, and on a cross-cluster replay sees foreign suids) can emit a |
6191 | | // replayable BASE ON clause without a suid lookup. |
6192 | | char parentStbFNames[TSDB_MAX_VST_PARENTS][TSDB_TABLE_FNAME_LEN]; |
6193 | | } SVCreateStbReq; |
6194 | | |
6195 | | int tEncodeSVCreateStbReq(SEncoder* pCoder, const SVCreateStbReq* pReq); |
6196 | | int tDecodeSVCreateStbReq(SDecoder* pCoder, SVCreateStbReq* pReq); |
6197 | | |
6198 | | // TDMT_VND_DROP_STB ============== |
6199 | | typedef struct SVDropStbReq { |
6200 | | char* name; |
6201 | | tb_uid_t suid; |
6202 | | txn_id_t txnId; // batch-meta-txn: DROP STB belongs to this txn (VNode marks as PRE_DROP) |
6203 | | } SVDropStbReq; |
6204 | | |
6205 | | int32_t tEncodeSVDropStbReq(SEncoder* pCoder, const SVDropStbReq* pReq); |
6206 | | int32_t tDecodeSVDropStbReq(SDecoder* pCoder, SVDropStbReq* pReq); |
6207 | | |
6208 | | // TDMT_VND_CHECK_HAS_CTB ============== |
6209 | | typedef struct SVCheckHasCtbReq { |
6210 | | int64_t suid; |
6211 | | } SVCheckHasCtbReq; |
6212 | | |
6213 | | int32_t tSerializeSVCheckHasCtbReq(void* buf, int32_t bufLen, const SVCheckHasCtbReq* pReq); |
6214 | | int32_t tDeserializeSVCheckHasCtbReq(const void* buf, int32_t bufLen, SVCheckHasCtbReq* pReq); |
6215 | | |
6216 | | // TDMT_VND_CHECK_STB_ALTER_NAME ============== |
6217 | | // Pre-check for a virtual stb alter that introduces new column/tag names: each vnode owning |
6218 | | // vchild tables of the stb verifies that none of them already owns one of the names as an |
6219 | | // own (extension) column/tag. Response carries only the error code. |
6220 | | typedef struct SVCheckStbAlterNameReq { |
6221 | | int64_t suid; // uid of the virtual super table being altered |
6222 | | SArray* pNames; // array of char[TSDB_COL_NAME_LEN], new names introduced by the alter |
6223 | | } SVCheckStbAlterNameReq; |
6224 | | |
6225 | | int32_t tSerializeSVCheckStbAlterNameReq(void* buf, int32_t bufLen, const SVCheckStbAlterNameReq* pReq); |
6226 | | int32_t tDeserializeSVCheckStbAlterNameReq(const void* buf, int32_t bufLen, SVCheckStbAlterNameReq* pReq); |
6227 | | void tFreeSVCheckStbAlterNameReq(SVCheckStbAlterNameReq* pReq); |
6228 | | |
6229 | | // TDMT_VND_CREATE_TABLE ============== |
6230 | 0 | #define TD_CREATE_IF_NOT_EXISTS 0x1 |
6231 | | #define TD_CREATE_NORMAL_TB_IN_STREAM 0x2 |
6232 | | #define TD_CREATE_SUB_TB_IN_STREAM 0x4 |
6233 | | |
6234 | | // Own (extension) column of a virtual child table declared at CREATE VTABLE time |
6235 | | // (see SVChildOwnSchema in storageapi.h). schema.colId is a placeholder on the wire; |
6236 | | // the vnode assigns colIds from TSDB_VCHILD_OWN_COL_ID_BASE upwards. |
6237 | | typedef struct SVChildOwnColDef { |
6238 | | SSchema schema; |
6239 | | SColRef ref; // hasRef is always true: an own data column must carry an origin reference |
6240 | | STypeMod typeMod; // decimal precision/scale for own columns of decimal type (0 otherwise) |
6241 | | } SVChildOwnColDef; |
6242 | | |
6243 | | // Own (extension) tag of a virtual child table declared at CREATE VTABLE time. Carries |
6244 | | // an optional literal value (hasValue) or an optional tag reference (ref.hasRef); both |
6245 | | // empty means the tag value is NULL. schema.colId is a placeholder as above. |
6246 | | typedef struct SVChildOwnTagDef { |
6247 | | SSchema schema; |
6248 | | SColRef ref; |
6249 | | bool hasValue; |
6250 | | int8_t valType; |
6251 | | int64_t valI64; // fixed-width literal value |
6252 | | int32_t valLen; // payload length for var-width types |
6253 | | uint8_t *pVal; // var-width literal payload |
6254 | | } SVChildOwnTagDef; |
6255 | | |
6256 | | typedef struct SVCreateTbReq { |
6257 | | int32_t flags; |
6258 | | char* name; |
6259 | | tb_uid_t uid; |
6260 | | int64_t btime; |
6261 | | int32_t ttl; |
6262 | | int32_t commentLen; |
6263 | | char* comment; |
6264 | | int8_t type; |
6265 | | union { |
6266 | | struct { |
6267 | | char* stbName; // super table name |
6268 | | uint8_t tagNum; |
6269 | | tb_uid_t suid; |
6270 | | SArray* tagName; |
6271 | | uint8_t* pTag; |
6272 | | } ctb; |
6273 | | struct { |
6274 | | SSchemaWrapper schemaRow; |
6275 | | SSchemaWrapper schemaTag; // owned tag schema (normal/virtual-normal table with tags); nCols==0 when no tags |
6276 | | uint8_t* pTags; // owned tag values, STag container (NULL when no tags) |
6277 | | int64_t userId; |
6278 | | } ntb; |
6279 | | }; |
6280 | | int32_t sqlLen; |
6281 | | char* sql; |
6282 | | SColCmprWrapper colCmpr; |
6283 | | SExtSchema* pExtSchemas; |
6284 | | SColRefWrapper colRef; // col reference for virtual table |
6285 | | SSeriesWrapper series; // series declarations for virtual table |
6286 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
6287 | | int8_t txnStatus; // EMetaTxnStatus for snapshot replication (0 = normal/PRE_CREATE) |
6288 | | // vchild own (extension) columns/tags declared at create time, TSDB_VIRTUAL_CHILD_TABLE only |
6289 | | int32_t nOwnColDefs; |
6290 | | SVChildOwnColDef *pOwnColDefs; |
6291 | | int32_t nOwnTagDefs; |
6292 | | SVChildOwnTagDef *pOwnTagDefs; |
6293 | | } SVCreateTbReq; |
6294 | | |
6295 | | int tEncodeSVCreateTbReq(SEncoder* pCoder, const SVCreateTbReq* pReq); |
6296 | | int tDecodeSVCreateTbReq(SDecoder* pCoder, SVCreateTbReq* pReq); |
6297 | | void tdDestroySVCreateTbReq(SVCreateTbReq* pReq); |
6298 | | |
6299 | | typedef struct { |
6300 | | int32_t nReqs; |
6301 | | union { |
6302 | | SVCreateTbReq* pReqs; |
6303 | | SArray* pArray; |
6304 | | }; |
6305 | | int8_t source; // TD_REQ_FROM_TAOX-taosX or TD_REQ_FROM_APP-taosClient |
6306 | | } SVCreateTbBatchReq; |
6307 | | |
6308 | | int tEncodeSVCreateTbBatchReq(SEncoder* pCoder, const SVCreateTbBatchReq* pReq); |
6309 | | int tDecodeSVCreateTbBatchReq(SDecoder* pCoder, SVCreateTbBatchReq* pReq); |
6310 | | void tDeleteSVCreateTbBatchReq(SVCreateTbBatchReq* pReq); |
6311 | | |
6312 | | typedef struct { |
6313 | | int32_t code; |
6314 | | int32_t index; // index in batch req, start from 0 |
6315 | | STableMetaRsp* pMeta; |
6316 | | } SVCreateTbRsp, SVUpdateTbRsp; |
6317 | | |
6318 | | int tEncodeSVCreateTbRsp(SEncoder* pCoder, const SVCreateTbRsp* pRsp); |
6319 | | int tDecodeSVCreateTbRsp(SDecoder* pCoder, SVCreateTbRsp* pRsp); |
6320 | | void tFreeSVCreateTbRsp(void* param); |
6321 | | |
6322 | | int32_t tSerializeSVCreateTbReq(void** buf, SVCreateTbReq* pReq); |
6323 | | void* tDeserializeSVCreateTbReq(void* buf, SVCreateTbReq* pReq); |
6324 | | |
6325 | | typedef struct { |
6326 | | int32_t nRsps; |
6327 | | union { |
6328 | | SVCreateTbRsp* pRsps; |
6329 | | SArray* pArray; |
6330 | | }; |
6331 | | } SVCreateTbBatchRsp; |
6332 | | |
6333 | | int tEncodeSVCreateTbBatchRsp(SEncoder* pCoder, const SVCreateTbBatchRsp* pRsp); |
6334 | | int tDecodeSVCreateTbBatchRsp(SDecoder* pCoder, SVCreateTbBatchRsp* pRsp); |
6335 | | |
6336 | | // int32_t tSerializeSVCreateTbBatchRsp(void* buf, int32_t bufLen, SVCreateTbBatchRsp* pRsp); |
6337 | | // int32_t tDeserializeSVCreateTbBatchRsp(void* buf, int32_t bufLen, SVCreateTbBatchRsp* pRsp); |
6338 | | |
6339 | | // TDMT_VND_DROP_TABLE ================= |
6340 | | typedef struct { |
6341 | | char* name; |
6342 | | uint64_t suid; // for tmq in wal format |
6343 | | int64_t uid; |
6344 | | int8_t igNotExists; |
6345 | | int8_t isVirtual; |
6346 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
6347 | | } SVDropTbReq; |
6348 | | |
6349 | | typedef struct { |
6350 | | int32_t code; |
6351 | | } SVDropTbRsp; |
6352 | | |
6353 | | typedef struct { |
6354 | | int32_t nReqs; |
6355 | | union { |
6356 | | SVDropTbReq* pReqs; |
6357 | | SArray* pArray; |
6358 | | }; |
6359 | | } SVDropTbBatchReq; |
6360 | | |
6361 | | int32_t tEncodeSVDropTbBatchReq(SEncoder* pCoder, const SVDropTbBatchReq* pReq); |
6362 | | int32_t tDecodeSVDropTbBatchReq(SDecoder* pCoder, SVDropTbBatchReq* pReq); |
6363 | | |
6364 | | typedef struct { |
6365 | | int32_t nRsps; |
6366 | | union { |
6367 | | SVDropTbRsp* pRsps; |
6368 | | SArray* pArray; |
6369 | | }; |
6370 | | } SVDropTbBatchRsp; |
6371 | | |
6372 | | int32_t tEncodeSVDropTbBatchRsp(SEncoder* pCoder, const SVDropTbBatchRsp* pRsp); |
6373 | | int32_t tDecodeSVDropTbBatchRsp(SDecoder* pCoder, SVDropTbBatchRsp* pRsp); |
6374 | | |
6375 | | // TDMT_VND_ALTER_TABLE ===================== |
6376 | | typedef struct SUpdatedTagVal { |
6377 | | char* tagName; |
6378 | | int32_t colId; |
6379 | | int8_t tagType; |
6380 | | int8_t tagFree; |
6381 | | uint32_t nTagVal; |
6382 | | uint8_t* pTagVal; |
6383 | | int8_t isNull; |
6384 | | SArray* pTagArray; |
6385 | | // NOTE: regexp and replacement are only a temporary solution for tag value update, |
6386 | | // they should be replaced by a more generic solution in the future for full expression |
6387 | | // support |
6388 | | char* regexp; |
6389 | | char* replacement; |
6390 | | } SUpdatedTagVal; |
6391 | | |
6392 | | typedef struct SUpdateTableTagVal { |
6393 | | char *tbName; |
6394 | | SArray* tags; // Array of SUpdatedTagVal |
6395 | | } SUpdateTableTagVal; |
6396 | | |
6397 | | |
6398 | | typedef struct SVAlterTbReq { |
6399 | | char* tbName; |
6400 | | int8_t action; |
6401 | | char* colName; |
6402 | | int32_t colId; |
6403 | | // TSDB_ALTER_TABLE_ADD_COLUMN |
6404 | | int8_t type; |
6405 | | int8_t flags; |
6406 | | int32_t bytes; |
6407 | | // TSDB_ALTER_TABLE_DROP_COLUMN |
6408 | | // TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES |
6409 | | int8_t colModType; |
6410 | | int32_t colModBytes; |
6411 | | char* colNewName; // TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME |
6412 | | char* tagName; // TSDB_ALTER_TABLE_UPDATE_TAG_VAL |
6413 | | int8_t isNull; |
6414 | | int8_t tagType; |
6415 | | int8_t tagFree; |
6416 | | uint32_t nTagVal; |
6417 | | uint8_t* pTagVal; |
6418 | | SArray* pTagArray; |
6419 | | // TSDB_ALTER_TABLE_UPDATE_OPTIONS |
6420 | | int8_t updateTTL; |
6421 | | int32_t newTTL; |
6422 | | int32_t newCommentLen; |
6423 | | char* newComment; |
6424 | | int64_t ctimeMs; // fill by vnode |
6425 | | int8_t source; // TD_REQ_FROM_TAOX-taosX or TD_REQ_FROM_APP-taosClient |
6426 | | uint32_t compress; // TSDB_ALTER_TABLE_UPDATE_COLUMN_COMPRESS |
6427 | | SArray* pMultiTag; // TSDB_ALTER_TABLE_ADD_MULTI_TAGS and TSDB_ALTER_TABLE_UPDATE_CHILD_TABLE_TAG_VAL |
6428 | | SArray* tables; // Array of SUpdateTableTagVal, for TSDB_ALTER_TABLE_UPDATE_MULTI_TABLE_TAG_VAL |
6429 | | int32_t whereLen; // [whereLen] & [where] are for TSDB_ALTER_TABLE_UPDATE_CHILD_TABLE_TAG_VAL, |
6430 | | uint8_t* where; // [where] is the encode where condition. |
6431 | | // for Add column |
6432 | | STypeMod typeMod; |
6433 | | // TSDB_ALTER_TABLE_ALTER_COLUMN_REF / TSDB_ALTER_TABLE_ALTER_TAG_REF |
6434 | | char* refDbName; |
6435 | | char* refTbName; |
6436 | | char* refColName; |
6437 | | char* refSourceName; |
6438 | | // External schema segment of the reference (SQL Server 5-part paths; empty otherwise). |
6439 | | // Encoded as the last field of the message so that older readers simply ignore it and |
6440 | | // this decoder treats its absence as empty (same pattern as txnDdlQuota). |
6441 | | char* refSchemaName; |
6442 | | int8_t refType; // 0=local, 1=external |
6443 | | int32_t filterCondLen; |
6444 | | char* filterCondJson; |
6445 | | // TSDB_ALTER_TABLE_REMOVE_COLUMN_REF |
6446 | | // TSDB_ALTER_TABLE_ADD_SERIES |
6447 | | char* seriesAlias; |
6448 | | char* seriesSourceName; |
6449 | | char* seriesDbName; |
6450 | | char* seriesMeasurementName; |
6451 | | int32_t seriesTagCondLen; |
6452 | | char* seriesTagCondJson; |
6453 | | // TSDB_ALTER_TABLE_REMOVE_SERIES - uses seriesAlias above |
6454 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
6455 | | // Per-vnode share of the remaining TSDB_TXN_MAX_DDL_OPS_PER_TXN budget, for |
6456 | | // TSDB_ALTER_TABLE_UPDATE_CHILD_TABLE_TAG_VAL only. The client cannot know how many |
6457 | | // children a WHERE predicate matches (tag values live on the vnode, and inside a txn the |
6458 | | // predicate must be evaluated against uncommitted shadow state), so it sends the quota it |
6459 | | // can afford and the vnode aborts its pre-scan once the match count exceeds it. 0 = no |
6460 | | // limit (non-txn path). See metaPreScanChildTableTagUpdate. |
6461 | | int32_t txnDdlQuota; |
6462 | | } SVAlterTbReq; |
6463 | | |
6464 | | int32_t tEncodeSVAlterTbReq(SEncoder* pEncoder, const SVAlterTbReq* pReq); |
6465 | | int32_t tDecodeSVAlterTbReq(SDecoder* pDecoder, SVAlterTbReq* pReq); |
6466 | | void destroyAlterTbReq(SVAlterTbReq* pReq); |
6467 | | int32_t tDecodeSVAlterTbReqSetCtime(SDecoder* pDecoder, SVAlterTbReq* pReq, int64_t ctimeMs); |
6468 | | void tfreeMultiTagUpdateVal(void* pMultiTag); |
6469 | | void tfreeUpdateTableTagVal(void* pMultiTable); |
6470 | | |
6471 | | typedef struct { |
6472 | | int32_t code; |
6473 | | STableMetaRsp* pMeta; |
6474 | | // Number of child tables this vnode actually rewrote, for |
6475 | | // TSDB_ALTER_TABLE_UPDATE_CHILD_TABLE_TAG_VAL (WHERE-based bulk tag update) inside a |
6476 | | // txn. The vnode fills this in when that action runs with txnId != 0 |
6477 | | // (vnodeProcessAlterTbReq, txn path); it stays 0 on the non-txn path and for all |
6478 | | // other action types. Only txn callers consume it: the client sums this across |
6479 | | // vgroups into txnDdlCount so the per-object accounting in FS Sec.4.13 reflects the |
6480 | | // real object count for a statement whose reach is only knowable server-side. |
6481 | | int32_t numTouched; |
6482 | | } SVAlterTbRsp; |
6483 | | |
6484 | | int32_t tEncodeSVAlterTbRsp(SEncoder* pEncoder, const SVAlterTbRsp* pRsp); |
6485 | | int32_t tDecodeSVAlterTbRsp(SDecoder* pDecoder, SVAlterTbRsp* pRsp); |
6486 | | // ====================== |
6487 | | |
6488 | | typedef struct { |
6489 | | SMsgHead head; |
6490 | | int64_t uid; |
6491 | | int32_t tid; |
6492 | | int16_t tversion; |
6493 | | int16_t colId; |
6494 | | int8_t type; |
6495 | | int16_t bytes; |
6496 | | int32_t tagValLen; |
6497 | | int16_t numOfTags; |
6498 | | int32_t schemaLen; |
6499 | | char data[]; |
6500 | | } SUpdateTagValReq; |
6501 | | |
6502 | | typedef struct { |
6503 | | SMsgHead head; |
6504 | | } SUpdateTagValRsp; |
6505 | | |
6506 | | typedef struct { |
6507 | | SMsgHead head; |
6508 | | } SVShowTablesReq; |
6509 | | |
6510 | | typedef struct { |
6511 | | SMsgHead head; |
6512 | | int32_t id; |
6513 | | } SVShowTablesFetchReq; |
6514 | | |
6515 | | typedef struct { |
6516 | | int64_t useconds; |
6517 | | int8_t completed; // all results are returned to client |
6518 | | int8_t precision; |
6519 | | int8_t compressed; |
6520 | | int32_t compLen; |
6521 | | int32_t numOfRows; |
6522 | | char data[]; |
6523 | | } SVShowTablesFetchRsp; |
6524 | | |
6525 | | typedef struct { |
6526 | | int64_t consumerId; |
6527 | | int32_t epoch; |
6528 | | char cgroup[TSDB_CGROUP_LEN]; |
6529 | | } SMqAskEpReq; |
6530 | | |
6531 | | typedef struct { |
6532 | | int32_t key; |
6533 | | int32_t valueLen; |
6534 | | void* value; |
6535 | | } SKv; |
6536 | | |
6537 | | typedef struct { |
6538 | | int64_t tscRid; |
6539 | | int8_t connType; |
6540 | | } SClientHbKey; |
6541 | | |
6542 | | typedef struct { |
6543 | | int64_t tid; |
6544 | | char status[TSDB_JOB_STATUS_LEN]; |
6545 | | int64_t startTs; // sub-task first execution start time, us |
6546 | | } SQuerySubDesc; |
6547 | | |
6548 | | typedef enum EQueryExecPhase { |
6549 | | /* Main phases: 0-9 */ |
6550 | | QUERY_PHASE_NONE = 0, |
6551 | | QUERY_PHASE_PARSE = 1, |
6552 | | QUERY_PHASE_CATALOG = 2, |
6553 | | QUERY_PHASE_PLAN = 3, |
6554 | | QUERY_PHASE_SCHEDULE = 4, |
6555 | | QUERY_PHASE_EXECUTE = 5, |
6556 | | QUERY_PHASE_FETCH = 6, |
6557 | | QUERY_PHASE_DONE = 7, |
6558 | | |
6559 | | /* SCHEDULE sub-phases: 4x */ |
6560 | | QUERY_PHASE_SCHEDULE_ANALYSIS = 41, |
6561 | | QUERY_PHASE_SCHEDULE_PLANNING = 42, |
6562 | | QUERY_PHASE_SCHEDULE_NODE_SELECTION = 43, |
6563 | | |
6564 | | /* EXECUTE sub-phases: 5x */ |
6565 | | QUERY_PHASE_EXEC_DATA_QUERY = 51, |
6566 | | QUERY_PHASE_EXEC_MERGE_QUERY = 52, |
6567 | | QUERY_PHASE_EXEC_WAITING_CHILDREN = 53, |
6568 | | |
6569 | | /* FETCH sub-phases: 6x */ |
6570 | | QUERY_PHASE_FETCH_IN_PROGRESS = 60, // A single fetch operation is in progress |
6571 | | QUERY_PHASE_FETCH_RETURNED = 61, // Data returned to client, business logic processing |
6572 | | } EQueryExecPhase; |
6573 | | |
6574 | | const char* queryPhaseStr(int32_t phase); |
6575 | | |
6576 | | typedef struct { |
6577 | | char sql[TSDB_SHOW_SQL_LEN]; |
6578 | | uint64_t queryId; |
6579 | | int64_t useconds; |
6580 | | int64_t stime; // timestamp precision ms |
6581 | | int64_t reqRid; |
6582 | | bool stableQuery; |
6583 | | bool isSubQuery; |
6584 | | char fqdn[TSDB_FQDN_LEN]; |
6585 | | int32_t subPlanNum; |
6586 | | SArray* subDesc; // SArray<SQuerySubDesc> |
6587 | | int32_t execPhase; // EQueryExecPhase |
6588 | | int64_t phaseStartTime; // when current phase started, ms |
6589 | | } SQueryDesc; |
6590 | | |
6591 | | typedef struct { |
6592 | | uint32_t connId; |
6593 | | SArray* queryDesc; // SArray<SQueryDesc> |
6594 | | } SQueryHbReqBasic; |
6595 | | |
6596 | | // values for SQueryHbRspBasic.killConnection |
6597 | | #define HB_KILL_CONN 1 // close the connection (e.g. KILL CONNECTION) |
6598 | | #define HB_KILL_CONN_AUTH 2 // password changed after login; reject access with auth failure |
6599 | | |
6600 | | typedef struct { |
6601 | | uint32_t connId; |
6602 | | uint64_t killRid; |
6603 | | int32_t totalDnodes; |
6604 | | int32_t onlineDnodes; |
6605 | | int8_t killConnection; // HB_KILL_CONN_*: 0 keep, 1 close, 2 reject with auth failure |
6606 | | int8_t align[3]; |
6607 | | SEpSet epSet; |
6608 | | SArray* pQnodeList; |
6609 | | } SQueryHbRspBasic; |
6610 | | |
6611 | | typedef struct SAppClusterSummary { |
6612 | | uint64_t numOfInsertsReq; |
6613 | | uint64_t numOfInsertRows; |
6614 | | uint64_t insertElapsedTime; |
6615 | | uint64_t insertBytes; // submit to tsdb since launched. |
6616 | | |
6617 | | uint64_t fetchBytes; |
6618 | | uint64_t numOfQueryReq; |
6619 | | uint64_t queryElapsedTime; |
6620 | | uint64_t numOfSlowQueries; |
6621 | | uint64_t totalRequests; |
6622 | | uint64_t currentRequests; // the number of SRequestObj |
6623 | | } SAppClusterSummary; |
6624 | | |
6625 | | typedef struct { |
6626 | | int64_t appId; |
6627 | | int32_t pid; |
6628 | | char name[TSDB_APP_NAME_LEN]; |
6629 | | int64_t startTime; |
6630 | | SAppClusterSummary summary; |
6631 | | } SAppHbReq; |
6632 | | |
6633 | | typedef struct { |
6634 | | SClientHbKey connKey; |
6635 | | int64_t clusterId; |
6636 | | SAppHbReq app; |
6637 | | SQueryHbReqBasic* query; |
6638 | | SHashObj* info; // hash<Skv.key, Skv> |
6639 | | char user[TSDB_USER_LEN]; |
6640 | | char tokenName[TSDB_TOKEN_NAME_LEN]; |
6641 | | char userApp[TSDB_APP_NAME_LEN]; |
6642 | | uint32_t userIp; |
6643 | | SIpRange userDualIp; |
6644 | | char sVer[TSDB_VERSION_LEN]; |
6645 | | char cInfo[CONNECTOR_INFO_LEN]; |
6646 | | int32_t passVer; // password version the client authenticated with (-1: not reported) |
6647 | | } SClientHbReq; |
6648 | | |
6649 | | typedef struct { |
6650 | | int64_t reqId; |
6651 | | SArray* reqs; // SArray<SClientHbReq> |
6652 | | int64_t ipWhiteListVer; |
6653 | | } SClientHbBatchReq; |
6654 | | |
6655 | | typedef struct { |
6656 | | SClientHbKey connKey; |
6657 | | int32_t status; |
6658 | | SQueryHbRspBasic* query; |
6659 | | SArray* info; // Array<Skv> |
6660 | | } SClientHbRsp; |
6661 | | |
6662 | | typedef struct { |
6663 | | int64_t reqId; |
6664 | | int64_t rspId; |
6665 | | int32_t svrTimestamp; |
6666 | | SArray* rsps; // SArray<SClientHbRsp> |
6667 | | SMonitorParas monitorParas; |
6668 | | int8_t enableAuditDelete; |
6669 | | int8_t enableStrongPass; |
6670 | | int8_t enableAuditSelect; |
6671 | | int8_t enableAuditInsert; |
6672 | | int8_t auditLevel; |
6673 | | union { |
6674 | | uint32_t flags; |
6675 | | struct { |
6676 | | uint32_t sodInitial : 1; // cluster-wide: 1 = SoD still in initial phase |
6677 | | uint32_t macActive : 1; // cluster-wide: 1 = MAC mandatory mode activated |
6678 | | uint32_t reserved : 30; |
6679 | | }; |
6680 | | }; |
6681 | | } SClientHbBatchRsp; |
6682 | | |
6683 | 0 | static FORCE_INLINE uint32_t hbKeyHashFunc(const char* key, uint32_t keyLen) { return taosIntHash_64(key, keyLen); }Unexecuted instantiation: sql-fuzzer.c:hbKeyHashFunc Unexecuted instantiation: parser.c:hbKeyHashFunc Unexecuted instantiation: parTranslater.c:hbKeyHashFunc Unexecuted instantiation: parUtil.c:hbKeyHashFunc Unexecuted instantiation: parAstParser.c:hbKeyHashFunc Unexecuted instantiation: parAuthenticator.c:hbKeyHashFunc Unexecuted instantiation: parCalcConst.c:hbKeyHashFunc Unexecuted instantiation: parInsertSql.c:hbKeyHashFunc Unexecuted instantiation: parInsertUtil.c:hbKeyHashFunc Unexecuted instantiation: taos_lemon_sql.tab.c:hbKeyHashFunc Unexecuted instantiation: parAstCreater.c:hbKeyHashFunc Unexecuted instantiation: parInsertSml.c:hbKeyHashFunc Unexecuted instantiation: planner.c:hbKeyHashFunc Unexecuted instantiation: planLogicCreater.c:hbKeyHashFunc Unexecuted instantiation: planOptimizer.c:hbKeyHashFunc Unexecuted instantiation: planPhysiCreater.c:hbKeyHashFunc Unexecuted instantiation: planScaleOut.c:hbKeyHashFunc Unexecuted instantiation: planSpliter.c:hbKeyHashFunc Unexecuted instantiation: planUtil.c:hbKeyHashFunc Unexecuted instantiation: planValidator.c:hbKeyHashFunc Unexecuted instantiation: catalog.c:hbKeyHashFunc Unexecuted instantiation: ctgAsync.c:hbKeyHashFunc Unexecuted instantiation: ctgCache.c:hbKeyHashFunc Unexecuted instantiation: ctgDbg.c:hbKeyHashFunc Unexecuted instantiation: ctgRemote.c:hbKeyHashFunc Unexecuted instantiation: ctgRent.c:hbKeyHashFunc Unexecuted instantiation: ctgUtil.c:hbKeyHashFunc Unexecuted instantiation: extConnector.c:hbKeyHashFunc Unexecuted instantiation: extDialect.c:hbKeyHashFunc Unexecuted instantiation: extDialectDefaults.c:hbKeyHashFunc Unexecuted instantiation: functionMgt.c:hbKeyHashFunc Unexecuted instantiation: tudf.c:hbKeyHashFunc Unexecuted instantiation: builtins.c:hbKeyHashFunc Unexecuted instantiation: builtinsimpl.c:hbKeyHashFunc Unexecuted instantiation: spillDistinctSet.c:hbKeyHashFunc Unexecuted instantiation: thistogram.c:hbKeyHashFunc Unexecuted instantiation: tpercentile.c:hbKeyHashFunc Unexecuted instantiation: tavgfunction.c:hbKeyHashFunc Unexecuted instantiation: tminmax.c:hbKeyHashFunc Unexecuted instantiation: tminmaxavx.c:hbKeyHashFunc Unexecuted instantiation: filter.c:hbKeyHashFunc Unexecuted instantiation: scalar.c:hbKeyHashFunc Unexecuted instantiation: sclfunc.c:hbKeyHashFunc Unexecuted instantiation: sclvector.c:hbKeyHashFunc Unexecuted instantiation: nodesCloneFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesCodeFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesEqualFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesMatchFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesMsgFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesRemotePlanToSQL.c:hbKeyHashFunc Unexecuted instantiation: nodesToSQLFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesTraverseFuncs.c:hbKeyHashFunc Unexecuted instantiation: nodesUtilFuncs.c:hbKeyHashFunc Unexecuted instantiation: extTypeMap.c:hbKeyHashFunc Unexecuted instantiation: queryUtil.c:hbKeyHashFunc Unexecuted instantiation: querymsg.c:hbKeyHashFunc Unexecuted instantiation: trans.c:hbKeyHashFunc Unexecuted instantiation: transCli.c:hbKeyHashFunc Unexecuted instantiation: transComm.c:hbKeyHashFunc Unexecuted instantiation: transSasl.c:hbKeyHashFunc Unexecuted instantiation: transSvr.c:hbKeyHashFunc Unexecuted instantiation: transTLS.c:hbKeyHashFunc Unexecuted instantiation: thttp.c:hbKeyHashFunc Unexecuted instantiation: geomFunc.c:hbKeyHashFunc Unexecuted instantiation: tconfig.c:hbKeyHashFunc Unexecuted instantiation: tdigest.c:hbKeyHashFunc Unexecuted instantiation: tlog.c:hbKeyHashFunc Unexecuted instantiation: tmempool.c:hbKeyHashFunc Unexecuted instantiation: tpagedbuf.c:hbKeyHashFunc Unexecuted instantiation: mpDirect.c:hbKeyHashFunc Unexecuted instantiation: extCapability.c:hbKeyHashFunc Unexecuted instantiation: systable.c:hbKeyHashFunc Unexecuted instantiation: tanalytics.c:hbKeyHashFunc Unexecuted instantiation: tdatablock.c:hbKeyHashFunc Unexecuted instantiation: tdataformat.c:hbKeyHashFunc Unexecuted instantiation: tglobal.c:hbKeyHashFunc Unexecuted instantiation: tmisce.c:hbKeyHashFunc Unexecuted instantiation: tname.c:hbKeyHashFunc Unexecuted instantiation: tpriv.c:hbKeyHashFunc Unexecuted instantiation: ttime.c:hbKeyHashFunc Unexecuted instantiation: tvariant.c:hbKeyHashFunc Unexecuted instantiation: streamMsg.c:hbKeyHashFunc Unexecuted instantiation: streamWindowPlan.c:hbKeyHashFunc Unexecuted instantiation: tmsg.c:hbKeyHashFunc Unexecuted instantiation: xnode.c:hbKeyHashFunc Unexecuted instantiation: tencrypt.c:hbKeyHashFunc Unexecuted instantiation: streamJson.c:hbKeyHashFunc Unexecuted instantiation: crypt.c:hbKeyHashFunc |
6684 | | |
6685 | 0 | static FORCE_INLINE void tFreeReqKvHash(SHashObj* info) { |
6686 | 0 | void* pIter = taosHashIterate(info, NULL); |
6687 | 0 | while (pIter != NULL) { |
6688 | 0 | SKv* kv = (SKv*)pIter; |
6689 | 0 | taosMemoryFreeClear(kv->value); |
6690 | 0 | pIter = taosHashIterate(info, pIter); |
6691 | 0 | } |
6692 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeReqKvHash Unexecuted instantiation: parser.c:tFreeReqKvHash Unexecuted instantiation: parTranslater.c:tFreeReqKvHash Unexecuted instantiation: parUtil.c:tFreeReqKvHash Unexecuted instantiation: parAstParser.c:tFreeReqKvHash Unexecuted instantiation: parAuthenticator.c:tFreeReqKvHash Unexecuted instantiation: parCalcConst.c:tFreeReqKvHash Unexecuted instantiation: parInsertSql.c:tFreeReqKvHash Unexecuted instantiation: parInsertUtil.c:tFreeReqKvHash Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeReqKvHash Unexecuted instantiation: parAstCreater.c:tFreeReqKvHash Unexecuted instantiation: parInsertSml.c:tFreeReqKvHash Unexecuted instantiation: planner.c:tFreeReqKvHash Unexecuted instantiation: planLogicCreater.c:tFreeReqKvHash Unexecuted instantiation: planOptimizer.c:tFreeReqKvHash Unexecuted instantiation: planPhysiCreater.c:tFreeReqKvHash Unexecuted instantiation: planScaleOut.c:tFreeReqKvHash Unexecuted instantiation: planSpliter.c:tFreeReqKvHash Unexecuted instantiation: planUtil.c:tFreeReqKvHash Unexecuted instantiation: planValidator.c:tFreeReqKvHash Unexecuted instantiation: catalog.c:tFreeReqKvHash Unexecuted instantiation: ctgAsync.c:tFreeReqKvHash Unexecuted instantiation: ctgCache.c:tFreeReqKvHash Unexecuted instantiation: ctgDbg.c:tFreeReqKvHash Unexecuted instantiation: ctgRemote.c:tFreeReqKvHash Unexecuted instantiation: ctgRent.c:tFreeReqKvHash Unexecuted instantiation: ctgUtil.c:tFreeReqKvHash Unexecuted instantiation: extConnector.c:tFreeReqKvHash Unexecuted instantiation: extDialect.c:tFreeReqKvHash Unexecuted instantiation: extDialectDefaults.c:tFreeReqKvHash Unexecuted instantiation: functionMgt.c:tFreeReqKvHash Unexecuted instantiation: tudf.c:tFreeReqKvHash Unexecuted instantiation: builtins.c:tFreeReqKvHash Unexecuted instantiation: builtinsimpl.c:tFreeReqKvHash Unexecuted instantiation: spillDistinctSet.c:tFreeReqKvHash Unexecuted instantiation: thistogram.c:tFreeReqKvHash Unexecuted instantiation: tpercentile.c:tFreeReqKvHash Unexecuted instantiation: tavgfunction.c:tFreeReqKvHash Unexecuted instantiation: tminmax.c:tFreeReqKvHash Unexecuted instantiation: tminmaxavx.c:tFreeReqKvHash Unexecuted instantiation: filter.c:tFreeReqKvHash Unexecuted instantiation: scalar.c:tFreeReqKvHash Unexecuted instantiation: sclfunc.c:tFreeReqKvHash Unexecuted instantiation: sclvector.c:tFreeReqKvHash Unexecuted instantiation: nodesCloneFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesCodeFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesEqualFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesMatchFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesMsgFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeReqKvHash Unexecuted instantiation: nodesToSQLFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesTraverseFuncs.c:tFreeReqKvHash Unexecuted instantiation: nodesUtilFuncs.c:tFreeReqKvHash Unexecuted instantiation: extTypeMap.c:tFreeReqKvHash Unexecuted instantiation: queryUtil.c:tFreeReqKvHash Unexecuted instantiation: querymsg.c:tFreeReqKvHash Unexecuted instantiation: trans.c:tFreeReqKvHash Unexecuted instantiation: transCli.c:tFreeReqKvHash Unexecuted instantiation: transComm.c:tFreeReqKvHash Unexecuted instantiation: transSasl.c:tFreeReqKvHash Unexecuted instantiation: transSvr.c:tFreeReqKvHash Unexecuted instantiation: transTLS.c:tFreeReqKvHash Unexecuted instantiation: thttp.c:tFreeReqKvHash Unexecuted instantiation: geomFunc.c:tFreeReqKvHash Unexecuted instantiation: tconfig.c:tFreeReqKvHash Unexecuted instantiation: tdigest.c:tFreeReqKvHash Unexecuted instantiation: tlog.c:tFreeReqKvHash Unexecuted instantiation: tmempool.c:tFreeReqKvHash Unexecuted instantiation: tpagedbuf.c:tFreeReqKvHash Unexecuted instantiation: mpDirect.c:tFreeReqKvHash Unexecuted instantiation: extCapability.c:tFreeReqKvHash Unexecuted instantiation: systable.c:tFreeReqKvHash Unexecuted instantiation: tanalytics.c:tFreeReqKvHash Unexecuted instantiation: tdatablock.c:tFreeReqKvHash Unexecuted instantiation: tdataformat.c:tFreeReqKvHash Unexecuted instantiation: tglobal.c:tFreeReqKvHash Unexecuted instantiation: tmisce.c:tFreeReqKvHash Unexecuted instantiation: tname.c:tFreeReqKvHash Unexecuted instantiation: tpriv.c:tFreeReqKvHash Unexecuted instantiation: ttime.c:tFreeReqKvHash Unexecuted instantiation: tvariant.c:tFreeReqKvHash Unexecuted instantiation: streamMsg.c:tFreeReqKvHash Unexecuted instantiation: streamWindowPlan.c:tFreeReqKvHash Unexecuted instantiation: tmsg.c:tFreeReqKvHash Unexecuted instantiation: xnode.c:tFreeReqKvHash Unexecuted instantiation: tencrypt.c:tFreeReqKvHash Unexecuted instantiation: streamJson.c:tFreeReqKvHash Unexecuted instantiation: crypt.c:tFreeReqKvHash |
6693 | | |
6694 | 0 | static FORCE_INLINE void tFreeClientHbQueryDesc(void* pDesc) { |
6695 | 0 | SQueryDesc* desc = (SQueryDesc*)pDesc; |
6696 | 0 | if (desc->subDesc) { |
6697 | 0 | taosArrayDestroy(desc->subDesc); |
6698 | 0 | desc->subDesc = NULL; |
6699 | 0 | } |
6700 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientHbQueryDesc Unexecuted instantiation: parser.c:tFreeClientHbQueryDesc Unexecuted instantiation: parTranslater.c:tFreeClientHbQueryDesc Unexecuted instantiation: parUtil.c:tFreeClientHbQueryDesc Unexecuted instantiation: parAstParser.c:tFreeClientHbQueryDesc Unexecuted instantiation: parAuthenticator.c:tFreeClientHbQueryDesc Unexecuted instantiation: parCalcConst.c:tFreeClientHbQueryDesc Unexecuted instantiation: parInsertSql.c:tFreeClientHbQueryDesc Unexecuted instantiation: parInsertUtil.c:tFreeClientHbQueryDesc Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientHbQueryDesc Unexecuted instantiation: parAstCreater.c:tFreeClientHbQueryDesc Unexecuted instantiation: parInsertSml.c:tFreeClientHbQueryDesc Unexecuted instantiation: planner.c:tFreeClientHbQueryDesc Unexecuted instantiation: planLogicCreater.c:tFreeClientHbQueryDesc Unexecuted instantiation: planOptimizer.c:tFreeClientHbQueryDesc Unexecuted instantiation: planPhysiCreater.c:tFreeClientHbQueryDesc Unexecuted instantiation: planScaleOut.c:tFreeClientHbQueryDesc Unexecuted instantiation: planSpliter.c:tFreeClientHbQueryDesc Unexecuted instantiation: planUtil.c:tFreeClientHbQueryDesc Unexecuted instantiation: planValidator.c:tFreeClientHbQueryDesc Unexecuted instantiation: catalog.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgAsync.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgCache.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgDbg.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgRemote.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgRent.c:tFreeClientHbQueryDesc Unexecuted instantiation: ctgUtil.c:tFreeClientHbQueryDesc Unexecuted instantiation: extConnector.c:tFreeClientHbQueryDesc Unexecuted instantiation: extDialect.c:tFreeClientHbQueryDesc Unexecuted instantiation: extDialectDefaults.c:tFreeClientHbQueryDesc Unexecuted instantiation: functionMgt.c:tFreeClientHbQueryDesc Unexecuted instantiation: tudf.c:tFreeClientHbQueryDesc Unexecuted instantiation: builtins.c:tFreeClientHbQueryDesc Unexecuted instantiation: builtinsimpl.c:tFreeClientHbQueryDesc Unexecuted instantiation: spillDistinctSet.c:tFreeClientHbQueryDesc Unexecuted instantiation: thistogram.c:tFreeClientHbQueryDesc Unexecuted instantiation: tpercentile.c:tFreeClientHbQueryDesc Unexecuted instantiation: tavgfunction.c:tFreeClientHbQueryDesc Unexecuted instantiation: tminmax.c:tFreeClientHbQueryDesc Unexecuted instantiation: tminmaxavx.c:tFreeClientHbQueryDesc Unexecuted instantiation: filter.c:tFreeClientHbQueryDesc Unexecuted instantiation: scalar.c:tFreeClientHbQueryDesc Unexecuted instantiation: sclfunc.c:tFreeClientHbQueryDesc Unexecuted instantiation: sclvector.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientHbQueryDesc Unexecuted instantiation: extTypeMap.c:tFreeClientHbQueryDesc Unexecuted instantiation: queryUtil.c:tFreeClientHbQueryDesc Unexecuted instantiation: querymsg.c:tFreeClientHbQueryDesc Unexecuted instantiation: trans.c:tFreeClientHbQueryDesc Unexecuted instantiation: transCli.c:tFreeClientHbQueryDesc Unexecuted instantiation: transComm.c:tFreeClientHbQueryDesc Unexecuted instantiation: transSasl.c:tFreeClientHbQueryDesc Unexecuted instantiation: transSvr.c:tFreeClientHbQueryDesc Unexecuted instantiation: transTLS.c:tFreeClientHbQueryDesc Unexecuted instantiation: thttp.c:tFreeClientHbQueryDesc Unexecuted instantiation: geomFunc.c:tFreeClientHbQueryDesc Unexecuted instantiation: tconfig.c:tFreeClientHbQueryDesc Unexecuted instantiation: tdigest.c:tFreeClientHbQueryDesc Unexecuted instantiation: tlog.c:tFreeClientHbQueryDesc Unexecuted instantiation: tmempool.c:tFreeClientHbQueryDesc Unexecuted instantiation: tpagedbuf.c:tFreeClientHbQueryDesc Unexecuted instantiation: mpDirect.c:tFreeClientHbQueryDesc Unexecuted instantiation: extCapability.c:tFreeClientHbQueryDesc Unexecuted instantiation: systable.c:tFreeClientHbQueryDesc Unexecuted instantiation: tanalytics.c:tFreeClientHbQueryDesc Unexecuted instantiation: tdatablock.c:tFreeClientHbQueryDesc Unexecuted instantiation: tdataformat.c:tFreeClientHbQueryDesc Unexecuted instantiation: tglobal.c:tFreeClientHbQueryDesc Unexecuted instantiation: tmisce.c:tFreeClientHbQueryDesc Unexecuted instantiation: tname.c:tFreeClientHbQueryDesc Unexecuted instantiation: tpriv.c:tFreeClientHbQueryDesc Unexecuted instantiation: ttime.c:tFreeClientHbQueryDesc Unexecuted instantiation: tvariant.c:tFreeClientHbQueryDesc Unexecuted instantiation: streamMsg.c:tFreeClientHbQueryDesc Unexecuted instantiation: streamWindowPlan.c:tFreeClientHbQueryDesc Unexecuted instantiation: tmsg.c:tFreeClientHbQueryDesc Unexecuted instantiation: xnode.c:tFreeClientHbQueryDesc Unexecuted instantiation: tencrypt.c:tFreeClientHbQueryDesc Unexecuted instantiation: streamJson.c:tFreeClientHbQueryDesc Unexecuted instantiation: crypt.c:tFreeClientHbQueryDesc |
6701 | | |
6702 | 0 | static FORCE_INLINE void tFreeClientHbReq(void* pReq) { |
6703 | 0 | SClientHbReq* req = (SClientHbReq*)pReq; |
6704 | 0 | if (req->query) { |
6705 | 0 | if (req->query->queryDesc) { |
6706 | 0 | taosArrayDestroyEx(req->query->queryDesc, tFreeClientHbQueryDesc); |
6707 | 0 | } |
6708 | 0 | taosMemoryFreeClear(req->query); |
6709 | 0 | } |
6710 | |
|
6711 | 0 | if (req->info) { |
6712 | 0 | tFreeReqKvHash(req->info); |
6713 | 0 | taosHashCleanup(req->info); |
6714 | 0 | req->info = NULL; |
6715 | 0 | } |
6716 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientHbReq Unexecuted instantiation: parser.c:tFreeClientHbReq Unexecuted instantiation: parTranslater.c:tFreeClientHbReq Unexecuted instantiation: parUtil.c:tFreeClientHbReq Unexecuted instantiation: parAstParser.c:tFreeClientHbReq Unexecuted instantiation: parAuthenticator.c:tFreeClientHbReq Unexecuted instantiation: parCalcConst.c:tFreeClientHbReq Unexecuted instantiation: parInsertSql.c:tFreeClientHbReq Unexecuted instantiation: parInsertUtil.c:tFreeClientHbReq Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientHbReq Unexecuted instantiation: parAstCreater.c:tFreeClientHbReq Unexecuted instantiation: parInsertSml.c:tFreeClientHbReq Unexecuted instantiation: planner.c:tFreeClientHbReq Unexecuted instantiation: planLogicCreater.c:tFreeClientHbReq Unexecuted instantiation: planOptimizer.c:tFreeClientHbReq Unexecuted instantiation: planPhysiCreater.c:tFreeClientHbReq Unexecuted instantiation: planScaleOut.c:tFreeClientHbReq Unexecuted instantiation: planSpliter.c:tFreeClientHbReq Unexecuted instantiation: planUtil.c:tFreeClientHbReq Unexecuted instantiation: planValidator.c:tFreeClientHbReq Unexecuted instantiation: catalog.c:tFreeClientHbReq Unexecuted instantiation: ctgAsync.c:tFreeClientHbReq Unexecuted instantiation: ctgCache.c:tFreeClientHbReq Unexecuted instantiation: ctgDbg.c:tFreeClientHbReq Unexecuted instantiation: ctgRemote.c:tFreeClientHbReq Unexecuted instantiation: ctgRent.c:tFreeClientHbReq Unexecuted instantiation: ctgUtil.c:tFreeClientHbReq Unexecuted instantiation: extConnector.c:tFreeClientHbReq Unexecuted instantiation: extDialect.c:tFreeClientHbReq Unexecuted instantiation: extDialectDefaults.c:tFreeClientHbReq Unexecuted instantiation: functionMgt.c:tFreeClientHbReq Unexecuted instantiation: tudf.c:tFreeClientHbReq Unexecuted instantiation: builtins.c:tFreeClientHbReq Unexecuted instantiation: builtinsimpl.c:tFreeClientHbReq Unexecuted instantiation: spillDistinctSet.c:tFreeClientHbReq Unexecuted instantiation: thistogram.c:tFreeClientHbReq Unexecuted instantiation: tpercentile.c:tFreeClientHbReq Unexecuted instantiation: tavgfunction.c:tFreeClientHbReq Unexecuted instantiation: tminmax.c:tFreeClientHbReq Unexecuted instantiation: tminmaxavx.c:tFreeClientHbReq Unexecuted instantiation: filter.c:tFreeClientHbReq Unexecuted instantiation: scalar.c:tFreeClientHbReq Unexecuted instantiation: sclfunc.c:tFreeClientHbReq Unexecuted instantiation: sclvector.c:tFreeClientHbReq Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientHbReq Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientHbReq Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientHbReq Unexecuted instantiation: extTypeMap.c:tFreeClientHbReq Unexecuted instantiation: queryUtil.c:tFreeClientHbReq Unexecuted instantiation: querymsg.c:tFreeClientHbReq Unexecuted instantiation: trans.c:tFreeClientHbReq Unexecuted instantiation: transCli.c:tFreeClientHbReq Unexecuted instantiation: transComm.c:tFreeClientHbReq Unexecuted instantiation: transSasl.c:tFreeClientHbReq Unexecuted instantiation: transSvr.c:tFreeClientHbReq Unexecuted instantiation: transTLS.c:tFreeClientHbReq Unexecuted instantiation: thttp.c:tFreeClientHbReq Unexecuted instantiation: geomFunc.c:tFreeClientHbReq Unexecuted instantiation: tconfig.c:tFreeClientHbReq Unexecuted instantiation: tdigest.c:tFreeClientHbReq Unexecuted instantiation: tlog.c:tFreeClientHbReq Unexecuted instantiation: tmempool.c:tFreeClientHbReq Unexecuted instantiation: tpagedbuf.c:tFreeClientHbReq Unexecuted instantiation: mpDirect.c:tFreeClientHbReq Unexecuted instantiation: extCapability.c:tFreeClientHbReq Unexecuted instantiation: systable.c:tFreeClientHbReq Unexecuted instantiation: tanalytics.c:tFreeClientHbReq Unexecuted instantiation: tdatablock.c:tFreeClientHbReq Unexecuted instantiation: tdataformat.c:tFreeClientHbReq Unexecuted instantiation: tglobal.c:tFreeClientHbReq Unexecuted instantiation: tmisce.c:tFreeClientHbReq Unexecuted instantiation: tname.c:tFreeClientHbReq Unexecuted instantiation: tpriv.c:tFreeClientHbReq Unexecuted instantiation: ttime.c:tFreeClientHbReq Unexecuted instantiation: tvariant.c:tFreeClientHbReq Unexecuted instantiation: streamMsg.c:tFreeClientHbReq Unexecuted instantiation: streamWindowPlan.c:tFreeClientHbReq Unexecuted instantiation: tmsg.c:tFreeClientHbReq Unexecuted instantiation: xnode.c:tFreeClientHbReq Unexecuted instantiation: tencrypt.c:tFreeClientHbReq Unexecuted instantiation: streamJson.c:tFreeClientHbReq Unexecuted instantiation: crypt.c:tFreeClientHbReq |
6717 | | |
6718 | | int32_t tSerializeSClientHbBatchReq(void* buf, int32_t bufLen, const SClientHbBatchReq* pReq); |
6719 | | int32_t tDeserializeSClientHbBatchReq(void* buf, int32_t bufLen, SClientHbBatchReq* pReq); |
6720 | | |
6721 | 0 | static FORCE_INLINE void tFreeClientHbBatchReq(void* pReq) { |
6722 | 0 | if (pReq == NULL) return; |
6723 | 0 | SClientHbBatchReq* req = (SClientHbBatchReq*)pReq; |
6724 | 0 | taosArrayDestroyEx(req->reqs, tFreeClientHbReq); |
6725 | 0 | taosMemoryFree(pReq); |
6726 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientHbBatchReq Unexecuted instantiation: parser.c:tFreeClientHbBatchReq Unexecuted instantiation: parTranslater.c:tFreeClientHbBatchReq Unexecuted instantiation: parUtil.c:tFreeClientHbBatchReq Unexecuted instantiation: parAstParser.c:tFreeClientHbBatchReq Unexecuted instantiation: parAuthenticator.c:tFreeClientHbBatchReq Unexecuted instantiation: parCalcConst.c:tFreeClientHbBatchReq Unexecuted instantiation: parInsertSql.c:tFreeClientHbBatchReq Unexecuted instantiation: parInsertUtil.c:tFreeClientHbBatchReq Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientHbBatchReq Unexecuted instantiation: parAstCreater.c:tFreeClientHbBatchReq Unexecuted instantiation: parInsertSml.c:tFreeClientHbBatchReq Unexecuted instantiation: planner.c:tFreeClientHbBatchReq Unexecuted instantiation: planLogicCreater.c:tFreeClientHbBatchReq Unexecuted instantiation: planOptimizer.c:tFreeClientHbBatchReq Unexecuted instantiation: planPhysiCreater.c:tFreeClientHbBatchReq Unexecuted instantiation: planScaleOut.c:tFreeClientHbBatchReq Unexecuted instantiation: planSpliter.c:tFreeClientHbBatchReq Unexecuted instantiation: planUtil.c:tFreeClientHbBatchReq Unexecuted instantiation: planValidator.c:tFreeClientHbBatchReq Unexecuted instantiation: catalog.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgAsync.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgCache.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgDbg.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgRemote.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgRent.c:tFreeClientHbBatchReq Unexecuted instantiation: ctgUtil.c:tFreeClientHbBatchReq Unexecuted instantiation: extConnector.c:tFreeClientHbBatchReq Unexecuted instantiation: extDialect.c:tFreeClientHbBatchReq Unexecuted instantiation: extDialectDefaults.c:tFreeClientHbBatchReq Unexecuted instantiation: functionMgt.c:tFreeClientHbBatchReq Unexecuted instantiation: tudf.c:tFreeClientHbBatchReq Unexecuted instantiation: builtins.c:tFreeClientHbBatchReq Unexecuted instantiation: builtinsimpl.c:tFreeClientHbBatchReq Unexecuted instantiation: spillDistinctSet.c:tFreeClientHbBatchReq Unexecuted instantiation: thistogram.c:tFreeClientHbBatchReq Unexecuted instantiation: tpercentile.c:tFreeClientHbBatchReq Unexecuted instantiation: tavgfunction.c:tFreeClientHbBatchReq Unexecuted instantiation: tminmax.c:tFreeClientHbBatchReq Unexecuted instantiation: tminmaxavx.c:tFreeClientHbBatchReq Unexecuted instantiation: filter.c:tFreeClientHbBatchReq Unexecuted instantiation: scalar.c:tFreeClientHbBatchReq Unexecuted instantiation: sclfunc.c:tFreeClientHbBatchReq Unexecuted instantiation: sclvector.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientHbBatchReq Unexecuted instantiation: extTypeMap.c:tFreeClientHbBatchReq Unexecuted instantiation: queryUtil.c:tFreeClientHbBatchReq Unexecuted instantiation: querymsg.c:tFreeClientHbBatchReq Unexecuted instantiation: trans.c:tFreeClientHbBatchReq Unexecuted instantiation: transCli.c:tFreeClientHbBatchReq Unexecuted instantiation: transComm.c:tFreeClientHbBatchReq Unexecuted instantiation: transSasl.c:tFreeClientHbBatchReq Unexecuted instantiation: transSvr.c:tFreeClientHbBatchReq Unexecuted instantiation: transTLS.c:tFreeClientHbBatchReq Unexecuted instantiation: thttp.c:tFreeClientHbBatchReq Unexecuted instantiation: geomFunc.c:tFreeClientHbBatchReq Unexecuted instantiation: tconfig.c:tFreeClientHbBatchReq Unexecuted instantiation: tdigest.c:tFreeClientHbBatchReq Unexecuted instantiation: tlog.c:tFreeClientHbBatchReq Unexecuted instantiation: tmempool.c:tFreeClientHbBatchReq Unexecuted instantiation: tpagedbuf.c:tFreeClientHbBatchReq Unexecuted instantiation: mpDirect.c:tFreeClientHbBatchReq Unexecuted instantiation: extCapability.c:tFreeClientHbBatchReq Unexecuted instantiation: systable.c:tFreeClientHbBatchReq Unexecuted instantiation: tanalytics.c:tFreeClientHbBatchReq Unexecuted instantiation: tdatablock.c:tFreeClientHbBatchReq Unexecuted instantiation: tdataformat.c:tFreeClientHbBatchReq Unexecuted instantiation: tglobal.c:tFreeClientHbBatchReq Unexecuted instantiation: tmisce.c:tFreeClientHbBatchReq Unexecuted instantiation: tname.c:tFreeClientHbBatchReq Unexecuted instantiation: tpriv.c:tFreeClientHbBatchReq Unexecuted instantiation: ttime.c:tFreeClientHbBatchReq Unexecuted instantiation: tvariant.c:tFreeClientHbBatchReq Unexecuted instantiation: streamMsg.c:tFreeClientHbBatchReq Unexecuted instantiation: streamWindowPlan.c:tFreeClientHbBatchReq Unexecuted instantiation: tmsg.c:tFreeClientHbBatchReq Unexecuted instantiation: xnode.c:tFreeClientHbBatchReq Unexecuted instantiation: tencrypt.c:tFreeClientHbBatchReq Unexecuted instantiation: streamJson.c:tFreeClientHbBatchReq Unexecuted instantiation: crypt.c:tFreeClientHbBatchReq |
6727 | | |
6728 | 0 | static FORCE_INLINE void tFreeClientKv(void* pKv) { |
6729 | 0 | SKv* kv = (SKv*)pKv; |
6730 | 0 | if (kv) { |
6731 | 0 | taosMemoryFreeClear(kv->value); |
6732 | 0 | } |
6733 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientKv Unexecuted instantiation: parser.c:tFreeClientKv Unexecuted instantiation: parTranslater.c:tFreeClientKv Unexecuted instantiation: parUtil.c:tFreeClientKv Unexecuted instantiation: parAstParser.c:tFreeClientKv Unexecuted instantiation: parAuthenticator.c:tFreeClientKv Unexecuted instantiation: parCalcConst.c:tFreeClientKv Unexecuted instantiation: parInsertSql.c:tFreeClientKv Unexecuted instantiation: parInsertUtil.c:tFreeClientKv Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientKv Unexecuted instantiation: parAstCreater.c:tFreeClientKv Unexecuted instantiation: parInsertSml.c:tFreeClientKv Unexecuted instantiation: planner.c:tFreeClientKv Unexecuted instantiation: planLogicCreater.c:tFreeClientKv Unexecuted instantiation: planOptimizer.c:tFreeClientKv Unexecuted instantiation: planPhysiCreater.c:tFreeClientKv Unexecuted instantiation: planScaleOut.c:tFreeClientKv Unexecuted instantiation: planSpliter.c:tFreeClientKv Unexecuted instantiation: planUtil.c:tFreeClientKv Unexecuted instantiation: planValidator.c:tFreeClientKv Unexecuted instantiation: catalog.c:tFreeClientKv Unexecuted instantiation: ctgAsync.c:tFreeClientKv Unexecuted instantiation: ctgCache.c:tFreeClientKv Unexecuted instantiation: ctgDbg.c:tFreeClientKv Unexecuted instantiation: ctgRemote.c:tFreeClientKv Unexecuted instantiation: ctgRent.c:tFreeClientKv Unexecuted instantiation: ctgUtil.c:tFreeClientKv Unexecuted instantiation: extConnector.c:tFreeClientKv Unexecuted instantiation: extDialect.c:tFreeClientKv Unexecuted instantiation: extDialectDefaults.c:tFreeClientKv Unexecuted instantiation: functionMgt.c:tFreeClientKv Unexecuted instantiation: tudf.c:tFreeClientKv Unexecuted instantiation: builtins.c:tFreeClientKv Unexecuted instantiation: builtinsimpl.c:tFreeClientKv Unexecuted instantiation: spillDistinctSet.c:tFreeClientKv Unexecuted instantiation: thistogram.c:tFreeClientKv Unexecuted instantiation: tpercentile.c:tFreeClientKv Unexecuted instantiation: tavgfunction.c:tFreeClientKv Unexecuted instantiation: tminmax.c:tFreeClientKv Unexecuted instantiation: tminmaxavx.c:tFreeClientKv Unexecuted instantiation: filter.c:tFreeClientKv Unexecuted instantiation: scalar.c:tFreeClientKv Unexecuted instantiation: sclfunc.c:tFreeClientKv Unexecuted instantiation: sclvector.c:tFreeClientKv Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientKv Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientKv Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientKv Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientKv Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientKv Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientKv Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientKv Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientKv Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientKv Unexecuted instantiation: extTypeMap.c:tFreeClientKv Unexecuted instantiation: queryUtil.c:tFreeClientKv Unexecuted instantiation: querymsg.c:tFreeClientKv Unexecuted instantiation: trans.c:tFreeClientKv Unexecuted instantiation: transCli.c:tFreeClientKv Unexecuted instantiation: transComm.c:tFreeClientKv Unexecuted instantiation: transSasl.c:tFreeClientKv Unexecuted instantiation: transSvr.c:tFreeClientKv Unexecuted instantiation: transTLS.c:tFreeClientKv Unexecuted instantiation: thttp.c:tFreeClientKv Unexecuted instantiation: geomFunc.c:tFreeClientKv Unexecuted instantiation: tconfig.c:tFreeClientKv Unexecuted instantiation: tdigest.c:tFreeClientKv Unexecuted instantiation: tlog.c:tFreeClientKv Unexecuted instantiation: tmempool.c:tFreeClientKv Unexecuted instantiation: tpagedbuf.c:tFreeClientKv Unexecuted instantiation: mpDirect.c:tFreeClientKv Unexecuted instantiation: extCapability.c:tFreeClientKv Unexecuted instantiation: systable.c:tFreeClientKv Unexecuted instantiation: tanalytics.c:tFreeClientKv Unexecuted instantiation: tdatablock.c:tFreeClientKv Unexecuted instantiation: tdataformat.c:tFreeClientKv Unexecuted instantiation: tglobal.c:tFreeClientKv Unexecuted instantiation: tmisce.c:tFreeClientKv Unexecuted instantiation: tname.c:tFreeClientKv Unexecuted instantiation: tpriv.c:tFreeClientKv Unexecuted instantiation: ttime.c:tFreeClientKv Unexecuted instantiation: tvariant.c:tFreeClientKv Unexecuted instantiation: streamMsg.c:tFreeClientKv Unexecuted instantiation: streamWindowPlan.c:tFreeClientKv Unexecuted instantiation: tmsg.c:tFreeClientKv Unexecuted instantiation: xnode.c:tFreeClientKv Unexecuted instantiation: tencrypt.c:tFreeClientKv Unexecuted instantiation: streamJson.c:tFreeClientKv Unexecuted instantiation: crypt.c:tFreeClientKv |
6734 | | |
6735 | 0 | static FORCE_INLINE void tFreeClientHbRsp(void* pRsp) { |
6736 | 0 | SClientHbRsp* rsp = (SClientHbRsp*)pRsp; |
6737 | 0 | if (rsp->query) { |
6738 | 0 | taosArrayDestroy(rsp->query->pQnodeList); |
6739 | 0 | taosMemoryFreeClear(rsp->query); |
6740 | 0 | } |
6741 | 0 | if (rsp->info) taosArrayDestroyEx(rsp->info, tFreeClientKv); |
6742 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientHbRsp Unexecuted instantiation: parser.c:tFreeClientHbRsp Unexecuted instantiation: parTranslater.c:tFreeClientHbRsp Unexecuted instantiation: parUtil.c:tFreeClientHbRsp Unexecuted instantiation: parAstParser.c:tFreeClientHbRsp Unexecuted instantiation: parAuthenticator.c:tFreeClientHbRsp Unexecuted instantiation: parCalcConst.c:tFreeClientHbRsp Unexecuted instantiation: parInsertSql.c:tFreeClientHbRsp Unexecuted instantiation: parInsertUtil.c:tFreeClientHbRsp Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientHbRsp Unexecuted instantiation: parAstCreater.c:tFreeClientHbRsp Unexecuted instantiation: parInsertSml.c:tFreeClientHbRsp Unexecuted instantiation: planner.c:tFreeClientHbRsp Unexecuted instantiation: planLogicCreater.c:tFreeClientHbRsp Unexecuted instantiation: planOptimizer.c:tFreeClientHbRsp Unexecuted instantiation: planPhysiCreater.c:tFreeClientHbRsp Unexecuted instantiation: planScaleOut.c:tFreeClientHbRsp Unexecuted instantiation: planSpliter.c:tFreeClientHbRsp Unexecuted instantiation: planUtil.c:tFreeClientHbRsp Unexecuted instantiation: planValidator.c:tFreeClientHbRsp Unexecuted instantiation: catalog.c:tFreeClientHbRsp Unexecuted instantiation: ctgAsync.c:tFreeClientHbRsp Unexecuted instantiation: ctgCache.c:tFreeClientHbRsp Unexecuted instantiation: ctgDbg.c:tFreeClientHbRsp Unexecuted instantiation: ctgRemote.c:tFreeClientHbRsp Unexecuted instantiation: ctgRent.c:tFreeClientHbRsp Unexecuted instantiation: ctgUtil.c:tFreeClientHbRsp Unexecuted instantiation: extConnector.c:tFreeClientHbRsp Unexecuted instantiation: extDialect.c:tFreeClientHbRsp Unexecuted instantiation: extDialectDefaults.c:tFreeClientHbRsp Unexecuted instantiation: functionMgt.c:tFreeClientHbRsp Unexecuted instantiation: tudf.c:tFreeClientHbRsp Unexecuted instantiation: builtins.c:tFreeClientHbRsp Unexecuted instantiation: builtinsimpl.c:tFreeClientHbRsp Unexecuted instantiation: spillDistinctSet.c:tFreeClientHbRsp Unexecuted instantiation: thistogram.c:tFreeClientHbRsp Unexecuted instantiation: tpercentile.c:tFreeClientHbRsp Unexecuted instantiation: tavgfunction.c:tFreeClientHbRsp Unexecuted instantiation: tminmax.c:tFreeClientHbRsp Unexecuted instantiation: tminmaxavx.c:tFreeClientHbRsp Unexecuted instantiation: filter.c:tFreeClientHbRsp Unexecuted instantiation: scalar.c:tFreeClientHbRsp Unexecuted instantiation: sclfunc.c:tFreeClientHbRsp Unexecuted instantiation: sclvector.c:tFreeClientHbRsp Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientHbRsp Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientHbRsp Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientHbRsp Unexecuted instantiation: extTypeMap.c:tFreeClientHbRsp Unexecuted instantiation: queryUtil.c:tFreeClientHbRsp Unexecuted instantiation: querymsg.c:tFreeClientHbRsp Unexecuted instantiation: trans.c:tFreeClientHbRsp Unexecuted instantiation: transCli.c:tFreeClientHbRsp Unexecuted instantiation: transComm.c:tFreeClientHbRsp Unexecuted instantiation: transSasl.c:tFreeClientHbRsp Unexecuted instantiation: transSvr.c:tFreeClientHbRsp Unexecuted instantiation: transTLS.c:tFreeClientHbRsp Unexecuted instantiation: thttp.c:tFreeClientHbRsp Unexecuted instantiation: geomFunc.c:tFreeClientHbRsp Unexecuted instantiation: tconfig.c:tFreeClientHbRsp Unexecuted instantiation: tdigest.c:tFreeClientHbRsp Unexecuted instantiation: tlog.c:tFreeClientHbRsp Unexecuted instantiation: tmempool.c:tFreeClientHbRsp Unexecuted instantiation: tpagedbuf.c:tFreeClientHbRsp Unexecuted instantiation: mpDirect.c:tFreeClientHbRsp Unexecuted instantiation: extCapability.c:tFreeClientHbRsp Unexecuted instantiation: systable.c:tFreeClientHbRsp Unexecuted instantiation: tanalytics.c:tFreeClientHbRsp Unexecuted instantiation: tdatablock.c:tFreeClientHbRsp Unexecuted instantiation: tdataformat.c:tFreeClientHbRsp Unexecuted instantiation: tglobal.c:tFreeClientHbRsp Unexecuted instantiation: tmisce.c:tFreeClientHbRsp Unexecuted instantiation: tname.c:tFreeClientHbRsp Unexecuted instantiation: tpriv.c:tFreeClientHbRsp Unexecuted instantiation: ttime.c:tFreeClientHbRsp Unexecuted instantiation: tvariant.c:tFreeClientHbRsp Unexecuted instantiation: streamMsg.c:tFreeClientHbRsp Unexecuted instantiation: streamWindowPlan.c:tFreeClientHbRsp Unexecuted instantiation: tmsg.c:tFreeClientHbRsp Unexecuted instantiation: xnode.c:tFreeClientHbRsp Unexecuted instantiation: tencrypt.c:tFreeClientHbRsp Unexecuted instantiation: streamJson.c:tFreeClientHbRsp Unexecuted instantiation: crypt.c:tFreeClientHbRsp |
6743 | | |
6744 | 0 | static FORCE_INLINE void tFreeClientHbBatchRsp(void* pRsp) { |
6745 | 0 | SClientHbBatchRsp* rsp = (SClientHbBatchRsp*)pRsp; |
6746 | 0 | taosArrayDestroyEx(rsp->rsps, tFreeClientHbRsp); |
6747 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeClientHbBatchRsp Unexecuted instantiation: parser.c:tFreeClientHbBatchRsp Unexecuted instantiation: parTranslater.c:tFreeClientHbBatchRsp Unexecuted instantiation: parUtil.c:tFreeClientHbBatchRsp Unexecuted instantiation: parAstParser.c:tFreeClientHbBatchRsp Unexecuted instantiation: parAuthenticator.c:tFreeClientHbBatchRsp Unexecuted instantiation: parCalcConst.c:tFreeClientHbBatchRsp Unexecuted instantiation: parInsertSql.c:tFreeClientHbBatchRsp Unexecuted instantiation: parInsertUtil.c:tFreeClientHbBatchRsp Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeClientHbBatchRsp Unexecuted instantiation: parAstCreater.c:tFreeClientHbBatchRsp Unexecuted instantiation: parInsertSml.c:tFreeClientHbBatchRsp Unexecuted instantiation: planner.c:tFreeClientHbBatchRsp Unexecuted instantiation: planLogicCreater.c:tFreeClientHbBatchRsp Unexecuted instantiation: planOptimizer.c:tFreeClientHbBatchRsp Unexecuted instantiation: planPhysiCreater.c:tFreeClientHbBatchRsp Unexecuted instantiation: planScaleOut.c:tFreeClientHbBatchRsp Unexecuted instantiation: planSpliter.c:tFreeClientHbBatchRsp Unexecuted instantiation: planUtil.c:tFreeClientHbBatchRsp Unexecuted instantiation: planValidator.c:tFreeClientHbBatchRsp Unexecuted instantiation: catalog.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgAsync.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgCache.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgDbg.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgRemote.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgRent.c:tFreeClientHbBatchRsp Unexecuted instantiation: ctgUtil.c:tFreeClientHbBatchRsp Unexecuted instantiation: extConnector.c:tFreeClientHbBatchRsp Unexecuted instantiation: extDialect.c:tFreeClientHbBatchRsp Unexecuted instantiation: extDialectDefaults.c:tFreeClientHbBatchRsp Unexecuted instantiation: functionMgt.c:tFreeClientHbBatchRsp Unexecuted instantiation: tudf.c:tFreeClientHbBatchRsp Unexecuted instantiation: builtins.c:tFreeClientHbBatchRsp Unexecuted instantiation: builtinsimpl.c:tFreeClientHbBatchRsp Unexecuted instantiation: spillDistinctSet.c:tFreeClientHbBatchRsp Unexecuted instantiation: thistogram.c:tFreeClientHbBatchRsp Unexecuted instantiation: tpercentile.c:tFreeClientHbBatchRsp Unexecuted instantiation: tavgfunction.c:tFreeClientHbBatchRsp Unexecuted instantiation: tminmax.c:tFreeClientHbBatchRsp Unexecuted instantiation: tminmaxavx.c:tFreeClientHbBatchRsp Unexecuted instantiation: filter.c:tFreeClientHbBatchRsp Unexecuted instantiation: scalar.c:tFreeClientHbBatchRsp Unexecuted instantiation: sclfunc.c:tFreeClientHbBatchRsp Unexecuted instantiation: sclvector.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesCloneFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesCodeFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesEqualFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesMatchFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesMsgFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesToSQLFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesTraverseFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: nodesUtilFuncs.c:tFreeClientHbBatchRsp Unexecuted instantiation: extTypeMap.c:tFreeClientHbBatchRsp Unexecuted instantiation: queryUtil.c:tFreeClientHbBatchRsp Unexecuted instantiation: querymsg.c:tFreeClientHbBatchRsp Unexecuted instantiation: trans.c:tFreeClientHbBatchRsp Unexecuted instantiation: transCli.c:tFreeClientHbBatchRsp Unexecuted instantiation: transComm.c:tFreeClientHbBatchRsp Unexecuted instantiation: transSasl.c:tFreeClientHbBatchRsp Unexecuted instantiation: transSvr.c:tFreeClientHbBatchRsp Unexecuted instantiation: transTLS.c:tFreeClientHbBatchRsp Unexecuted instantiation: thttp.c:tFreeClientHbBatchRsp Unexecuted instantiation: geomFunc.c:tFreeClientHbBatchRsp Unexecuted instantiation: tconfig.c:tFreeClientHbBatchRsp Unexecuted instantiation: tdigest.c:tFreeClientHbBatchRsp Unexecuted instantiation: tlog.c:tFreeClientHbBatchRsp Unexecuted instantiation: tmempool.c:tFreeClientHbBatchRsp Unexecuted instantiation: tpagedbuf.c:tFreeClientHbBatchRsp Unexecuted instantiation: mpDirect.c:tFreeClientHbBatchRsp Unexecuted instantiation: extCapability.c:tFreeClientHbBatchRsp Unexecuted instantiation: systable.c:tFreeClientHbBatchRsp Unexecuted instantiation: tanalytics.c:tFreeClientHbBatchRsp Unexecuted instantiation: tdatablock.c:tFreeClientHbBatchRsp Unexecuted instantiation: tdataformat.c:tFreeClientHbBatchRsp Unexecuted instantiation: tglobal.c:tFreeClientHbBatchRsp Unexecuted instantiation: tmisce.c:tFreeClientHbBatchRsp Unexecuted instantiation: tname.c:tFreeClientHbBatchRsp Unexecuted instantiation: tpriv.c:tFreeClientHbBatchRsp Unexecuted instantiation: ttime.c:tFreeClientHbBatchRsp Unexecuted instantiation: tvariant.c:tFreeClientHbBatchRsp Unexecuted instantiation: streamMsg.c:tFreeClientHbBatchRsp Unexecuted instantiation: streamWindowPlan.c:tFreeClientHbBatchRsp Unexecuted instantiation: tmsg.c:tFreeClientHbBatchRsp Unexecuted instantiation: xnode.c:tFreeClientHbBatchRsp Unexecuted instantiation: tencrypt.c:tFreeClientHbBatchRsp Unexecuted instantiation: streamJson.c:tFreeClientHbBatchRsp Unexecuted instantiation: crypt.c:tFreeClientHbBatchRsp |
6748 | | |
6749 | | int32_t tSerializeSClientHbBatchRsp(void* buf, int32_t bufLen, const SClientHbBatchRsp* pBatchRsp); |
6750 | | int32_t tDeserializeSClientHbBatchRsp(void* buf, int32_t bufLen, SClientHbBatchRsp* pBatchRsp); |
6751 | | void tFreeSClientHbBatchRsp(SClientHbBatchRsp* pBatchRsp); |
6752 | | |
6753 | 0 | static FORCE_INLINE int32_t tEncodeSKv(SEncoder* pEncoder, const SKv* pKv) { |
6754 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, pKv->key)); |
6755 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, pKv->valueLen)); |
6756 | 0 | TAOS_CHECK_RETURN(tEncodeBinary(pEncoder, (uint8_t*)pKv->value, pKv->valueLen)); |
6757 | 0 | return 0; |
6758 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSKv Unexecuted instantiation: parser.c:tEncodeSKv Unexecuted instantiation: parTranslater.c:tEncodeSKv Unexecuted instantiation: parUtil.c:tEncodeSKv Unexecuted instantiation: parAstParser.c:tEncodeSKv Unexecuted instantiation: parAuthenticator.c:tEncodeSKv Unexecuted instantiation: parCalcConst.c:tEncodeSKv Unexecuted instantiation: parInsertSql.c:tEncodeSKv Unexecuted instantiation: parInsertUtil.c:tEncodeSKv Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSKv Unexecuted instantiation: parAstCreater.c:tEncodeSKv Unexecuted instantiation: parInsertSml.c:tEncodeSKv Unexecuted instantiation: planner.c:tEncodeSKv Unexecuted instantiation: planLogicCreater.c:tEncodeSKv Unexecuted instantiation: planOptimizer.c:tEncodeSKv Unexecuted instantiation: planPhysiCreater.c:tEncodeSKv Unexecuted instantiation: planScaleOut.c:tEncodeSKv Unexecuted instantiation: planSpliter.c:tEncodeSKv Unexecuted instantiation: planUtil.c:tEncodeSKv Unexecuted instantiation: planValidator.c:tEncodeSKv Unexecuted instantiation: catalog.c:tEncodeSKv Unexecuted instantiation: ctgAsync.c:tEncodeSKv Unexecuted instantiation: ctgCache.c:tEncodeSKv Unexecuted instantiation: ctgDbg.c:tEncodeSKv Unexecuted instantiation: ctgRemote.c:tEncodeSKv Unexecuted instantiation: ctgRent.c:tEncodeSKv Unexecuted instantiation: ctgUtil.c:tEncodeSKv Unexecuted instantiation: extConnector.c:tEncodeSKv Unexecuted instantiation: extDialect.c:tEncodeSKv Unexecuted instantiation: extDialectDefaults.c:tEncodeSKv Unexecuted instantiation: functionMgt.c:tEncodeSKv Unexecuted instantiation: tudf.c:tEncodeSKv Unexecuted instantiation: builtins.c:tEncodeSKv Unexecuted instantiation: builtinsimpl.c:tEncodeSKv Unexecuted instantiation: spillDistinctSet.c:tEncodeSKv Unexecuted instantiation: thistogram.c:tEncodeSKv Unexecuted instantiation: tpercentile.c:tEncodeSKv Unexecuted instantiation: tavgfunction.c:tEncodeSKv Unexecuted instantiation: tminmax.c:tEncodeSKv Unexecuted instantiation: tminmaxavx.c:tEncodeSKv Unexecuted instantiation: filter.c:tEncodeSKv Unexecuted instantiation: scalar.c:tEncodeSKv Unexecuted instantiation: sclfunc.c:tEncodeSKv Unexecuted instantiation: sclvector.c:tEncodeSKv Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSKv Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSKv Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSKv Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSKv Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSKv Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSKv Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSKv Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSKv Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSKv Unexecuted instantiation: extTypeMap.c:tEncodeSKv Unexecuted instantiation: queryUtil.c:tEncodeSKv Unexecuted instantiation: querymsg.c:tEncodeSKv Unexecuted instantiation: trans.c:tEncodeSKv Unexecuted instantiation: transCli.c:tEncodeSKv Unexecuted instantiation: transComm.c:tEncodeSKv Unexecuted instantiation: transSasl.c:tEncodeSKv Unexecuted instantiation: transSvr.c:tEncodeSKv Unexecuted instantiation: transTLS.c:tEncodeSKv Unexecuted instantiation: thttp.c:tEncodeSKv Unexecuted instantiation: geomFunc.c:tEncodeSKv Unexecuted instantiation: tconfig.c:tEncodeSKv Unexecuted instantiation: tdigest.c:tEncodeSKv Unexecuted instantiation: tlog.c:tEncodeSKv Unexecuted instantiation: tmempool.c:tEncodeSKv Unexecuted instantiation: tpagedbuf.c:tEncodeSKv Unexecuted instantiation: mpDirect.c:tEncodeSKv Unexecuted instantiation: extCapability.c:tEncodeSKv Unexecuted instantiation: systable.c:tEncodeSKv Unexecuted instantiation: tanalytics.c:tEncodeSKv Unexecuted instantiation: tdatablock.c:tEncodeSKv Unexecuted instantiation: tdataformat.c:tEncodeSKv Unexecuted instantiation: tglobal.c:tEncodeSKv Unexecuted instantiation: tmisce.c:tEncodeSKv Unexecuted instantiation: tname.c:tEncodeSKv Unexecuted instantiation: tpriv.c:tEncodeSKv Unexecuted instantiation: ttime.c:tEncodeSKv Unexecuted instantiation: tvariant.c:tEncodeSKv Unexecuted instantiation: streamMsg.c:tEncodeSKv Unexecuted instantiation: streamWindowPlan.c:tEncodeSKv Unexecuted instantiation: tmsg.c:tEncodeSKv Unexecuted instantiation: xnode.c:tEncodeSKv Unexecuted instantiation: tencrypt.c:tEncodeSKv Unexecuted instantiation: streamJson.c:tEncodeSKv Unexecuted instantiation: crypt.c:tEncodeSKv |
6759 | | |
6760 | 0 | static FORCE_INLINE int32_t tDecodeSKv(SDecoder* pDecoder, SKv* pKv) { |
6761 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pKv->key)); |
6762 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pKv->valueLen)); |
6763 | | |
6764 | 0 | if (pKv->valueLen < 0) { |
6765 | 0 | return TSDB_CODE_INVALID_MSG; |
6766 | 0 | } |
6767 | | |
6768 | 0 | pKv->value = taosMemoryMalloc(pKv->valueLen + 1); |
6769 | 0 | if (pKv->value == NULL) { |
6770 | 0 | return TSDB_CODE_OUT_OF_MEMORY; |
6771 | 0 | } |
6772 | 0 | int32_t code = tDecodeCStrToN(pDecoder, (char*)pKv->value, pKv->valueLen + 1); |
6773 | 0 | if (code != 0) { |
6774 | 0 | taosMemoryFreeClear(pKv->value); |
6775 | 0 | return code; |
6776 | 0 | } |
6777 | 0 | return 0; |
6778 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSKv Unexecuted instantiation: parser.c:tDecodeSKv Unexecuted instantiation: parTranslater.c:tDecodeSKv Unexecuted instantiation: parUtil.c:tDecodeSKv Unexecuted instantiation: parAstParser.c:tDecodeSKv Unexecuted instantiation: parAuthenticator.c:tDecodeSKv Unexecuted instantiation: parCalcConst.c:tDecodeSKv Unexecuted instantiation: parInsertSql.c:tDecodeSKv Unexecuted instantiation: parInsertUtil.c:tDecodeSKv Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSKv Unexecuted instantiation: parAstCreater.c:tDecodeSKv Unexecuted instantiation: parInsertSml.c:tDecodeSKv Unexecuted instantiation: planner.c:tDecodeSKv Unexecuted instantiation: planLogicCreater.c:tDecodeSKv Unexecuted instantiation: planOptimizer.c:tDecodeSKv Unexecuted instantiation: planPhysiCreater.c:tDecodeSKv Unexecuted instantiation: planScaleOut.c:tDecodeSKv Unexecuted instantiation: planSpliter.c:tDecodeSKv Unexecuted instantiation: planUtil.c:tDecodeSKv Unexecuted instantiation: planValidator.c:tDecodeSKv Unexecuted instantiation: catalog.c:tDecodeSKv Unexecuted instantiation: ctgAsync.c:tDecodeSKv Unexecuted instantiation: ctgCache.c:tDecodeSKv Unexecuted instantiation: ctgDbg.c:tDecodeSKv Unexecuted instantiation: ctgRemote.c:tDecodeSKv Unexecuted instantiation: ctgRent.c:tDecodeSKv Unexecuted instantiation: ctgUtil.c:tDecodeSKv Unexecuted instantiation: extConnector.c:tDecodeSKv Unexecuted instantiation: extDialect.c:tDecodeSKv Unexecuted instantiation: extDialectDefaults.c:tDecodeSKv Unexecuted instantiation: functionMgt.c:tDecodeSKv Unexecuted instantiation: tudf.c:tDecodeSKv Unexecuted instantiation: builtins.c:tDecodeSKv Unexecuted instantiation: builtinsimpl.c:tDecodeSKv Unexecuted instantiation: spillDistinctSet.c:tDecodeSKv Unexecuted instantiation: thistogram.c:tDecodeSKv Unexecuted instantiation: tpercentile.c:tDecodeSKv Unexecuted instantiation: tavgfunction.c:tDecodeSKv Unexecuted instantiation: tminmax.c:tDecodeSKv Unexecuted instantiation: tminmaxavx.c:tDecodeSKv Unexecuted instantiation: filter.c:tDecodeSKv Unexecuted instantiation: scalar.c:tDecodeSKv Unexecuted instantiation: sclfunc.c:tDecodeSKv Unexecuted instantiation: sclvector.c:tDecodeSKv Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSKv Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSKv Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSKv Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSKv Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSKv Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSKv Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSKv Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSKv Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSKv Unexecuted instantiation: extTypeMap.c:tDecodeSKv Unexecuted instantiation: queryUtil.c:tDecodeSKv Unexecuted instantiation: querymsg.c:tDecodeSKv Unexecuted instantiation: trans.c:tDecodeSKv Unexecuted instantiation: transCli.c:tDecodeSKv Unexecuted instantiation: transComm.c:tDecodeSKv Unexecuted instantiation: transSasl.c:tDecodeSKv Unexecuted instantiation: transSvr.c:tDecodeSKv Unexecuted instantiation: transTLS.c:tDecodeSKv Unexecuted instantiation: thttp.c:tDecodeSKv Unexecuted instantiation: geomFunc.c:tDecodeSKv Unexecuted instantiation: tconfig.c:tDecodeSKv Unexecuted instantiation: tdigest.c:tDecodeSKv Unexecuted instantiation: tlog.c:tDecodeSKv Unexecuted instantiation: tmempool.c:tDecodeSKv Unexecuted instantiation: tpagedbuf.c:tDecodeSKv Unexecuted instantiation: mpDirect.c:tDecodeSKv Unexecuted instantiation: extCapability.c:tDecodeSKv Unexecuted instantiation: systable.c:tDecodeSKv Unexecuted instantiation: tanalytics.c:tDecodeSKv Unexecuted instantiation: tdatablock.c:tDecodeSKv Unexecuted instantiation: tdataformat.c:tDecodeSKv Unexecuted instantiation: tglobal.c:tDecodeSKv Unexecuted instantiation: tmisce.c:tDecodeSKv Unexecuted instantiation: tname.c:tDecodeSKv Unexecuted instantiation: tpriv.c:tDecodeSKv Unexecuted instantiation: ttime.c:tDecodeSKv Unexecuted instantiation: tvariant.c:tDecodeSKv Unexecuted instantiation: streamMsg.c:tDecodeSKv Unexecuted instantiation: streamWindowPlan.c:tDecodeSKv Unexecuted instantiation: tmsg.c:tDecodeSKv Unexecuted instantiation: xnode.c:tDecodeSKv Unexecuted instantiation: tencrypt.c:tDecodeSKv Unexecuted instantiation: streamJson.c:tDecodeSKv Unexecuted instantiation: crypt.c:tDecodeSKv |
6779 | | |
6780 | 0 | static FORCE_INLINE int32_t tEncodeSClientHbKey(SEncoder* pEncoder, const SClientHbKey* pKey) { |
6781 | 0 | TAOS_CHECK_RETURN(tEncodeI64(pEncoder, pKey->tscRid)); |
6782 | 0 | TAOS_CHECK_RETURN(tEncodeI8(pEncoder, pKey->connType)); |
6783 | 0 | return 0; |
6784 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSClientHbKey Unexecuted instantiation: parser.c:tEncodeSClientHbKey Unexecuted instantiation: parTranslater.c:tEncodeSClientHbKey Unexecuted instantiation: parUtil.c:tEncodeSClientHbKey Unexecuted instantiation: parAstParser.c:tEncodeSClientHbKey Unexecuted instantiation: parAuthenticator.c:tEncodeSClientHbKey Unexecuted instantiation: parCalcConst.c:tEncodeSClientHbKey Unexecuted instantiation: parInsertSql.c:tEncodeSClientHbKey Unexecuted instantiation: parInsertUtil.c:tEncodeSClientHbKey Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSClientHbKey Unexecuted instantiation: parAstCreater.c:tEncodeSClientHbKey Unexecuted instantiation: parInsertSml.c:tEncodeSClientHbKey Unexecuted instantiation: planner.c:tEncodeSClientHbKey Unexecuted instantiation: planLogicCreater.c:tEncodeSClientHbKey Unexecuted instantiation: planOptimizer.c:tEncodeSClientHbKey Unexecuted instantiation: planPhysiCreater.c:tEncodeSClientHbKey Unexecuted instantiation: planScaleOut.c:tEncodeSClientHbKey Unexecuted instantiation: planSpliter.c:tEncodeSClientHbKey Unexecuted instantiation: planUtil.c:tEncodeSClientHbKey Unexecuted instantiation: planValidator.c:tEncodeSClientHbKey Unexecuted instantiation: catalog.c:tEncodeSClientHbKey Unexecuted instantiation: ctgAsync.c:tEncodeSClientHbKey Unexecuted instantiation: ctgCache.c:tEncodeSClientHbKey Unexecuted instantiation: ctgDbg.c:tEncodeSClientHbKey Unexecuted instantiation: ctgRemote.c:tEncodeSClientHbKey Unexecuted instantiation: ctgRent.c:tEncodeSClientHbKey Unexecuted instantiation: ctgUtil.c:tEncodeSClientHbKey Unexecuted instantiation: extConnector.c:tEncodeSClientHbKey Unexecuted instantiation: extDialect.c:tEncodeSClientHbKey Unexecuted instantiation: extDialectDefaults.c:tEncodeSClientHbKey Unexecuted instantiation: functionMgt.c:tEncodeSClientHbKey Unexecuted instantiation: tudf.c:tEncodeSClientHbKey Unexecuted instantiation: builtins.c:tEncodeSClientHbKey Unexecuted instantiation: builtinsimpl.c:tEncodeSClientHbKey Unexecuted instantiation: spillDistinctSet.c:tEncodeSClientHbKey Unexecuted instantiation: thistogram.c:tEncodeSClientHbKey Unexecuted instantiation: tpercentile.c:tEncodeSClientHbKey Unexecuted instantiation: tavgfunction.c:tEncodeSClientHbKey Unexecuted instantiation: tminmax.c:tEncodeSClientHbKey Unexecuted instantiation: tminmaxavx.c:tEncodeSClientHbKey Unexecuted instantiation: filter.c:tEncodeSClientHbKey Unexecuted instantiation: scalar.c:tEncodeSClientHbKey Unexecuted instantiation: sclfunc.c:tEncodeSClientHbKey Unexecuted instantiation: sclvector.c:tEncodeSClientHbKey Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSClientHbKey Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSClientHbKey Unexecuted instantiation: extTypeMap.c:tEncodeSClientHbKey Unexecuted instantiation: queryUtil.c:tEncodeSClientHbKey Unexecuted instantiation: querymsg.c:tEncodeSClientHbKey Unexecuted instantiation: trans.c:tEncodeSClientHbKey Unexecuted instantiation: transCli.c:tEncodeSClientHbKey Unexecuted instantiation: transComm.c:tEncodeSClientHbKey Unexecuted instantiation: transSasl.c:tEncodeSClientHbKey Unexecuted instantiation: transSvr.c:tEncodeSClientHbKey Unexecuted instantiation: transTLS.c:tEncodeSClientHbKey Unexecuted instantiation: thttp.c:tEncodeSClientHbKey Unexecuted instantiation: geomFunc.c:tEncodeSClientHbKey Unexecuted instantiation: tconfig.c:tEncodeSClientHbKey Unexecuted instantiation: tdigest.c:tEncodeSClientHbKey Unexecuted instantiation: tlog.c:tEncodeSClientHbKey Unexecuted instantiation: tmempool.c:tEncodeSClientHbKey Unexecuted instantiation: tpagedbuf.c:tEncodeSClientHbKey Unexecuted instantiation: mpDirect.c:tEncodeSClientHbKey Unexecuted instantiation: extCapability.c:tEncodeSClientHbKey Unexecuted instantiation: systable.c:tEncodeSClientHbKey Unexecuted instantiation: tanalytics.c:tEncodeSClientHbKey Unexecuted instantiation: tdatablock.c:tEncodeSClientHbKey Unexecuted instantiation: tdataformat.c:tEncodeSClientHbKey Unexecuted instantiation: tglobal.c:tEncodeSClientHbKey Unexecuted instantiation: tmisce.c:tEncodeSClientHbKey Unexecuted instantiation: tname.c:tEncodeSClientHbKey Unexecuted instantiation: tpriv.c:tEncodeSClientHbKey Unexecuted instantiation: ttime.c:tEncodeSClientHbKey Unexecuted instantiation: tvariant.c:tEncodeSClientHbKey Unexecuted instantiation: streamMsg.c:tEncodeSClientHbKey Unexecuted instantiation: streamWindowPlan.c:tEncodeSClientHbKey Unexecuted instantiation: tmsg.c:tEncodeSClientHbKey Unexecuted instantiation: xnode.c:tEncodeSClientHbKey Unexecuted instantiation: tencrypt.c:tEncodeSClientHbKey Unexecuted instantiation: streamJson.c:tEncodeSClientHbKey Unexecuted instantiation: crypt.c:tEncodeSClientHbKey |
6785 | | |
6786 | 0 | static FORCE_INLINE int32_t tDecodeSClientHbKey(SDecoder* pDecoder, SClientHbKey* pKey) { |
6787 | 0 | TAOS_CHECK_RETURN(tDecodeI64(pDecoder, &pKey->tscRid)); |
6788 | 0 | TAOS_CHECK_RETURN(tDecodeI8(pDecoder, &pKey->connType)); |
6789 | 0 | return 0; |
6790 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSClientHbKey Unexecuted instantiation: parser.c:tDecodeSClientHbKey Unexecuted instantiation: parTranslater.c:tDecodeSClientHbKey Unexecuted instantiation: parUtil.c:tDecodeSClientHbKey Unexecuted instantiation: parAstParser.c:tDecodeSClientHbKey Unexecuted instantiation: parAuthenticator.c:tDecodeSClientHbKey Unexecuted instantiation: parCalcConst.c:tDecodeSClientHbKey Unexecuted instantiation: parInsertSql.c:tDecodeSClientHbKey Unexecuted instantiation: parInsertUtil.c:tDecodeSClientHbKey Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSClientHbKey Unexecuted instantiation: parAstCreater.c:tDecodeSClientHbKey Unexecuted instantiation: parInsertSml.c:tDecodeSClientHbKey Unexecuted instantiation: planner.c:tDecodeSClientHbKey Unexecuted instantiation: planLogicCreater.c:tDecodeSClientHbKey Unexecuted instantiation: planOptimizer.c:tDecodeSClientHbKey Unexecuted instantiation: planPhysiCreater.c:tDecodeSClientHbKey Unexecuted instantiation: planScaleOut.c:tDecodeSClientHbKey Unexecuted instantiation: planSpliter.c:tDecodeSClientHbKey Unexecuted instantiation: planUtil.c:tDecodeSClientHbKey Unexecuted instantiation: planValidator.c:tDecodeSClientHbKey Unexecuted instantiation: catalog.c:tDecodeSClientHbKey Unexecuted instantiation: ctgAsync.c:tDecodeSClientHbKey Unexecuted instantiation: ctgCache.c:tDecodeSClientHbKey Unexecuted instantiation: ctgDbg.c:tDecodeSClientHbKey Unexecuted instantiation: ctgRemote.c:tDecodeSClientHbKey Unexecuted instantiation: ctgRent.c:tDecodeSClientHbKey Unexecuted instantiation: ctgUtil.c:tDecodeSClientHbKey Unexecuted instantiation: extConnector.c:tDecodeSClientHbKey Unexecuted instantiation: extDialect.c:tDecodeSClientHbKey Unexecuted instantiation: extDialectDefaults.c:tDecodeSClientHbKey Unexecuted instantiation: functionMgt.c:tDecodeSClientHbKey Unexecuted instantiation: tudf.c:tDecodeSClientHbKey Unexecuted instantiation: builtins.c:tDecodeSClientHbKey Unexecuted instantiation: builtinsimpl.c:tDecodeSClientHbKey Unexecuted instantiation: spillDistinctSet.c:tDecodeSClientHbKey Unexecuted instantiation: thistogram.c:tDecodeSClientHbKey Unexecuted instantiation: tpercentile.c:tDecodeSClientHbKey Unexecuted instantiation: tavgfunction.c:tDecodeSClientHbKey Unexecuted instantiation: tminmax.c:tDecodeSClientHbKey Unexecuted instantiation: tminmaxavx.c:tDecodeSClientHbKey Unexecuted instantiation: filter.c:tDecodeSClientHbKey Unexecuted instantiation: scalar.c:tDecodeSClientHbKey Unexecuted instantiation: sclfunc.c:tDecodeSClientHbKey Unexecuted instantiation: sclvector.c:tDecodeSClientHbKey Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSClientHbKey Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSClientHbKey Unexecuted instantiation: extTypeMap.c:tDecodeSClientHbKey Unexecuted instantiation: queryUtil.c:tDecodeSClientHbKey Unexecuted instantiation: querymsg.c:tDecodeSClientHbKey Unexecuted instantiation: trans.c:tDecodeSClientHbKey Unexecuted instantiation: transCli.c:tDecodeSClientHbKey Unexecuted instantiation: transComm.c:tDecodeSClientHbKey Unexecuted instantiation: transSasl.c:tDecodeSClientHbKey Unexecuted instantiation: transSvr.c:tDecodeSClientHbKey Unexecuted instantiation: transTLS.c:tDecodeSClientHbKey Unexecuted instantiation: thttp.c:tDecodeSClientHbKey Unexecuted instantiation: geomFunc.c:tDecodeSClientHbKey Unexecuted instantiation: tconfig.c:tDecodeSClientHbKey Unexecuted instantiation: tdigest.c:tDecodeSClientHbKey Unexecuted instantiation: tlog.c:tDecodeSClientHbKey Unexecuted instantiation: tmempool.c:tDecodeSClientHbKey Unexecuted instantiation: tpagedbuf.c:tDecodeSClientHbKey Unexecuted instantiation: mpDirect.c:tDecodeSClientHbKey Unexecuted instantiation: extCapability.c:tDecodeSClientHbKey Unexecuted instantiation: systable.c:tDecodeSClientHbKey Unexecuted instantiation: tanalytics.c:tDecodeSClientHbKey Unexecuted instantiation: tdatablock.c:tDecodeSClientHbKey Unexecuted instantiation: tdataformat.c:tDecodeSClientHbKey Unexecuted instantiation: tglobal.c:tDecodeSClientHbKey Unexecuted instantiation: tmisce.c:tDecodeSClientHbKey Unexecuted instantiation: tname.c:tDecodeSClientHbKey Unexecuted instantiation: tpriv.c:tDecodeSClientHbKey Unexecuted instantiation: ttime.c:tDecodeSClientHbKey Unexecuted instantiation: tvariant.c:tDecodeSClientHbKey Unexecuted instantiation: streamMsg.c:tDecodeSClientHbKey Unexecuted instantiation: streamWindowPlan.c:tDecodeSClientHbKey Unexecuted instantiation: tmsg.c:tDecodeSClientHbKey Unexecuted instantiation: xnode.c:tDecodeSClientHbKey Unexecuted instantiation: tencrypt.c:tDecodeSClientHbKey Unexecuted instantiation: streamJson.c:tDecodeSClientHbKey Unexecuted instantiation: crypt.c:tDecodeSClientHbKey |
6791 | | |
6792 | | typedef struct { |
6793 | | int32_t vgId; |
6794 | | // TODO stas |
6795 | | } SMqReportVgInfo; |
6796 | | |
6797 | 0 | static FORCE_INLINE int32_t taosEncodeSMqVgInfo(void** buf, const SMqReportVgInfo* pVgInfo) { |
6798 | 0 | int32_t tlen = 0; |
6799 | 0 | tlen += taosEncodeFixedI32(buf, pVgInfo->vgId); |
6800 | 0 | return tlen; |
6801 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosEncodeSMqVgInfo Unexecuted instantiation: parser.c:taosEncodeSMqVgInfo Unexecuted instantiation: parTranslater.c:taosEncodeSMqVgInfo Unexecuted instantiation: parUtil.c:taosEncodeSMqVgInfo Unexecuted instantiation: parAstParser.c:taosEncodeSMqVgInfo Unexecuted instantiation: parAuthenticator.c:taosEncodeSMqVgInfo Unexecuted instantiation: parCalcConst.c:taosEncodeSMqVgInfo Unexecuted instantiation: parInsertSql.c:taosEncodeSMqVgInfo Unexecuted instantiation: parInsertUtil.c:taosEncodeSMqVgInfo Unexecuted instantiation: taos_lemon_sql.tab.c:taosEncodeSMqVgInfo Unexecuted instantiation: parAstCreater.c:taosEncodeSMqVgInfo Unexecuted instantiation: parInsertSml.c:taosEncodeSMqVgInfo Unexecuted instantiation: planner.c:taosEncodeSMqVgInfo Unexecuted instantiation: planLogicCreater.c:taosEncodeSMqVgInfo Unexecuted instantiation: planOptimizer.c:taosEncodeSMqVgInfo Unexecuted instantiation: planPhysiCreater.c:taosEncodeSMqVgInfo Unexecuted instantiation: planScaleOut.c:taosEncodeSMqVgInfo Unexecuted instantiation: planSpliter.c:taosEncodeSMqVgInfo Unexecuted instantiation: planUtil.c:taosEncodeSMqVgInfo Unexecuted instantiation: planValidator.c:taosEncodeSMqVgInfo Unexecuted instantiation: catalog.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgAsync.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgCache.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgDbg.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgRemote.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgRent.c:taosEncodeSMqVgInfo Unexecuted instantiation: ctgUtil.c:taosEncodeSMqVgInfo Unexecuted instantiation: extConnector.c:taosEncodeSMqVgInfo Unexecuted instantiation: extDialect.c:taosEncodeSMqVgInfo Unexecuted instantiation: extDialectDefaults.c:taosEncodeSMqVgInfo Unexecuted instantiation: functionMgt.c:taosEncodeSMqVgInfo Unexecuted instantiation: tudf.c:taosEncodeSMqVgInfo Unexecuted instantiation: builtins.c:taosEncodeSMqVgInfo Unexecuted instantiation: builtinsimpl.c:taosEncodeSMqVgInfo Unexecuted instantiation: spillDistinctSet.c:taosEncodeSMqVgInfo Unexecuted instantiation: thistogram.c:taosEncodeSMqVgInfo Unexecuted instantiation: tpercentile.c:taosEncodeSMqVgInfo Unexecuted instantiation: tavgfunction.c:taosEncodeSMqVgInfo Unexecuted instantiation: tminmax.c:taosEncodeSMqVgInfo Unexecuted instantiation: tminmaxavx.c:taosEncodeSMqVgInfo Unexecuted instantiation: filter.c:taosEncodeSMqVgInfo Unexecuted instantiation: scalar.c:taosEncodeSMqVgInfo Unexecuted instantiation: sclfunc.c:taosEncodeSMqVgInfo Unexecuted instantiation: sclvector.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesCloneFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesCodeFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesEqualFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesMatchFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesMsgFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesRemotePlanToSQL.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesToSQLFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesTraverseFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: nodesUtilFuncs.c:taosEncodeSMqVgInfo Unexecuted instantiation: extTypeMap.c:taosEncodeSMqVgInfo Unexecuted instantiation: queryUtil.c:taosEncodeSMqVgInfo Unexecuted instantiation: querymsg.c:taosEncodeSMqVgInfo Unexecuted instantiation: trans.c:taosEncodeSMqVgInfo Unexecuted instantiation: transCli.c:taosEncodeSMqVgInfo Unexecuted instantiation: transComm.c:taosEncodeSMqVgInfo Unexecuted instantiation: transSasl.c:taosEncodeSMqVgInfo Unexecuted instantiation: transSvr.c:taosEncodeSMqVgInfo Unexecuted instantiation: transTLS.c:taosEncodeSMqVgInfo Unexecuted instantiation: thttp.c:taosEncodeSMqVgInfo Unexecuted instantiation: geomFunc.c:taosEncodeSMqVgInfo Unexecuted instantiation: tconfig.c:taosEncodeSMqVgInfo Unexecuted instantiation: tdigest.c:taosEncodeSMqVgInfo Unexecuted instantiation: tlog.c:taosEncodeSMqVgInfo Unexecuted instantiation: tmempool.c:taosEncodeSMqVgInfo Unexecuted instantiation: tpagedbuf.c:taosEncodeSMqVgInfo Unexecuted instantiation: mpDirect.c:taosEncodeSMqVgInfo Unexecuted instantiation: extCapability.c:taosEncodeSMqVgInfo Unexecuted instantiation: systable.c:taosEncodeSMqVgInfo Unexecuted instantiation: tanalytics.c:taosEncodeSMqVgInfo Unexecuted instantiation: tdatablock.c:taosEncodeSMqVgInfo Unexecuted instantiation: tdataformat.c:taosEncodeSMqVgInfo Unexecuted instantiation: tglobal.c:taosEncodeSMqVgInfo Unexecuted instantiation: tmisce.c:taosEncodeSMqVgInfo Unexecuted instantiation: tname.c:taosEncodeSMqVgInfo Unexecuted instantiation: tpriv.c:taosEncodeSMqVgInfo Unexecuted instantiation: ttime.c:taosEncodeSMqVgInfo Unexecuted instantiation: tvariant.c:taosEncodeSMqVgInfo Unexecuted instantiation: streamMsg.c:taosEncodeSMqVgInfo Unexecuted instantiation: streamWindowPlan.c:taosEncodeSMqVgInfo Unexecuted instantiation: tmsg.c:taosEncodeSMqVgInfo Unexecuted instantiation: xnode.c:taosEncodeSMqVgInfo Unexecuted instantiation: tencrypt.c:taosEncodeSMqVgInfo Unexecuted instantiation: streamJson.c:taosEncodeSMqVgInfo Unexecuted instantiation: crypt.c:taosEncodeSMqVgInfo |
6802 | | |
6803 | 0 | static FORCE_INLINE void* taosDecodeSMqVgInfo(void* buf, SMqReportVgInfo* pVgInfo) { |
6804 | 0 | buf = taosDecodeFixedI32(buf, &pVgInfo->vgId); |
6805 | 0 | return buf; |
6806 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosDecodeSMqVgInfo Unexecuted instantiation: parser.c:taosDecodeSMqVgInfo Unexecuted instantiation: parTranslater.c:taosDecodeSMqVgInfo Unexecuted instantiation: parUtil.c:taosDecodeSMqVgInfo Unexecuted instantiation: parAstParser.c:taosDecodeSMqVgInfo Unexecuted instantiation: parAuthenticator.c:taosDecodeSMqVgInfo Unexecuted instantiation: parCalcConst.c:taosDecodeSMqVgInfo Unexecuted instantiation: parInsertSql.c:taosDecodeSMqVgInfo Unexecuted instantiation: parInsertUtil.c:taosDecodeSMqVgInfo Unexecuted instantiation: taos_lemon_sql.tab.c:taosDecodeSMqVgInfo Unexecuted instantiation: parAstCreater.c:taosDecodeSMqVgInfo Unexecuted instantiation: parInsertSml.c:taosDecodeSMqVgInfo Unexecuted instantiation: planner.c:taosDecodeSMqVgInfo Unexecuted instantiation: planLogicCreater.c:taosDecodeSMqVgInfo Unexecuted instantiation: planOptimizer.c:taosDecodeSMqVgInfo Unexecuted instantiation: planPhysiCreater.c:taosDecodeSMqVgInfo Unexecuted instantiation: planScaleOut.c:taosDecodeSMqVgInfo Unexecuted instantiation: planSpliter.c:taosDecodeSMqVgInfo Unexecuted instantiation: planUtil.c:taosDecodeSMqVgInfo Unexecuted instantiation: planValidator.c:taosDecodeSMqVgInfo Unexecuted instantiation: catalog.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgAsync.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgCache.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgDbg.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgRemote.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgRent.c:taosDecodeSMqVgInfo Unexecuted instantiation: ctgUtil.c:taosDecodeSMqVgInfo Unexecuted instantiation: extConnector.c:taosDecodeSMqVgInfo Unexecuted instantiation: extDialect.c:taosDecodeSMqVgInfo Unexecuted instantiation: extDialectDefaults.c:taosDecodeSMqVgInfo Unexecuted instantiation: functionMgt.c:taosDecodeSMqVgInfo Unexecuted instantiation: tudf.c:taosDecodeSMqVgInfo Unexecuted instantiation: builtins.c:taosDecodeSMqVgInfo Unexecuted instantiation: builtinsimpl.c:taosDecodeSMqVgInfo Unexecuted instantiation: spillDistinctSet.c:taosDecodeSMqVgInfo Unexecuted instantiation: thistogram.c:taosDecodeSMqVgInfo Unexecuted instantiation: tpercentile.c:taosDecodeSMqVgInfo Unexecuted instantiation: tavgfunction.c:taosDecodeSMqVgInfo Unexecuted instantiation: tminmax.c:taosDecodeSMqVgInfo Unexecuted instantiation: tminmaxavx.c:taosDecodeSMqVgInfo Unexecuted instantiation: filter.c:taosDecodeSMqVgInfo Unexecuted instantiation: scalar.c:taosDecodeSMqVgInfo Unexecuted instantiation: sclfunc.c:taosDecodeSMqVgInfo Unexecuted instantiation: sclvector.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesCloneFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesCodeFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesEqualFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesMatchFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesMsgFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesRemotePlanToSQL.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesToSQLFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesTraverseFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: nodesUtilFuncs.c:taosDecodeSMqVgInfo Unexecuted instantiation: extTypeMap.c:taosDecodeSMqVgInfo Unexecuted instantiation: queryUtil.c:taosDecodeSMqVgInfo Unexecuted instantiation: querymsg.c:taosDecodeSMqVgInfo Unexecuted instantiation: trans.c:taosDecodeSMqVgInfo Unexecuted instantiation: transCli.c:taosDecodeSMqVgInfo Unexecuted instantiation: transComm.c:taosDecodeSMqVgInfo Unexecuted instantiation: transSasl.c:taosDecodeSMqVgInfo Unexecuted instantiation: transSvr.c:taosDecodeSMqVgInfo Unexecuted instantiation: transTLS.c:taosDecodeSMqVgInfo Unexecuted instantiation: thttp.c:taosDecodeSMqVgInfo Unexecuted instantiation: geomFunc.c:taosDecodeSMqVgInfo Unexecuted instantiation: tconfig.c:taosDecodeSMqVgInfo Unexecuted instantiation: tdigest.c:taosDecodeSMqVgInfo Unexecuted instantiation: tlog.c:taosDecodeSMqVgInfo Unexecuted instantiation: tmempool.c:taosDecodeSMqVgInfo Unexecuted instantiation: tpagedbuf.c:taosDecodeSMqVgInfo Unexecuted instantiation: mpDirect.c:taosDecodeSMqVgInfo Unexecuted instantiation: extCapability.c:taosDecodeSMqVgInfo Unexecuted instantiation: systable.c:taosDecodeSMqVgInfo Unexecuted instantiation: tanalytics.c:taosDecodeSMqVgInfo Unexecuted instantiation: tdatablock.c:taosDecodeSMqVgInfo Unexecuted instantiation: tdataformat.c:taosDecodeSMqVgInfo Unexecuted instantiation: tglobal.c:taosDecodeSMqVgInfo Unexecuted instantiation: tmisce.c:taosDecodeSMqVgInfo Unexecuted instantiation: tname.c:taosDecodeSMqVgInfo Unexecuted instantiation: tpriv.c:taosDecodeSMqVgInfo Unexecuted instantiation: ttime.c:taosDecodeSMqVgInfo Unexecuted instantiation: tvariant.c:taosDecodeSMqVgInfo Unexecuted instantiation: streamMsg.c:taosDecodeSMqVgInfo Unexecuted instantiation: streamWindowPlan.c:taosDecodeSMqVgInfo Unexecuted instantiation: tmsg.c:taosDecodeSMqVgInfo Unexecuted instantiation: xnode.c:taosDecodeSMqVgInfo Unexecuted instantiation: tencrypt.c:taosDecodeSMqVgInfo Unexecuted instantiation: streamJson.c:taosDecodeSMqVgInfo Unexecuted instantiation: crypt.c:taosDecodeSMqVgInfo |
6807 | | |
6808 | | typedef struct { |
6809 | | int32_t epoch; |
6810 | | int64_t topicUid; |
6811 | | char name[TSDB_TOPIC_FNAME_LEN]; |
6812 | | SArray* pVgInfo; // SArray<SMqHbVgInfo> |
6813 | | } SMqTopicInfo; |
6814 | | |
6815 | 0 | static FORCE_INLINE int32_t taosEncodeSMqTopicInfoMsg(void** buf, const SMqTopicInfo* pTopicInfo) { |
6816 | 0 | int32_t tlen = 0; |
6817 | 0 | tlen += taosEncodeFixedI32(buf, pTopicInfo->epoch); |
6818 | 0 | tlen += taosEncodeFixedI64(buf, pTopicInfo->topicUid); |
6819 | 0 | tlen += taosEncodeString(buf, pTopicInfo->name); |
6820 | 0 | int32_t sz = taosArrayGetSize(pTopicInfo->pVgInfo); |
6821 | 0 | tlen += taosEncodeFixedI32(buf, sz); |
6822 | 0 | for (int32_t i = 0; i < sz; i++) { |
6823 | 0 | SMqReportVgInfo* pVgInfo = (SMqReportVgInfo*)taosArrayGet(pTopicInfo->pVgInfo, i); |
6824 | 0 | tlen += taosEncodeSMqVgInfo(buf, pVgInfo); |
6825 | 0 | } |
6826 | 0 | return tlen; |
6827 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parser.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parTranslater.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parUtil.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parAstParser.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parAuthenticator.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parCalcConst.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parInsertSql.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parInsertUtil.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: taos_lemon_sql.tab.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parAstCreater.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: parInsertSml.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planner.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planLogicCreater.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planOptimizer.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planPhysiCreater.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planScaleOut.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planSpliter.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planUtil.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: planValidator.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: catalog.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgAsync.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgCache.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgDbg.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgRemote.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgRent.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ctgUtil.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: extConnector.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: extDialect.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: extDialectDefaults.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: functionMgt.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tudf.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: builtins.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: builtinsimpl.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: spillDistinctSet.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: thistogram.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tpercentile.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tavgfunction.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tminmax.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tminmaxavx.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: filter.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: scalar.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: sclfunc.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: sclvector.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesCloneFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesCodeFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesEqualFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesMatchFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesMsgFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesToSQLFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesTraverseFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: nodesUtilFuncs.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: extTypeMap.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: queryUtil.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: querymsg.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: trans.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: transCli.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: transComm.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: transSasl.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: transSvr.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: transTLS.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: thttp.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: geomFunc.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tconfig.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tdigest.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tlog.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tmempool.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tpagedbuf.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: mpDirect.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: extCapability.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: systable.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tanalytics.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tdatablock.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tdataformat.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tglobal.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tmisce.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tname.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tpriv.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: ttime.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tvariant.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: streamMsg.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: streamWindowPlan.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tmsg.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: xnode.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: tencrypt.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: streamJson.c:taosEncodeSMqTopicInfoMsg Unexecuted instantiation: crypt.c:taosEncodeSMqTopicInfoMsg |
6828 | | |
6829 | 0 | static FORCE_INLINE void* taosDecodeSMqTopicInfoMsg(void* buf, SMqTopicInfo* pTopicInfo) { |
6830 | 0 | buf = taosDecodeFixedI32(buf, &pTopicInfo->epoch); |
6831 | 0 | buf = taosDecodeFixedI64(buf, &pTopicInfo->topicUid); |
6832 | 0 | buf = taosDecodeStringTo(buf, pTopicInfo->name); |
6833 | 0 | int32_t sz; |
6834 | 0 | buf = taosDecodeFixedI32(buf, &sz); |
6835 | 0 | if ((pTopicInfo->pVgInfo = taosArrayInit(sz, sizeof(SMqReportVgInfo))) == NULL) { |
6836 | 0 | return NULL; |
6837 | 0 | } |
6838 | 0 | for (int32_t i = 0; i < sz; i++) { |
6839 | 0 | SMqReportVgInfo vgInfo; |
6840 | 0 | buf = taosDecodeSMqVgInfo(buf, &vgInfo); |
6841 | 0 | if (taosArrayPush(pTopicInfo->pVgInfo, &vgInfo) == NULL) { |
6842 | 0 | return NULL; |
6843 | 0 | } |
6844 | 0 | } |
6845 | 0 | return buf; |
6846 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parser.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parTranslater.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parUtil.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parAstParser.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parAuthenticator.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parCalcConst.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parInsertSql.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parInsertUtil.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: taos_lemon_sql.tab.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parAstCreater.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: parInsertSml.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planner.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planLogicCreater.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planOptimizer.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planPhysiCreater.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planScaleOut.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planSpliter.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planUtil.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: planValidator.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: catalog.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgAsync.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgCache.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgDbg.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgRemote.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgRent.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ctgUtil.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: extConnector.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: extDialect.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: extDialectDefaults.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: functionMgt.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tudf.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: builtins.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: builtinsimpl.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: spillDistinctSet.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: thistogram.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tpercentile.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tavgfunction.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tminmax.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tminmaxavx.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: filter.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: scalar.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: sclfunc.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: sclvector.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesCloneFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesCodeFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesEqualFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesMatchFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesMsgFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesToSQLFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesTraverseFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: nodesUtilFuncs.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: extTypeMap.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: queryUtil.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: querymsg.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: trans.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: transCli.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: transComm.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: transSasl.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: transSvr.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: transTLS.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: thttp.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: geomFunc.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tconfig.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tdigest.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tlog.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tmempool.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tpagedbuf.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: mpDirect.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: extCapability.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: systable.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tanalytics.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tdatablock.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tdataformat.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tglobal.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tmisce.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tname.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tpriv.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: ttime.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tvariant.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: streamMsg.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: streamWindowPlan.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tmsg.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: xnode.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: tencrypt.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: streamJson.c:taosDecodeSMqTopicInfoMsg Unexecuted instantiation: crypt.c:taosDecodeSMqTopicInfoMsg |
6847 | | |
6848 | | typedef struct { |
6849 | | int32_t status; // ask hb endpoint |
6850 | | int32_t epoch; |
6851 | | int64_t consumerId; |
6852 | | SArray* pTopics; // SArray<SMqHbTopicInfo> |
6853 | | } SMqReportReq; |
6854 | | |
6855 | 0 | static FORCE_INLINE int32_t taosEncodeSMqReportMsg(void** buf, const SMqReportReq* pMsg) { |
6856 | 0 | int32_t tlen = 0; |
6857 | 0 | tlen += taosEncodeFixedI32(buf, pMsg->status); |
6858 | 0 | tlen += taosEncodeFixedI32(buf, pMsg->epoch); |
6859 | 0 | tlen += taosEncodeFixedI64(buf, pMsg->consumerId); |
6860 | 0 | int32_t sz = taosArrayGetSize(pMsg->pTopics); |
6861 | 0 | tlen += taosEncodeFixedI32(buf, sz); |
6862 | 0 | for (int32_t i = 0; i < sz; i++) { |
6863 | 0 | SMqTopicInfo* topicInfo = (SMqTopicInfo*)taosArrayGet(pMsg->pTopics, i); |
6864 | 0 | tlen += taosEncodeSMqTopicInfoMsg(buf, topicInfo); |
6865 | 0 | } |
6866 | 0 | return tlen; |
6867 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosEncodeSMqReportMsg Unexecuted instantiation: parser.c:taosEncodeSMqReportMsg Unexecuted instantiation: parTranslater.c:taosEncodeSMqReportMsg Unexecuted instantiation: parUtil.c:taosEncodeSMqReportMsg Unexecuted instantiation: parAstParser.c:taosEncodeSMqReportMsg Unexecuted instantiation: parAuthenticator.c:taosEncodeSMqReportMsg Unexecuted instantiation: parCalcConst.c:taosEncodeSMqReportMsg Unexecuted instantiation: parInsertSql.c:taosEncodeSMqReportMsg Unexecuted instantiation: parInsertUtil.c:taosEncodeSMqReportMsg Unexecuted instantiation: taos_lemon_sql.tab.c:taosEncodeSMqReportMsg Unexecuted instantiation: parAstCreater.c:taosEncodeSMqReportMsg Unexecuted instantiation: parInsertSml.c:taosEncodeSMqReportMsg Unexecuted instantiation: planner.c:taosEncodeSMqReportMsg Unexecuted instantiation: planLogicCreater.c:taosEncodeSMqReportMsg Unexecuted instantiation: planOptimizer.c:taosEncodeSMqReportMsg Unexecuted instantiation: planPhysiCreater.c:taosEncodeSMqReportMsg Unexecuted instantiation: planScaleOut.c:taosEncodeSMqReportMsg Unexecuted instantiation: planSpliter.c:taosEncodeSMqReportMsg Unexecuted instantiation: planUtil.c:taosEncodeSMqReportMsg Unexecuted instantiation: planValidator.c:taosEncodeSMqReportMsg Unexecuted instantiation: catalog.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgAsync.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgCache.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgDbg.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgRemote.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgRent.c:taosEncodeSMqReportMsg Unexecuted instantiation: ctgUtil.c:taosEncodeSMqReportMsg Unexecuted instantiation: extConnector.c:taosEncodeSMqReportMsg Unexecuted instantiation: extDialect.c:taosEncodeSMqReportMsg Unexecuted instantiation: extDialectDefaults.c:taosEncodeSMqReportMsg Unexecuted instantiation: functionMgt.c:taosEncodeSMqReportMsg Unexecuted instantiation: tudf.c:taosEncodeSMqReportMsg Unexecuted instantiation: builtins.c:taosEncodeSMqReportMsg Unexecuted instantiation: builtinsimpl.c:taosEncodeSMqReportMsg Unexecuted instantiation: spillDistinctSet.c:taosEncodeSMqReportMsg Unexecuted instantiation: thistogram.c:taosEncodeSMqReportMsg Unexecuted instantiation: tpercentile.c:taosEncodeSMqReportMsg Unexecuted instantiation: tavgfunction.c:taosEncodeSMqReportMsg Unexecuted instantiation: tminmax.c:taosEncodeSMqReportMsg Unexecuted instantiation: tminmaxavx.c:taosEncodeSMqReportMsg Unexecuted instantiation: filter.c:taosEncodeSMqReportMsg Unexecuted instantiation: scalar.c:taosEncodeSMqReportMsg Unexecuted instantiation: sclfunc.c:taosEncodeSMqReportMsg Unexecuted instantiation: sclvector.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesCloneFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesCodeFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesEqualFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesMatchFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesMsgFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesToSQLFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesTraverseFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: nodesUtilFuncs.c:taosEncodeSMqReportMsg Unexecuted instantiation: extTypeMap.c:taosEncodeSMqReportMsg Unexecuted instantiation: queryUtil.c:taosEncodeSMqReportMsg Unexecuted instantiation: querymsg.c:taosEncodeSMqReportMsg Unexecuted instantiation: trans.c:taosEncodeSMqReportMsg Unexecuted instantiation: transCli.c:taosEncodeSMqReportMsg Unexecuted instantiation: transComm.c:taosEncodeSMqReportMsg Unexecuted instantiation: transSasl.c:taosEncodeSMqReportMsg Unexecuted instantiation: transSvr.c:taosEncodeSMqReportMsg Unexecuted instantiation: transTLS.c:taosEncodeSMqReportMsg Unexecuted instantiation: thttp.c:taosEncodeSMqReportMsg Unexecuted instantiation: geomFunc.c:taosEncodeSMqReportMsg Unexecuted instantiation: tconfig.c:taosEncodeSMqReportMsg Unexecuted instantiation: tdigest.c:taosEncodeSMqReportMsg Unexecuted instantiation: tlog.c:taosEncodeSMqReportMsg Unexecuted instantiation: tmempool.c:taosEncodeSMqReportMsg Unexecuted instantiation: tpagedbuf.c:taosEncodeSMqReportMsg Unexecuted instantiation: mpDirect.c:taosEncodeSMqReportMsg Unexecuted instantiation: extCapability.c:taosEncodeSMqReportMsg Unexecuted instantiation: systable.c:taosEncodeSMqReportMsg Unexecuted instantiation: tanalytics.c:taosEncodeSMqReportMsg Unexecuted instantiation: tdatablock.c:taosEncodeSMqReportMsg Unexecuted instantiation: tdataformat.c:taosEncodeSMqReportMsg Unexecuted instantiation: tglobal.c:taosEncodeSMqReportMsg Unexecuted instantiation: tmisce.c:taosEncodeSMqReportMsg Unexecuted instantiation: tname.c:taosEncodeSMqReportMsg Unexecuted instantiation: tpriv.c:taosEncodeSMqReportMsg Unexecuted instantiation: ttime.c:taosEncodeSMqReportMsg Unexecuted instantiation: tvariant.c:taosEncodeSMqReportMsg Unexecuted instantiation: streamMsg.c:taosEncodeSMqReportMsg Unexecuted instantiation: streamWindowPlan.c:taosEncodeSMqReportMsg Unexecuted instantiation: tmsg.c:taosEncodeSMqReportMsg Unexecuted instantiation: xnode.c:taosEncodeSMqReportMsg Unexecuted instantiation: tencrypt.c:taosEncodeSMqReportMsg Unexecuted instantiation: streamJson.c:taosEncodeSMqReportMsg Unexecuted instantiation: crypt.c:taosEncodeSMqReportMsg |
6868 | | |
6869 | 0 | static FORCE_INLINE void* taosDecodeSMqReportMsg(void* buf, SMqReportReq* pMsg) { |
6870 | 0 | buf = taosDecodeFixedI32(buf, &pMsg->status); |
6871 | 0 | buf = taosDecodeFixedI32(buf, &pMsg->epoch); |
6872 | 0 | buf = taosDecodeFixedI64(buf, &pMsg->consumerId); |
6873 | 0 | int32_t sz; |
6874 | 0 | buf = taosDecodeFixedI32(buf, &sz); |
6875 | 0 | if ((pMsg->pTopics = taosArrayInit(sz, sizeof(SMqTopicInfo))) == NULL) { |
6876 | 0 | return NULL; |
6877 | 0 | } |
6878 | 0 | for (int32_t i = 0; i < sz; i++) { |
6879 | 0 | SMqTopicInfo topicInfo; |
6880 | 0 | buf = taosDecodeSMqTopicInfoMsg(buf, &topicInfo); |
6881 | 0 | if (taosArrayPush(pMsg->pTopics, &topicInfo) == NULL) { |
6882 | 0 | return NULL; |
6883 | 0 | } |
6884 | 0 | } |
6885 | 0 | return buf; |
6886 | 0 | } Unexecuted instantiation: sql-fuzzer.c:taosDecodeSMqReportMsg Unexecuted instantiation: parser.c:taosDecodeSMqReportMsg Unexecuted instantiation: parTranslater.c:taosDecodeSMqReportMsg Unexecuted instantiation: parUtil.c:taosDecodeSMqReportMsg Unexecuted instantiation: parAstParser.c:taosDecodeSMqReportMsg Unexecuted instantiation: parAuthenticator.c:taosDecodeSMqReportMsg Unexecuted instantiation: parCalcConst.c:taosDecodeSMqReportMsg Unexecuted instantiation: parInsertSql.c:taosDecodeSMqReportMsg Unexecuted instantiation: parInsertUtil.c:taosDecodeSMqReportMsg Unexecuted instantiation: taos_lemon_sql.tab.c:taosDecodeSMqReportMsg Unexecuted instantiation: parAstCreater.c:taosDecodeSMqReportMsg Unexecuted instantiation: parInsertSml.c:taosDecodeSMqReportMsg Unexecuted instantiation: planner.c:taosDecodeSMqReportMsg Unexecuted instantiation: planLogicCreater.c:taosDecodeSMqReportMsg Unexecuted instantiation: planOptimizer.c:taosDecodeSMqReportMsg Unexecuted instantiation: planPhysiCreater.c:taosDecodeSMqReportMsg Unexecuted instantiation: planScaleOut.c:taosDecodeSMqReportMsg Unexecuted instantiation: planSpliter.c:taosDecodeSMqReportMsg Unexecuted instantiation: planUtil.c:taosDecodeSMqReportMsg Unexecuted instantiation: planValidator.c:taosDecodeSMqReportMsg Unexecuted instantiation: catalog.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgAsync.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgCache.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgDbg.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgRemote.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgRent.c:taosDecodeSMqReportMsg Unexecuted instantiation: ctgUtil.c:taosDecodeSMqReportMsg Unexecuted instantiation: extConnector.c:taosDecodeSMqReportMsg Unexecuted instantiation: extDialect.c:taosDecodeSMqReportMsg Unexecuted instantiation: extDialectDefaults.c:taosDecodeSMqReportMsg Unexecuted instantiation: functionMgt.c:taosDecodeSMqReportMsg Unexecuted instantiation: tudf.c:taosDecodeSMqReportMsg Unexecuted instantiation: builtins.c:taosDecodeSMqReportMsg Unexecuted instantiation: builtinsimpl.c:taosDecodeSMqReportMsg Unexecuted instantiation: spillDistinctSet.c:taosDecodeSMqReportMsg Unexecuted instantiation: thistogram.c:taosDecodeSMqReportMsg Unexecuted instantiation: tpercentile.c:taosDecodeSMqReportMsg Unexecuted instantiation: tavgfunction.c:taosDecodeSMqReportMsg Unexecuted instantiation: tminmax.c:taosDecodeSMqReportMsg Unexecuted instantiation: tminmaxavx.c:taosDecodeSMqReportMsg Unexecuted instantiation: filter.c:taosDecodeSMqReportMsg Unexecuted instantiation: scalar.c:taosDecodeSMqReportMsg Unexecuted instantiation: sclfunc.c:taosDecodeSMqReportMsg Unexecuted instantiation: sclvector.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesCloneFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesCodeFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesEqualFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesMatchFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesMsgFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesToSQLFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesTraverseFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: nodesUtilFuncs.c:taosDecodeSMqReportMsg Unexecuted instantiation: extTypeMap.c:taosDecodeSMqReportMsg Unexecuted instantiation: queryUtil.c:taosDecodeSMqReportMsg Unexecuted instantiation: querymsg.c:taosDecodeSMqReportMsg Unexecuted instantiation: trans.c:taosDecodeSMqReportMsg Unexecuted instantiation: transCli.c:taosDecodeSMqReportMsg Unexecuted instantiation: transComm.c:taosDecodeSMqReportMsg Unexecuted instantiation: transSasl.c:taosDecodeSMqReportMsg Unexecuted instantiation: transSvr.c:taosDecodeSMqReportMsg Unexecuted instantiation: transTLS.c:taosDecodeSMqReportMsg Unexecuted instantiation: thttp.c:taosDecodeSMqReportMsg Unexecuted instantiation: geomFunc.c:taosDecodeSMqReportMsg Unexecuted instantiation: tconfig.c:taosDecodeSMqReportMsg Unexecuted instantiation: tdigest.c:taosDecodeSMqReportMsg Unexecuted instantiation: tlog.c:taosDecodeSMqReportMsg Unexecuted instantiation: tmempool.c:taosDecodeSMqReportMsg Unexecuted instantiation: tpagedbuf.c:taosDecodeSMqReportMsg Unexecuted instantiation: mpDirect.c:taosDecodeSMqReportMsg Unexecuted instantiation: extCapability.c:taosDecodeSMqReportMsg Unexecuted instantiation: systable.c:taosDecodeSMqReportMsg Unexecuted instantiation: tanalytics.c:taosDecodeSMqReportMsg Unexecuted instantiation: tdatablock.c:taosDecodeSMqReportMsg Unexecuted instantiation: tdataformat.c:taosDecodeSMqReportMsg Unexecuted instantiation: tglobal.c:taosDecodeSMqReportMsg Unexecuted instantiation: tmisce.c:taosDecodeSMqReportMsg Unexecuted instantiation: tname.c:taosDecodeSMqReportMsg Unexecuted instantiation: tpriv.c:taosDecodeSMqReportMsg Unexecuted instantiation: ttime.c:taosDecodeSMqReportMsg Unexecuted instantiation: tvariant.c:taosDecodeSMqReportMsg Unexecuted instantiation: streamMsg.c:taosDecodeSMqReportMsg Unexecuted instantiation: streamWindowPlan.c:taosDecodeSMqReportMsg Unexecuted instantiation: tmsg.c:taosDecodeSMqReportMsg Unexecuted instantiation: xnode.c:taosDecodeSMqReportMsg Unexecuted instantiation: tencrypt.c:taosDecodeSMqReportMsg Unexecuted instantiation: streamJson.c:taosDecodeSMqReportMsg Unexecuted instantiation: crypt.c:taosDecodeSMqReportMsg |
6887 | | |
6888 | | typedef struct { |
6889 | | SMsgHead head; |
6890 | | int64_t leftForVer; |
6891 | | int32_t vgId; |
6892 | | int64_t consumerId; |
6893 | | char subKey[TSDB_SUBSCRIBE_KEY_LEN]; |
6894 | | } SMqVDeleteReq; |
6895 | | |
6896 | | typedef struct { |
6897 | | int8_t reserved; |
6898 | | } SMqVDeleteRsp; |
6899 | | |
6900 | | typedef struct { |
6901 | | char** name; |
6902 | | int32_t count; |
6903 | | int8_t igNotExists; |
6904 | | int64_t txnId; // batch meta txn ID (0 = not in txn) |
6905 | | } SMDropStreamReq; |
6906 | | |
6907 | | typedef struct { |
6908 | | int8_t reserved; |
6909 | | } SMDropStreamRsp; |
6910 | | |
6911 | | typedef struct { |
6912 | | SMsgHead head; |
6913 | | int64_t resetRelHalt; // reset related stream task halt status |
6914 | | int64_t streamId; |
6915 | | int32_t taskId; |
6916 | | } SVDropStreamTaskReq; |
6917 | | |
6918 | | typedef struct { |
6919 | | int8_t reserved; |
6920 | | } SVDropStreamTaskRsp; |
6921 | | |
6922 | | int32_t tSerializeSMDropStreamReq(void* buf, int32_t bufLen, const SMDropStreamReq* pReq); |
6923 | | int32_t tDeserializeSMDropStreamReq(void* buf, int32_t bufLen, SMDropStreamReq* pReq); |
6924 | | void tFreeMDropStreamReq(SMDropStreamReq* pReq); |
6925 | | |
6926 | | typedef struct { |
6927 | | char* name; |
6928 | | int8_t igNotExists; |
6929 | | } SMPauseStreamReq; |
6930 | | |
6931 | | int32_t tSerializeSMPauseStreamReq(void* buf, int32_t bufLen, const SMPauseStreamReq* pReq); |
6932 | | int32_t tDeserializeSMPauseStreamReq(void* buf, int32_t bufLen, SMPauseStreamReq* pReq); |
6933 | | void tFreeMPauseStreamReq(SMPauseStreamReq* pReq); |
6934 | | |
6935 | | typedef struct { |
6936 | | char* name; |
6937 | | int8_t igNotExists; |
6938 | | int8_t igUntreated; |
6939 | | } SMResumeStreamReq; |
6940 | | |
6941 | | int32_t tSerializeSMResumeStreamReq(void* buf, int32_t bufLen, const SMResumeStreamReq* pReq); |
6942 | | int32_t tDeserializeSMResumeStreamReq(void* buf, int32_t bufLen, SMResumeStreamReq* pReq); |
6943 | | void tFreeMResumeStreamReq(SMResumeStreamReq* pReq); |
6944 | | |
6945 | | typedef struct { |
6946 | | char* name; |
6947 | | int8_t calcAll; |
6948 | | STimeWindow timeRange; |
6949 | | } SMRecalcStreamReq; |
6950 | | |
6951 | | int32_t tSerializeSMRecalcStreamReq(void* buf, int32_t bufLen, const SMRecalcStreamReq* pReq); |
6952 | | int32_t tDeserializeSMRecalcStreamReq(void* buf, int32_t bufLen, SMRecalcStreamReq* pReq); |
6953 | | void tFreeMRecalcStreamReq(SMRecalcStreamReq* pReq); |
6954 | | |
6955 | | typedef struct SVndSetKeepVersionReq { |
6956 | | int64_t keepVersion; |
6957 | | } SVndSetKeepVersionReq; |
6958 | | |
6959 | | int32_t tSerializeSVndSetKeepVersionReq(void* buf, int32_t bufLen, SVndSetKeepVersionReq* pReq); |
6960 | | int32_t tDeserializeSVndSetKeepVersionReq(void* buf, int32_t bufLen, SVndSetKeepVersionReq* pReq); |
6961 | | |
6962 | | typedef struct SVUpdateCheckpointInfoReq { |
6963 | | SMsgHead head; |
6964 | | int64_t streamId; |
6965 | | int32_t taskId; |
6966 | | int64_t checkpointId; |
6967 | | int64_t checkpointVer; |
6968 | | int64_t checkpointTs; |
6969 | | int32_t transId; |
6970 | | int64_t hStreamId; // add encode/decode |
6971 | | int64_t hTaskId; |
6972 | | int8_t dropRelHTask; |
6973 | | } SVUpdateCheckpointInfoReq; |
6974 | | |
6975 | 0 | #define SMQ_REB_VG_REQ_VERSION 1 |
6976 | | |
6977 | | typedef struct { |
6978 | | int64_t leftForVer; |
6979 | | int32_t vgId; |
6980 | | int64_t oldConsumerId; |
6981 | | int64_t newConsumerId; |
6982 | | char subKey[TSDB_SUBSCRIBE_KEY_LEN]; |
6983 | | int8_t subType; |
6984 | | int8_t withMeta; |
6985 | | char* qmsg; // SubPlanToString |
6986 | | SSchemaWrapper schema; |
6987 | | int64_t suid; |
6988 | | } SMqRebVgReq; |
6989 | | |
6990 | | int32_t tEncodeSMqRebVgReq(SEncoder* pCoder, const SMqRebVgReq* pReq); |
6991 | | int32_t tDecodeSMqRebVgReq(SDecoder* pCoder, SMqRebVgReq* pReq); |
6992 | | |
6993 | | // tqOffset |
6994 | | enum { |
6995 | | TMQ_OFFSET__RESET_NONE = -3, |
6996 | | TMQ_OFFSET__RESET_EARLIEST = -2, |
6997 | | TMQ_OFFSET__RESET_LATEST = -1, |
6998 | | TMQ_OFFSET__LOG = 1, |
6999 | | TMQ_OFFSET__SNAPSHOT_DATA = 2, |
7000 | | TMQ_OFFSET__SNAPSHOT_META = 3, |
7001 | | }; |
7002 | | |
7003 | | enum { |
7004 | | ONLY_DATA = 0, |
7005 | | WITH_META = 1, |
7006 | | ONLY_META = 2, |
7007 | | }; |
7008 | | |
7009 | 0 | #define TQ_OFFSET_VERSION 1 |
7010 | | |
7011 | | typedef struct { |
7012 | | int8_t type; |
7013 | | union { |
7014 | | // snapshot |
7015 | | struct { |
7016 | | int64_t uid; |
7017 | | int64_t ts; |
7018 | | SValue primaryKey; |
7019 | | }; |
7020 | | // log |
7021 | | struct { |
7022 | | int64_t version; |
7023 | | }; |
7024 | | }; |
7025 | | } STqOffsetVal; |
7026 | | |
7027 | 0 | static FORCE_INLINE void tqOffsetResetToData(STqOffsetVal* pOffsetVal, int64_t uid, int64_t ts, SValue primaryKey) { |
7028 | 0 | pOffsetVal->type = TMQ_OFFSET__SNAPSHOT_DATA; |
7029 | 0 | pOffsetVal->uid = uid; |
7030 | 0 | pOffsetVal->ts = ts; |
7031 | 0 | if (IS_VAR_DATA_TYPE(pOffsetVal->primaryKey.type)) { |
7032 | 0 | taosMemoryFree(pOffsetVal->primaryKey.pData); |
7033 | 0 | } |
7034 | 0 | pOffsetVal->primaryKey = primaryKey; |
7035 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tqOffsetResetToData Unexecuted instantiation: parser.c:tqOffsetResetToData Unexecuted instantiation: parTranslater.c:tqOffsetResetToData Unexecuted instantiation: parUtil.c:tqOffsetResetToData Unexecuted instantiation: parAstParser.c:tqOffsetResetToData Unexecuted instantiation: parAuthenticator.c:tqOffsetResetToData Unexecuted instantiation: parCalcConst.c:tqOffsetResetToData Unexecuted instantiation: parInsertSql.c:tqOffsetResetToData Unexecuted instantiation: parInsertUtil.c:tqOffsetResetToData Unexecuted instantiation: taos_lemon_sql.tab.c:tqOffsetResetToData Unexecuted instantiation: parAstCreater.c:tqOffsetResetToData Unexecuted instantiation: parInsertSml.c:tqOffsetResetToData Unexecuted instantiation: planner.c:tqOffsetResetToData Unexecuted instantiation: planLogicCreater.c:tqOffsetResetToData Unexecuted instantiation: planOptimizer.c:tqOffsetResetToData Unexecuted instantiation: planPhysiCreater.c:tqOffsetResetToData Unexecuted instantiation: planScaleOut.c:tqOffsetResetToData Unexecuted instantiation: planSpliter.c:tqOffsetResetToData Unexecuted instantiation: planUtil.c:tqOffsetResetToData Unexecuted instantiation: planValidator.c:tqOffsetResetToData Unexecuted instantiation: catalog.c:tqOffsetResetToData Unexecuted instantiation: ctgAsync.c:tqOffsetResetToData Unexecuted instantiation: ctgCache.c:tqOffsetResetToData Unexecuted instantiation: ctgDbg.c:tqOffsetResetToData Unexecuted instantiation: ctgRemote.c:tqOffsetResetToData Unexecuted instantiation: ctgRent.c:tqOffsetResetToData Unexecuted instantiation: ctgUtil.c:tqOffsetResetToData Unexecuted instantiation: extConnector.c:tqOffsetResetToData Unexecuted instantiation: extDialect.c:tqOffsetResetToData Unexecuted instantiation: extDialectDefaults.c:tqOffsetResetToData Unexecuted instantiation: functionMgt.c:tqOffsetResetToData Unexecuted instantiation: tudf.c:tqOffsetResetToData Unexecuted instantiation: builtins.c:tqOffsetResetToData Unexecuted instantiation: builtinsimpl.c:tqOffsetResetToData Unexecuted instantiation: spillDistinctSet.c:tqOffsetResetToData Unexecuted instantiation: thistogram.c:tqOffsetResetToData Unexecuted instantiation: tpercentile.c:tqOffsetResetToData Unexecuted instantiation: tavgfunction.c:tqOffsetResetToData Unexecuted instantiation: tminmax.c:tqOffsetResetToData Unexecuted instantiation: tminmaxavx.c:tqOffsetResetToData Unexecuted instantiation: filter.c:tqOffsetResetToData Unexecuted instantiation: scalar.c:tqOffsetResetToData Unexecuted instantiation: sclfunc.c:tqOffsetResetToData Unexecuted instantiation: sclvector.c:tqOffsetResetToData Unexecuted instantiation: nodesCloneFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesCodeFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesEqualFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesMatchFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesMsgFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesRemotePlanToSQL.c:tqOffsetResetToData Unexecuted instantiation: nodesToSQLFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesTraverseFuncs.c:tqOffsetResetToData Unexecuted instantiation: nodesUtilFuncs.c:tqOffsetResetToData Unexecuted instantiation: extTypeMap.c:tqOffsetResetToData Unexecuted instantiation: queryUtil.c:tqOffsetResetToData Unexecuted instantiation: querymsg.c:tqOffsetResetToData Unexecuted instantiation: trans.c:tqOffsetResetToData Unexecuted instantiation: transCli.c:tqOffsetResetToData Unexecuted instantiation: transComm.c:tqOffsetResetToData Unexecuted instantiation: transSasl.c:tqOffsetResetToData Unexecuted instantiation: transSvr.c:tqOffsetResetToData Unexecuted instantiation: transTLS.c:tqOffsetResetToData Unexecuted instantiation: thttp.c:tqOffsetResetToData Unexecuted instantiation: geomFunc.c:tqOffsetResetToData Unexecuted instantiation: tconfig.c:tqOffsetResetToData Unexecuted instantiation: tdigest.c:tqOffsetResetToData Unexecuted instantiation: tlog.c:tqOffsetResetToData Unexecuted instantiation: tmempool.c:tqOffsetResetToData Unexecuted instantiation: tpagedbuf.c:tqOffsetResetToData Unexecuted instantiation: mpDirect.c:tqOffsetResetToData Unexecuted instantiation: extCapability.c:tqOffsetResetToData Unexecuted instantiation: systable.c:tqOffsetResetToData Unexecuted instantiation: tanalytics.c:tqOffsetResetToData Unexecuted instantiation: tdatablock.c:tqOffsetResetToData Unexecuted instantiation: tdataformat.c:tqOffsetResetToData Unexecuted instantiation: tglobal.c:tqOffsetResetToData Unexecuted instantiation: tmisce.c:tqOffsetResetToData Unexecuted instantiation: tname.c:tqOffsetResetToData Unexecuted instantiation: tpriv.c:tqOffsetResetToData Unexecuted instantiation: ttime.c:tqOffsetResetToData Unexecuted instantiation: tvariant.c:tqOffsetResetToData Unexecuted instantiation: streamMsg.c:tqOffsetResetToData Unexecuted instantiation: streamWindowPlan.c:tqOffsetResetToData Unexecuted instantiation: tmsg.c:tqOffsetResetToData Unexecuted instantiation: xnode.c:tqOffsetResetToData Unexecuted instantiation: tencrypt.c:tqOffsetResetToData Unexecuted instantiation: streamJson.c:tqOffsetResetToData Unexecuted instantiation: crypt.c:tqOffsetResetToData |
7036 | | |
7037 | 0 | static FORCE_INLINE void tqOffsetResetToMeta(STqOffsetVal* pOffsetVal, int64_t uid) { |
7038 | 0 | pOffsetVal->type = TMQ_OFFSET__SNAPSHOT_META; |
7039 | 0 | pOffsetVal->uid = uid; |
7040 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tqOffsetResetToMeta Unexecuted instantiation: parser.c:tqOffsetResetToMeta Unexecuted instantiation: parTranslater.c:tqOffsetResetToMeta Unexecuted instantiation: parUtil.c:tqOffsetResetToMeta Unexecuted instantiation: parAstParser.c:tqOffsetResetToMeta Unexecuted instantiation: parAuthenticator.c:tqOffsetResetToMeta Unexecuted instantiation: parCalcConst.c:tqOffsetResetToMeta Unexecuted instantiation: parInsertSql.c:tqOffsetResetToMeta Unexecuted instantiation: parInsertUtil.c:tqOffsetResetToMeta Unexecuted instantiation: taos_lemon_sql.tab.c:tqOffsetResetToMeta Unexecuted instantiation: parAstCreater.c:tqOffsetResetToMeta Unexecuted instantiation: parInsertSml.c:tqOffsetResetToMeta Unexecuted instantiation: planner.c:tqOffsetResetToMeta Unexecuted instantiation: planLogicCreater.c:tqOffsetResetToMeta Unexecuted instantiation: planOptimizer.c:tqOffsetResetToMeta Unexecuted instantiation: planPhysiCreater.c:tqOffsetResetToMeta Unexecuted instantiation: planScaleOut.c:tqOffsetResetToMeta Unexecuted instantiation: planSpliter.c:tqOffsetResetToMeta Unexecuted instantiation: planUtil.c:tqOffsetResetToMeta Unexecuted instantiation: planValidator.c:tqOffsetResetToMeta Unexecuted instantiation: catalog.c:tqOffsetResetToMeta Unexecuted instantiation: ctgAsync.c:tqOffsetResetToMeta Unexecuted instantiation: ctgCache.c:tqOffsetResetToMeta Unexecuted instantiation: ctgDbg.c:tqOffsetResetToMeta Unexecuted instantiation: ctgRemote.c:tqOffsetResetToMeta Unexecuted instantiation: ctgRent.c:tqOffsetResetToMeta Unexecuted instantiation: ctgUtil.c:tqOffsetResetToMeta Unexecuted instantiation: extConnector.c:tqOffsetResetToMeta Unexecuted instantiation: extDialect.c:tqOffsetResetToMeta Unexecuted instantiation: extDialectDefaults.c:tqOffsetResetToMeta Unexecuted instantiation: functionMgt.c:tqOffsetResetToMeta Unexecuted instantiation: tudf.c:tqOffsetResetToMeta Unexecuted instantiation: builtins.c:tqOffsetResetToMeta Unexecuted instantiation: builtinsimpl.c:tqOffsetResetToMeta Unexecuted instantiation: spillDistinctSet.c:tqOffsetResetToMeta Unexecuted instantiation: thistogram.c:tqOffsetResetToMeta Unexecuted instantiation: tpercentile.c:tqOffsetResetToMeta Unexecuted instantiation: tavgfunction.c:tqOffsetResetToMeta Unexecuted instantiation: tminmax.c:tqOffsetResetToMeta Unexecuted instantiation: tminmaxavx.c:tqOffsetResetToMeta Unexecuted instantiation: filter.c:tqOffsetResetToMeta Unexecuted instantiation: scalar.c:tqOffsetResetToMeta Unexecuted instantiation: sclfunc.c:tqOffsetResetToMeta Unexecuted instantiation: sclvector.c:tqOffsetResetToMeta Unexecuted instantiation: nodesCloneFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesCodeFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesEqualFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesMatchFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesMsgFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesRemotePlanToSQL.c:tqOffsetResetToMeta Unexecuted instantiation: nodesToSQLFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesTraverseFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: nodesUtilFuncs.c:tqOffsetResetToMeta Unexecuted instantiation: extTypeMap.c:tqOffsetResetToMeta Unexecuted instantiation: queryUtil.c:tqOffsetResetToMeta Unexecuted instantiation: querymsg.c:tqOffsetResetToMeta Unexecuted instantiation: trans.c:tqOffsetResetToMeta Unexecuted instantiation: transCli.c:tqOffsetResetToMeta Unexecuted instantiation: transComm.c:tqOffsetResetToMeta Unexecuted instantiation: transSasl.c:tqOffsetResetToMeta Unexecuted instantiation: transSvr.c:tqOffsetResetToMeta Unexecuted instantiation: transTLS.c:tqOffsetResetToMeta Unexecuted instantiation: thttp.c:tqOffsetResetToMeta Unexecuted instantiation: geomFunc.c:tqOffsetResetToMeta Unexecuted instantiation: tconfig.c:tqOffsetResetToMeta Unexecuted instantiation: tdigest.c:tqOffsetResetToMeta Unexecuted instantiation: tlog.c:tqOffsetResetToMeta Unexecuted instantiation: tmempool.c:tqOffsetResetToMeta Unexecuted instantiation: tpagedbuf.c:tqOffsetResetToMeta Unexecuted instantiation: mpDirect.c:tqOffsetResetToMeta Unexecuted instantiation: extCapability.c:tqOffsetResetToMeta Unexecuted instantiation: systable.c:tqOffsetResetToMeta Unexecuted instantiation: tanalytics.c:tqOffsetResetToMeta Unexecuted instantiation: tdatablock.c:tqOffsetResetToMeta Unexecuted instantiation: tdataformat.c:tqOffsetResetToMeta Unexecuted instantiation: tglobal.c:tqOffsetResetToMeta Unexecuted instantiation: tmisce.c:tqOffsetResetToMeta Unexecuted instantiation: tname.c:tqOffsetResetToMeta Unexecuted instantiation: tpriv.c:tqOffsetResetToMeta Unexecuted instantiation: ttime.c:tqOffsetResetToMeta Unexecuted instantiation: tvariant.c:tqOffsetResetToMeta Unexecuted instantiation: streamMsg.c:tqOffsetResetToMeta Unexecuted instantiation: streamWindowPlan.c:tqOffsetResetToMeta Unexecuted instantiation: tmsg.c:tqOffsetResetToMeta Unexecuted instantiation: xnode.c:tqOffsetResetToMeta Unexecuted instantiation: tencrypt.c:tqOffsetResetToMeta Unexecuted instantiation: streamJson.c:tqOffsetResetToMeta Unexecuted instantiation: crypt.c:tqOffsetResetToMeta |
7041 | | |
7042 | 0 | static FORCE_INLINE void tqOffsetResetToLog(STqOffsetVal* pOffsetVal, int64_t ver) { |
7043 | 0 | pOffsetVal->type = TMQ_OFFSET__LOG; |
7044 | 0 | pOffsetVal->version = ver; |
7045 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tqOffsetResetToLog Unexecuted instantiation: parser.c:tqOffsetResetToLog Unexecuted instantiation: parTranslater.c:tqOffsetResetToLog Unexecuted instantiation: parUtil.c:tqOffsetResetToLog Unexecuted instantiation: parAstParser.c:tqOffsetResetToLog Unexecuted instantiation: parAuthenticator.c:tqOffsetResetToLog Unexecuted instantiation: parCalcConst.c:tqOffsetResetToLog Unexecuted instantiation: parInsertSql.c:tqOffsetResetToLog Unexecuted instantiation: parInsertUtil.c:tqOffsetResetToLog Unexecuted instantiation: taos_lemon_sql.tab.c:tqOffsetResetToLog Unexecuted instantiation: parAstCreater.c:tqOffsetResetToLog Unexecuted instantiation: parInsertSml.c:tqOffsetResetToLog Unexecuted instantiation: planner.c:tqOffsetResetToLog Unexecuted instantiation: planLogicCreater.c:tqOffsetResetToLog Unexecuted instantiation: planOptimizer.c:tqOffsetResetToLog Unexecuted instantiation: planPhysiCreater.c:tqOffsetResetToLog Unexecuted instantiation: planScaleOut.c:tqOffsetResetToLog Unexecuted instantiation: planSpliter.c:tqOffsetResetToLog Unexecuted instantiation: planUtil.c:tqOffsetResetToLog Unexecuted instantiation: planValidator.c:tqOffsetResetToLog Unexecuted instantiation: catalog.c:tqOffsetResetToLog Unexecuted instantiation: ctgAsync.c:tqOffsetResetToLog Unexecuted instantiation: ctgCache.c:tqOffsetResetToLog Unexecuted instantiation: ctgDbg.c:tqOffsetResetToLog Unexecuted instantiation: ctgRemote.c:tqOffsetResetToLog Unexecuted instantiation: ctgRent.c:tqOffsetResetToLog Unexecuted instantiation: ctgUtil.c:tqOffsetResetToLog Unexecuted instantiation: extConnector.c:tqOffsetResetToLog Unexecuted instantiation: extDialect.c:tqOffsetResetToLog Unexecuted instantiation: extDialectDefaults.c:tqOffsetResetToLog Unexecuted instantiation: functionMgt.c:tqOffsetResetToLog Unexecuted instantiation: tudf.c:tqOffsetResetToLog Unexecuted instantiation: builtins.c:tqOffsetResetToLog Unexecuted instantiation: builtinsimpl.c:tqOffsetResetToLog Unexecuted instantiation: spillDistinctSet.c:tqOffsetResetToLog Unexecuted instantiation: thistogram.c:tqOffsetResetToLog Unexecuted instantiation: tpercentile.c:tqOffsetResetToLog Unexecuted instantiation: tavgfunction.c:tqOffsetResetToLog Unexecuted instantiation: tminmax.c:tqOffsetResetToLog Unexecuted instantiation: tminmaxavx.c:tqOffsetResetToLog Unexecuted instantiation: filter.c:tqOffsetResetToLog Unexecuted instantiation: scalar.c:tqOffsetResetToLog Unexecuted instantiation: sclfunc.c:tqOffsetResetToLog Unexecuted instantiation: sclvector.c:tqOffsetResetToLog Unexecuted instantiation: nodesCloneFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesCodeFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesEqualFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesMatchFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesMsgFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesRemotePlanToSQL.c:tqOffsetResetToLog Unexecuted instantiation: nodesToSQLFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesTraverseFuncs.c:tqOffsetResetToLog Unexecuted instantiation: nodesUtilFuncs.c:tqOffsetResetToLog Unexecuted instantiation: extTypeMap.c:tqOffsetResetToLog Unexecuted instantiation: queryUtil.c:tqOffsetResetToLog Unexecuted instantiation: querymsg.c:tqOffsetResetToLog Unexecuted instantiation: trans.c:tqOffsetResetToLog Unexecuted instantiation: transCli.c:tqOffsetResetToLog Unexecuted instantiation: transComm.c:tqOffsetResetToLog Unexecuted instantiation: transSasl.c:tqOffsetResetToLog Unexecuted instantiation: transSvr.c:tqOffsetResetToLog Unexecuted instantiation: transTLS.c:tqOffsetResetToLog Unexecuted instantiation: thttp.c:tqOffsetResetToLog Unexecuted instantiation: geomFunc.c:tqOffsetResetToLog Unexecuted instantiation: tconfig.c:tqOffsetResetToLog Unexecuted instantiation: tdigest.c:tqOffsetResetToLog Unexecuted instantiation: tlog.c:tqOffsetResetToLog Unexecuted instantiation: tmempool.c:tqOffsetResetToLog Unexecuted instantiation: tpagedbuf.c:tqOffsetResetToLog Unexecuted instantiation: mpDirect.c:tqOffsetResetToLog Unexecuted instantiation: extCapability.c:tqOffsetResetToLog Unexecuted instantiation: systable.c:tqOffsetResetToLog Unexecuted instantiation: tanalytics.c:tqOffsetResetToLog Unexecuted instantiation: tdatablock.c:tqOffsetResetToLog Unexecuted instantiation: tdataformat.c:tqOffsetResetToLog Unexecuted instantiation: tglobal.c:tqOffsetResetToLog Unexecuted instantiation: tmisce.c:tqOffsetResetToLog Unexecuted instantiation: tname.c:tqOffsetResetToLog Unexecuted instantiation: tpriv.c:tqOffsetResetToLog Unexecuted instantiation: ttime.c:tqOffsetResetToLog Unexecuted instantiation: tvariant.c:tqOffsetResetToLog Unexecuted instantiation: streamMsg.c:tqOffsetResetToLog Unexecuted instantiation: streamWindowPlan.c:tqOffsetResetToLog Unexecuted instantiation: tmsg.c:tqOffsetResetToLog Unexecuted instantiation: xnode.c:tqOffsetResetToLog Unexecuted instantiation: tencrypt.c:tqOffsetResetToLog Unexecuted instantiation: streamJson.c:tqOffsetResetToLog Unexecuted instantiation: crypt.c:tqOffsetResetToLog |
7046 | | |
7047 | | int32_t tEncodeSTqOffsetVal(SEncoder* pEncoder, const STqOffsetVal* pOffsetVal); |
7048 | | int32_t tDecodeSTqOffsetVal(SDecoder* pDecoder, STqOffsetVal* pOffsetVal); |
7049 | | void tFormatOffset(char* buf, int32_t maxLen, const STqOffsetVal* pVal); |
7050 | | bool tOffsetEqual(const STqOffsetVal* pLeft, const STqOffsetVal* pRight); |
7051 | | void tOffsetCopy(STqOffsetVal* pLeft, const STqOffsetVal* pRight); |
7052 | | void tOffsetDestroy(void* pVal); |
7053 | | |
7054 | | typedef struct { |
7055 | | STqOffsetVal val; |
7056 | | char subKey[TSDB_SUBSCRIBE_KEY_LEN]; |
7057 | | } STqOffset; |
7058 | | |
7059 | | int32_t tEncodeSTqOffset(SEncoder* pEncoder, const STqOffset* pOffset); |
7060 | | int32_t tDecodeSTqOffset(SDecoder* pDecoder, STqOffset* pOffset); |
7061 | | void tDeleteSTqOffset(void* val); |
7062 | | |
7063 | | typedef struct SMqVgOffset { |
7064 | | int64_t consumerId; |
7065 | | STqOffset offset; |
7066 | | } SMqVgOffset; |
7067 | | |
7068 | | int32_t tEncodeMqVgOffset(SEncoder* pEncoder, const SMqVgOffset* pOffset); |
7069 | | int32_t tDecodeMqVgOffset(SDecoder* pDecoder, SMqVgOffset* pOffset); |
7070 | | |
7071 | | typedef struct { |
7072 | | char name[TSDB_TABLE_FNAME_LEN]; |
7073 | | char stb[TSDB_TABLE_FNAME_LEN]; |
7074 | | int8_t igExists; |
7075 | | int8_t intervalUnit; |
7076 | | int8_t slidingUnit; |
7077 | | int8_t timezone; // int8_t is not enough, timezone is unit of second |
7078 | | int32_t dstVgId; // for stream |
7079 | | int64_t interval; |
7080 | | int64_t offset; |
7081 | | int64_t sliding; |
7082 | | int64_t maxDelay; |
7083 | | int64_t watermark; |
7084 | | int32_t exprLen; // strlen + 1 |
7085 | | int32_t tagsFilterLen; // strlen + 1 |
7086 | | int32_t sqlLen; // strlen + 1 |
7087 | | int32_t astLen; // strlen + 1 |
7088 | | char* expr; |
7089 | | char* tagsFilter; |
7090 | | char* sql; |
7091 | | char* ast; |
7092 | | int64_t deleteMark; |
7093 | | int64_t lastTs; |
7094 | | int64_t normSourceTbUid; // the Uid of source tb if its a normal table, otherwise 0 |
7095 | | SArray* pVgroupVerList; |
7096 | | int8_t recursiveTsma; |
7097 | | char baseTsmaName[TSDB_TABLE_FNAME_LEN]; // base tsma name for recursively created tsma |
7098 | | char* createStreamReq; |
7099 | | int32_t streamReqLen; |
7100 | | char* dropStreamReq; |
7101 | | int32_t dropStreamReqLen; |
7102 | | int64_t uid; |
7103 | | } SMCreateSmaReq; |
7104 | | |
7105 | | int32_t tSerializeSMCreateSmaReq(void* buf, int32_t bufLen, SMCreateSmaReq* pReq); |
7106 | | int32_t tDeserializeSMCreateSmaReq(void* buf, int32_t bufLen, SMCreateSmaReq* pReq); |
7107 | | void tFreeSMCreateSmaReq(SMCreateSmaReq* pReq); |
7108 | | |
7109 | | typedef struct { |
7110 | | char name[TSDB_TABLE_FNAME_LEN]; |
7111 | | int8_t igNotExists; |
7112 | | char* dropStreamReq; |
7113 | | int32_t dropStreamReqLen; |
7114 | | } SMDropSmaReq; |
7115 | | |
7116 | | int32_t tSerializeSMDropSmaReq(void* buf, int32_t bufLen, SMDropSmaReq* pReq); |
7117 | | int32_t tDeserializeSMDropSmaReq(void* buf, int32_t bufLen, SMDropSmaReq* pReq); |
7118 | | void tFreeSMDropSmaReq(SMDropSmaReq* pReq); |
7119 | | |
7120 | | typedef struct { |
7121 | | int32_t msgType; // begin, commit, rollback |
7122 | | int8_t clientStage; |
7123 | | txn_id_t txnId; |
7124 | | int64_t connId; |
7125 | | SSHashObj* pVgSet; // Hash set of int32_t vgId -> dummy, client-tracked participant VGroups |
7126 | | char dbFName[TSDB_DB_FNAME_LEN]; // participating DB fullName (replicated txn COMMIT/ROLLBACK) |
7127 | | } SMTransReq; |
7128 | | |
7129 | | int32_t tSerializeSMTransReq(void* buf, int32_t bufLen, SMTransReq* pReq); |
7130 | | int32_t tDeserializeSMTransReq(void* buf, int32_t bufLen, SMTransReq* pReq); |
7131 | | void tFreeSMTransReq(SMTransReq* pReq); |
7132 | | |
7133 | | // VNode registers with MNode to participate in a transaction (sent on first DDL carrying txnId) |
7134 | | typedef struct { |
7135 | | txn_id_t txnId; // global transaction ID |
7136 | | int32_t vgId; // sender VGroup ID |
7137 | | } SMndTxnRegReq; |
7138 | | |
7139 | | typedef struct { |
7140 | | int32_t code; // 0=success, non-zero=failure (e.g. txn expired or already rolled back) |
7141 | | txn_id_t txnId; |
7142 | | } SMndTxnRegRsp; |
7143 | | |
7144 | | // MNode -> VNode: COMMIT instruction for a single transaction |
7145 | | typedef struct { |
7146 | | txn_id_t txnId; |
7147 | | int64_t term; // current MNode Raft term (SyncTerm); used for VNode-side fencing |
7148 | | } SVTxnCommitReq; |
7149 | | |
7150 | | // MNode -> VNode: ROLLBACK instruction for a single transaction |
7151 | | typedef struct { |
7152 | | txn_id_t txnId; |
7153 | | int64_t term; // current MNode Raft term (SyncTerm); used for VNode-side fencing |
7154 | | int32_t reason; // rollback reason code (timeout / client disconnect / explicit user rollback, etc.) |
7155 | | } SVTxnRollbackReq; |
7156 | | |
7157 | | int32_t tSerializeSMndTxnRegReq(void* buf, int32_t bufLen, SMndTxnRegReq* pReq); |
7158 | | int32_t tDeserializeSMndTxnRegReq(void* buf, int32_t bufLen, SMndTxnRegReq* pReq); |
7159 | | int32_t tSerializeSMndTxnRegRsp(void* buf, int32_t bufLen, SMndTxnRegRsp* pRsp); |
7160 | | int32_t tDeserializeSMndTxnRegRsp(void* buf, int32_t bufLen, SMndTxnRegRsp* pRsp); |
7161 | | int32_t tSerializeSVTxnCommitReq(void* buf, int32_t bufLen, SVTxnCommitReq* pReq); |
7162 | | int32_t tDeserializeSVTxnCommitReq(void* buf, int32_t bufLen, SVTxnCommitReq* pReq); |
7163 | | int32_t tSerializeSVTxnRollbackReq(void* buf, int32_t bufLen, SVTxnRollbackReq* pReq); |
7164 | | int32_t tDeserializeSVTxnRollbackReq(void* buf, int32_t bufLen, SVTxnRollbackReq* pReq); |
7165 | | |
7166 | | // VNode -> DNode -> MNode keepalive query (piggy-backed onto SStatusReq) |
7167 | | typedef struct { |
7168 | | txn_id_t txnId; |
7169 | | int32_t vgId; // VNode issuing the query |
7170 | | } STxnActiveQuery; |
7171 | | |
7172 | | typedef struct { |
7173 | | char name[TSDB_TABLE_NAME_LEN]; |
7174 | | union { |
7175 | | char tbFName[TSDB_TABLE_FNAME_LEN]; // used by mnode |
7176 | | char tbName[TSDB_TABLE_NAME_LEN]; // used by vnode |
7177 | | }; |
7178 | | int8_t tbType; // ETableType: 1 stable, 3 normal table |
7179 | | union { |
7180 | | int8_t igExists; // used by mnode |
7181 | | int8_t alterType; // used by vnode |
7182 | | }; |
7183 | | int8_t intervalUnit; |
7184 | | int16_t nFuncs; // number of functions specified by user |
7185 | | col_id_t* funcColIds; // column ids specified by user |
7186 | | func_id_t* funcIds; // function ids specified by user |
7187 | | int64_t interval[2]; // 0 unspecified, > 0 valid interval |
7188 | | int64_t tbUid; |
7189 | | int64_t uid; // rsma uid |
7190 | | int32_t sqlLen; // strlen + 1 |
7191 | | char* sql; |
7192 | | } SMCreateRsmaReq; |
7193 | | |
7194 | | int32_t tSerializeSMCreateRsmaReq(void* buf, int32_t bufLen, SMCreateRsmaReq* pReq); |
7195 | | int32_t tDeserializeSMCreateRsmaReq(void* buf, int32_t bufLen, SMCreateRsmaReq* pReq); |
7196 | | void tFreeSMCreateRsmaReq(SMCreateRsmaReq* pReq); |
7197 | | |
7198 | | typedef SMCreateRsmaReq SVCreateRsmaReq; |
7199 | | |
7200 | | int32_t tSerializeSVCreateRsmaReq(void* buf, int32_t bufLen, SVCreateRsmaReq* pReq); |
7201 | | int32_t tDeserializeSVCreateRsmaReq(void* buf, int32_t bufLen, SVCreateRsmaReq* pReq); |
7202 | | void tFreeSVCreateRsmaReq(SVCreateRsmaReq* pReq); |
7203 | | |
7204 | | typedef SMCreateRsmaReq SVAlterRsmaReq; |
7205 | | |
7206 | | int32_t tSerializeSVAlterRsmaReq(void* buf, int32_t bufLen, SVAlterRsmaReq* pReq); |
7207 | | int32_t tDeserializeSVAlterRsmaReq(void* buf, int32_t bufLen, SVAlterRsmaReq* pReq); |
7208 | | void tFreeSVAlterRsmaReq(SVAlterRsmaReq* pReq); |
7209 | | |
7210 | | typedef struct { |
7211 | | char name[TSDB_TABLE_NAME_LEN]; |
7212 | | int8_t alterType; |
7213 | | int8_t tbType; // ETableType: 1 stable, 3 normal table |
7214 | | int8_t igNotExists; |
7215 | | int16_t nFuncs; // number of functions specified by user |
7216 | | col_id_t* funcColIds; // column ids specified by user |
7217 | | func_id_t* funcIds; // function ids specified by user |
7218 | | int32_t sqlLen; // strlen + 1 |
7219 | | char* sql; |
7220 | | } SMAlterRsmaReq; |
7221 | | |
7222 | | int32_t tSerializeSMAlterRsmaReq(void* buf, int32_t bufLen, SMAlterRsmaReq* pReq); |
7223 | | int32_t tDeserializeSMAlterRsmaReq(void* buf, int32_t bufLen, SMAlterRsmaReq* pReq); |
7224 | | void tFreeSMAlterRsmaReq(SMAlterRsmaReq* pReq); |
7225 | | |
7226 | | typedef struct { |
7227 | | int64_t id; |
7228 | | char name[TSDB_TABLE_NAME_LEN]; |
7229 | | char tbFName[TSDB_TABLE_FNAME_LEN]; |
7230 | | int64_t ownerId; |
7231 | | int32_t code; |
7232 | | int32_t version; |
7233 | | int8_t tbType; |
7234 | | int8_t intervalUnit; |
7235 | | col_id_t nFuncs; |
7236 | | col_id_t nColNames; |
7237 | | int64_t interval[2]; |
7238 | | col_id_t* funcColIds; |
7239 | | func_id_t* funcIds; |
7240 | | SArray* colNames; |
7241 | | } SRsmaInfoRsp; |
7242 | | |
7243 | | int32_t tSerializeRsmaInfoRsp(void* buf, int32_t bufLen, SRsmaInfoRsp* pReq); |
7244 | | int32_t tDeserializeRsmaInfoRsp(void* buf, int32_t bufLen, SRsmaInfoRsp* pReq); |
7245 | | void tFreeRsmaInfoRsp(SRsmaInfoRsp* pReq, bool deep); |
7246 | | |
7247 | | typedef struct { |
7248 | | char name[TSDB_TABLE_FNAME_LEN]; |
7249 | | int8_t igNotExists; |
7250 | | } SMDropRsmaReq; |
7251 | | |
7252 | | int32_t tSerializeSMDropRsmaReq(void* buf, int32_t bufLen, SMDropRsmaReq* pReq); |
7253 | | int32_t tDeserializeSMDropRsmaReq(void* buf, int32_t bufLen, SMDropRsmaReq* pReq); |
7254 | | |
7255 | | typedef struct { |
7256 | | char name[TSDB_TABLE_NAME_LEN]; |
7257 | | char tbName[TSDB_TABLE_NAME_LEN]; |
7258 | | int64_t uid; |
7259 | | int64_t tbUid; |
7260 | | int8_t tbType; |
7261 | | } SVDropRsmaReq; |
7262 | | |
7263 | | int32_t tSerializeSVDropRsmaReq(void* buf, int32_t bufLen, SVDropRsmaReq* pReq); |
7264 | | int32_t tDeserializeSVDropRsmaReq(void* buf, int32_t bufLen, SVDropRsmaReq* pReq); |
7265 | | |
7266 | | typedef struct { |
7267 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7268 | | char stbName[TSDB_TABLE_NAME_LEN]; |
7269 | | char colName[TSDB_COL_NAME_LEN]; |
7270 | | char idxName[TSDB_INDEX_FNAME_LEN]; |
7271 | | int8_t idxType; |
7272 | | } SCreateTagIndexReq; |
7273 | | |
7274 | | int32_t tSerializeSCreateTagIdxReq(void* buf, int32_t bufLen, SCreateTagIndexReq* pReq); |
7275 | | int32_t tDeserializeSCreateTagIdxReq(void* buf, int32_t bufLen, SCreateTagIndexReq* pReq); |
7276 | | |
7277 | | typedef SMDropSmaReq SDropTagIndexReq; |
7278 | | |
7279 | | // int32_t tSerializeSDropTagIdxReq(void* buf, int32_t bufLen, SDropTagIndexReq* pReq); |
7280 | | int32_t tDeserializeSDropTagIdxReq(void* buf, int32_t bufLen, SDropTagIndexReq* pReq); |
7281 | | |
7282 | | typedef struct { |
7283 | | int8_t version; // for compatibility(default 0) |
7284 | | int8_t intervalUnit; // MACRO: TIME_UNIT_XXX |
7285 | | int8_t slidingUnit; // MACRO: TIME_UNIT_XXX |
7286 | | int8_t timezoneInt; // sma data expired if timezone changes. |
7287 | | int32_t dstVgId; |
7288 | | char indexName[TSDB_INDEX_NAME_LEN]; |
7289 | | int32_t exprLen; |
7290 | | int32_t tagsFilterLen; |
7291 | | int64_t indexUid; |
7292 | | tb_uid_t tableUid; // super/child/common table uid |
7293 | | tb_uid_t dstTbUid; // for dstVgroup |
7294 | | int64_t interval; |
7295 | | int64_t offset; // use unit by precision of DB |
7296 | | int64_t sliding; |
7297 | | char* dstTbName; // for dstVgroup |
7298 | | char* expr; // sma expression |
7299 | | char* tagsFilter; |
7300 | | SSchemaWrapper schemaRow; // for dstVgroup |
7301 | | SSchemaWrapper schemaTag; // for dstVgroup |
7302 | | } STSma; // Time-range-wise SMA |
7303 | | |
7304 | | typedef STSma SVCreateTSmaReq; |
7305 | | |
7306 | | typedef struct { |
7307 | | int8_t type; // 0 status report, 1 update data |
7308 | | int64_t indexUid; |
7309 | | int64_t skey; // start TS key of interval/sliding window |
7310 | | } STSmaMsg; |
7311 | | |
7312 | | typedef struct { |
7313 | | int64_t indexUid; |
7314 | | char indexName[TSDB_INDEX_NAME_LEN]; |
7315 | | } SVDropTSmaReq; |
7316 | | |
7317 | | typedef struct { |
7318 | | int tmp; // TODO: to avoid compile error |
7319 | | } SVCreateTSmaRsp, SVDropTSmaRsp; |
7320 | | |
7321 | | #if 0 |
7322 | | int32_t tSerializeSVCreateTSmaReq(void** buf, SVCreateTSmaReq* pReq); |
7323 | | void* tDeserializeSVCreateTSmaReq(void* buf, SVCreateTSmaReq* pReq); |
7324 | | int32_t tSerializeSVDropTSmaReq(void** buf, SVDropTSmaReq* pReq); |
7325 | | void* tDeserializeSVDropTSmaReq(void* buf, SVDropTSmaReq* pReq); |
7326 | | #endif |
7327 | | |
7328 | | int32_t tEncodeSVCreateTSmaReq(SEncoder* pCoder, const SVCreateTSmaReq* pReq); |
7329 | | int32_t tDecodeSVCreateTSmaReq(SDecoder* pCoder, SVCreateTSmaReq* pReq); |
7330 | | int32_t tEncodeSVDropTSmaReq(SEncoder* pCoder, const SVDropTSmaReq* pReq); |
7331 | | // int32_t tDecodeSVDropTSmaReq(SDecoder* pCoder, SVDropTSmaReq* pReq); |
7332 | | |
7333 | | typedef struct { |
7334 | | int32_t number; |
7335 | | STSma* tSma; |
7336 | | } STSmaWrapper; |
7337 | | |
7338 | 0 | static FORCE_INLINE void tDestroyTSma(STSma* pSma) { |
7339 | 0 | if (pSma) { |
7340 | 0 | taosMemoryFreeClear(pSma->dstTbName); |
7341 | 0 | taosMemoryFreeClear(pSma->expr); |
7342 | 0 | taosMemoryFreeClear(pSma->tagsFilter); |
7343 | 0 | } |
7344 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDestroyTSma Unexecuted instantiation: parser.c:tDestroyTSma Unexecuted instantiation: parTranslater.c:tDestroyTSma Unexecuted instantiation: parUtil.c:tDestroyTSma Unexecuted instantiation: parAstParser.c:tDestroyTSma Unexecuted instantiation: parAuthenticator.c:tDestroyTSma Unexecuted instantiation: parCalcConst.c:tDestroyTSma Unexecuted instantiation: parInsertSql.c:tDestroyTSma Unexecuted instantiation: parInsertUtil.c:tDestroyTSma Unexecuted instantiation: taos_lemon_sql.tab.c:tDestroyTSma Unexecuted instantiation: parAstCreater.c:tDestroyTSma Unexecuted instantiation: parInsertSml.c:tDestroyTSma Unexecuted instantiation: planner.c:tDestroyTSma Unexecuted instantiation: planLogicCreater.c:tDestroyTSma Unexecuted instantiation: planOptimizer.c:tDestroyTSma Unexecuted instantiation: planPhysiCreater.c:tDestroyTSma Unexecuted instantiation: planScaleOut.c:tDestroyTSma Unexecuted instantiation: planSpliter.c:tDestroyTSma Unexecuted instantiation: planUtil.c:tDestroyTSma Unexecuted instantiation: planValidator.c:tDestroyTSma Unexecuted instantiation: catalog.c:tDestroyTSma Unexecuted instantiation: ctgAsync.c:tDestroyTSma Unexecuted instantiation: ctgCache.c:tDestroyTSma Unexecuted instantiation: ctgDbg.c:tDestroyTSma Unexecuted instantiation: ctgRemote.c:tDestroyTSma Unexecuted instantiation: ctgRent.c:tDestroyTSma Unexecuted instantiation: ctgUtil.c:tDestroyTSma Unexecuted instantiation: extConnector.c:tDestroyTSma Unexecuted instantiation: extDialect.c:tDestroyTSma Unexecuted instantiation: extDialectDefaults.c:tDestroyTSma Unexecuted instantiation: functionMgt.c:tDestroyTSma Unexecuted instantiation: tudf.c:tDestroyTSma Unexecuted instantiation: builtins.c:tDestroyTSma Unexecuted instantiation: builtinsimpl.c:tDestroyTSma Unexecuted instantiation: spillDistinctSet.c:tDestroyTSma Unexecuted instantiation: thistogram.c:tDestroyTSma Unexecuted instantiation: tpercentile.c:tDestroyTSma Unexecuted instantiation: tavgfunction.c:tDestroyTSma Unexecuted instantiation: tminmax.c:tDestroyTSma Unexecuted instantiation: tminmaxavx.c:tDestroyTSma Unexecuted instantiation: filter.c:tDestroyTSma Unexecuted instantiation: scalar.c:tDestroyTSma Unexecuted instantiation: sclfunc.c:tDestroyTSma Unexecuted instantiation: sclvector.c:tDestroyTSma Unexecuted instantiation: nodesCloneFuncs.c:tDestroyTSma Unexecuted instantiation: nodesCodeFuncs.c:tDestroyTSma Unexecuted instantiation: nodesEqualFuncs.c:tDestroyTSma Unexecuted instantiation: nodesMatchFuncs.c:tDestroyTSma Unexecuted instantiation: nodesMsgFuncs.c:tDestroyTSma Unexecuted instantiation: nodesRemotePlanToSQL.c:tDestroyTSma Unexecuted instantiation: nodesToSQLFuncs.c:tDestroyTSma Unexecuted instantiation: nodesTraverseFuncs.c:tDestroyTSma Unexecuted instantiation: nodesUtilFuncs.c:tDestroyTSma Unexecuted instantiation: extTypeMap.c:tDestroyTSma Unexecuted instantiation: queryUtil.c:tDestroyTSma Unexecuted instantiation: querymsg.c:tDestroyTSma Unexecuted instantiation: trans.c:tDestroyTSma Unexecuted instantiation: transCli.c:tDestroyTSma Unexecuted instantiation: transComm.c:tDestroyTSma Unexecuted instantiation: transSasl.c:tDestroyTSma Unexecuted instantiation: transSvr.c:tDestroyTSma Unexecuted instantiation: transTLS.c:tDestroyTSma Unexecuted instantiation: thttp.c:tDestroyTSma Unexecuted instantiation: geomFunc.c:tDestroyTSma Unexecuted instantiation: tconfig.c:tDestroyTSma Unexecuted instantiation: tdigest.c:tDestroyTSma Unexecuted instantiation: tlog.c:tDestroyTSma Unexecuted instantiation: tmempool.c:tDestroyTSma Unexecuted instantiation: tpagedbuf.c:tDestroyTSma Unexecuted instantiation: mpDirect.c:tDestroyTSma Unexecuted instantiation: extCapability.c:tDestroyTSma Unexecuted instantiation: systable.c:tDestroyTSma Unexecuted instantiation: tanalytics.c:tDestroyTSma Unexecuted instantiation: tdatablock.c:tDestroyTSma Unexecuted instantiation: tdataformat.c:tDestroyTSma Unexecuted instantiation: tglobal.c:tDestroyTSma Unexecuted instantiation: tmisce.c:tDestroyTSma Unexecuted instantiation: tname.c:tDestroyTSma Unexecuted instantiation: tpriv.c:tDestroyTSma Unexecuted instantiation: ttime.c:tDestroyTSma Unexecuted instantiation: tvariant.c:tDestroyTSma Unexecuted instantiation: streamMsg.c:tDestroyTSma Unexecuted instantiation: streamWindowPlan.c:tDestroyTSma Unexecuted instantiation: tmsg.c:tDestroyTSma Unexecuted instantiation: xnode.c:tDestroyTSma Unexecuted instantiation: tencrypt.c:tDestroyTSma Unexecuted instantiation: streamJson.c:tDestroyTSma Unexecuted instantiation: crypt.c:tDestroyTSma |
7345 | | |
7346 | 0 | static FORCE_INLINE void tDestroyTSmaWrapper(STSmaWrapper* pSW, bool deepCopy) { |
7347 | 0 | if (pSW) { |
7348 | 0 | if (pSW->tSma) { |
7349 | 0 | if (deepCopy) { |
7350 | 0 | for (uint32_t i = 0; i < pSW->number; ++i) { |
7351 | 0 | tDestroyTSma(pSW->tSma + i); |
7352 | 0 | } |
7353 | 0 | } |
7354 | 0 | taosMemoryFreeClear(pSW->tSma); |
7355 | 0 | } |
7356 | 0 | } |
7357 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDestroyTSmaWrapper Unexecuted instantiation: parser.c:tDestroyTSmaWrapper Unexecuted instantiation: parTranslater.c:tDestroyTSmaWrapper Unexecuted instantiation: parUtil.c:tDestroyTSmaWrapper Unexecuted instantiation: parAstParser.c:tDestroyTSmaWrapper Unexecuted instantiation: parAuthenticator.c:tDestroyTSmaWrapper Unexecuted instantiation: parCalcConst.c:tDestroyTSmaWrapper Unexecuted instantiation: parInsertSql.c:tDestroyTSmaWrapper Unexecuted instantiation: parInsertUtil.c:tDestroyTSmaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDestroyTSmaWrapper Unexecuted instantiation: parAstCreater.c:tDestroyTSmaWrapper Unexecuted instantiation: parInsertSml.c:tDestroyTSmaWrapper Unexecuted instantiation: planner.c:tDestroyTSmaWrapper Unexecuted instantiation: planLogicCreater.c:tDestroyTSmaWrapper Unexecuted instantiation: planOptimizer.c:tDestroyTSmaWrapper Unexecuted instantiation: planPhysiCreater.c:tDestroyTSmaWrapper Unexecuted instantiation: planScaleOut.c:tDestroyTSmaWrapper Unexecuted instantiation: planSpliter.c:tDestroyTSmaWrapper Unexecuted instantiation: planUtil.c:tDestroyTSmaWrapper Unexecuted instantiation: planValidator.c:tDestroyTSmaWrapper Unexecuted instantiation: catalog.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgAsync.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgCache.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgDbg.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgRemote.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgRent.c:tDestroyTSmaWrapper Unexecuted instantiation: ctgUtil.c:tDestroyTSmaWrapper Unexecuted instantiation: extConnector.c:tDestroyTSmaWrapper Unexecuted instantiation: extDialect.c:tDestroyTSmaWrapper Unexecuted instantiation: extDialectDefaults.c:tDestroyTSmaWrapper Unexecuted instantiation: functionMgt.c:tDestroyTSmaWrapper Unexecuted instantiation: tudf.c:tDestroyTSmaWrapper Unexecuted instantiation: builtins.c:tDestroyTSmaWrapper Unexecuted instantiation: builtinsimpl.c:tDestroyTSmaWrapper Unexecuted instantiation: spillDistinctSet.c:tDestroyTSmaWrapper Unexecuted instantiation: thistogram.c:tDestroyTSmaWrapper Unexecuted instantiation: tpercentile.c:tDestroyTSmaWrapper Unexecuted instantiation: tavgfunction.c:tDestroyTSmaWrapper Unexecuted instantiation: tminmax.c:tDestroyTSmaWrapper Unexecuted instantiation: tminmaxavx.c:tDestroyTSmaWrapper Unexecuted instantiation: filter.c:tDestroyTSmaWrapper Unexecuted instantiation: scalar.c:tDestroyTSmaWrapper Unexecuted instantiation: sclfunc.c:tDestroyTSmaWrapper Unexecuted instantiation: sclvector.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDestroyTSmaWrapper Unexecuted instantiation: extTypeMap.c:tDestroyTSmaWrapper Unexecuted instantiation: queryUtil.c:tDestroyTSmaWrapper Unexecuted instantiation: querymsg.c:tDestroyTSmaWrapper Unexecuted instantiation: trans.c:tDestroyTSmaWrapper Unexecuted instantiation: transCli.c:tDestroyTSmaWrapper Unexecuted instantiation: transComm.c:tDestroyTSmaWrapper Unexecuted instantiation: transSasl.c:tDestroyTSmaWrapper Unexecuted instantiation: transSvr.c:tDestroyTSmaWrapper Unexecuted instantiation: transTLS.c:tDestroyTSmaWrapper Unexecuted instantiation: thttp.c:tDestroyTSmaWrapper Unexecuted instantiation: geomFunc.c:tDestroyTSmaWrapper Unexecuted instantiation: tconfig.c:tDestroyTSmaWrapper Unexecuted instantiation: tdigest.c:tDestroyTSmaWrapper Unexecuted instantiation: tlog.c:tDestroyTSmaWrapper Unexecuted instantiation: tmempool.c:tDestroyTSmaWrapper Unexecuted instantiation: tpagedbuf.c:tDestroyTSmaWrapper Unexecuted instantiation: mpDirect.c:tDestroyTSmaWrapper Unexecuted instantiation: extCapability.c:tDestroyTSmaWrapper Unexecuted instantiation: systable.c:tDestroyTSmaWrapper Unexecuted instantiation: tanalytics.c:tDestroyTSmaWrapper Unexecuted instantiation: tdatablock.c:tDestroyTSmaWrapper Unexecuted instantiation: tdataformat.c:tDestroyTSmaWrapper Unexecuted instantiation: tglobal.c:tDestroyTSmaWrapper Unexecuted instantiation: tmisce.c:tDestroyTSmaWrapper Unexecuted instantiation: tname.c:tDestroyTSmaWrapper Unexecuted instantiation: tpriv.c:tDestroyTSmaWrapper Unexecuted instantiation: ttime.c:tDestroyTSmaWrapper Unexecuted instantiation: tvariant.c:tDestroyTSmaWrapper Unexecuted instantiation: streamMsg.c:tDestroyTSmaWrapper Unexecuted instantiation: streamWindowPlan.c:tDestroyTSmaWrapper Unexecuted instantiation: tmsg.c:tDestroyTSmaWrapper Unexecuted instantiation: xnode.c:tDestroyTSmaWrapper Unexecuted instantiation: tencrypt.c:tDestroyTSmaWrapper Unexecuted instantiation: streamJson.c:tDestroyTSmaWrapper Unexecuted instantiation: crypt.c:tDestroyTSmaWrapper |
7358 | | |
7359 | 0 | static FORCE_INLINE void* tFreeTSmaWrapper(STSmaWrapper* pSW, bool deepCopy) { |
7360 | 0 | tDestroyTSmaWrapper(pSW, deepCopy); |
7361 | 0 | taosMemoryFreeClear(pSW); |
7362 | 0 | return NULL; |
7363 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeTSmaWrapper Unexecuted instantiation: parser.c:tFreeTSmaWrapper Unexecuted instantiation: parTranslater.c:tFreeTSmaWrapper Unexecuted instantiation: parUtil.c:tFreeTSmaWrapper Unexecuted instantiation: parAstParser.c:tFreeTSmaWrapper Unexecuted instantiation: parAuthenticator.c:tFreeTSmaWrapper Unexecuted instantiation: parCalcConst.c:tFreeTSmaWrapper Unexecuted instantiation: parInsertSql.c:tFreeTSmaWrapper Unexecuted instantiation: parInsertUtil.c:tFreeTSmaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeTSmaWrapper Unexecuted instantiation: parAstCreater.c:tFreeTSmaWrapper Unexecuted instantiation: parInsertSml.c:tFreeTSmaWrapper Unexecuted instantiation: planner.c:tFreeTSmaWrapper Unexecuted instantiation: planLogicCreater.c:tFreeTSmaWrapper Unexecuted instantiation: planOptimizer.c:tFreeTSmaWrapper Unexecuted instantiation: planPhysiCreater.c:tFreeTSmaWrapper Unexecuted instantiation: planScaleOut.c:tFreeTSmaWrapper Unexecuted instantiation: planSpliter.c:tFreeTSmaWrapper Unexecuted instantiation: planUtil.c:tFreeTSmaWrapper Unexecuted instantiation: planValidator.c:tFreeTSmaWrapper Unexecuted instantiation: catalog.c:tFreeTSmaWrapper Unexecuted instantiation: ctgAsync.c:tFreeTSmaWrapper Unexecuted instantiation: ctgCache.c:tFreeTSmaWrapper Unexecuted instantiation: ctgDbg.c:tFreeTSmaWrapper Unexecuted instantiation: ctgRemote.c:tFreeTSmaWrapper Unexecuted instantiation: ctgRent.c:tFreeTSmaWrapper Unexecuted instantiation: ctgUtil.c:tFreeTSmaWrapper Unexecuted instantiation: extConnector.c:tFreeTSmaWrapper Unexecuted instantiation: extDialect.c:tFreeTSmaWrapper Unexecuted instantiation: extDialectDefaults.c:tFreeTSmaWrapper Unexecuted instantiation: functionMgt.c:tFreeTSmaWrapper Unexecuted instantiation: tudf.c:tFreeTSmaWrapper Unexecuted instantiation: builtins.c:tFreeTSmaWrapper Unexecuted instantiation: builtinsimpl.c:tFreeTSmaWrapper Unexecuted instantiation: spillDistinctSet.c:tFreeTSmaWrapper Unexecuted instantiation: thistogram.c:tFreeTSmaWrapper Unexecuted instantiation: tpercentile.c:tFreeTSmaWrapper Unexecuted instantiation: tavgfunction.c:tFreeTSmaWrapper Unexecuted instantiation: tminmax.c:tFreeTSmaWrapper Unexecuted instantiation: tminmaxavx.c:tFreeTSmaWrapper Unexecuted instantiation: filter.c:tFreeTSmaWrapper Unexecuted instantiation: scalar.c:tFreeTSmaWrapper Unexecuted instantiation: sclfunc.c:tFreeTSmaWrapper Unexecuted instantiation: sclvector.c:tFreeTSmaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeTSmaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tFreeTSmaWrapper Unexecuted instantiation: extTypeMap.c:tFreeTSmaWrapper Unexecuted instantiation: queryUtil.c:tFreeTSmaWrapper Unexecuted instantiation: querymsg.c:tFreeTSmaWrapper Unexecuted instantiation: trans.c:tFreeTSmaWrapper Unexecuted instantiation: transCli.c:tFreeTSmaWrapper Unexecuted instantiation: transComm.c:tFreeTSmaWrapper Unexecuted instantiation: transSasl.c:tFreeTSmaWrapper Unexecuted instantiation: transSvr.c:tFreeTSmaWrapper Unexecuted instantiation: transTLS.c:tFreeTSmaWrapper Unexecuted instantiation: thttp.c:tFreeTSmaWrapper Unexecuted instantiation: geomFunc.c:tFreeTSmaWrapper Unexecuted instantiation: tconfig.c:tFreeTSmaWrapper Unexecuted instantiation: tdigest.c:tFreeTSmaWrapper Unexecuted instantiation: tlog.c:tFreeTSmaWrapper Unexecuted instantiation: tmempool.c:tFreeTSmaWrapper Unexecuted instantiation: tpagedbuf.c:tFreeTSmaWrapper Unexecuted instantiation: mpDirect.c:tFreeTSmaWrapper Unexecuted instantiation: extCapability.c:tFreeTSmaWrapper Unexecuted instantiation: systable.c:tFreeTSmaWrapper Unexecuted instantiation: tanalytics.c:tFreeTSmaWrapper Unexecuted instantiation: tdatablock.c:tFreeTSmaWrapper Unexecuted instantiation: tdataformat.c:tFreeTSmaWrapper Unexecuted instantiation: tglobal.c:tFreeTSmaWrapper Unexecuted instantiation: tmisce.c:tFreeTSmaWrapper Unexecuted instantiation: tname.c:tFreeTSmaWrapper Unexecuted instantiation: tpriv.c:tFreeTSmaWrapper Unexecuted instantiation: ttime.c:tFreeTSmaWrapper Unexecuted instantiation: tvariant.c:tFreeTSmaWrapper Unexecuted instantiation: streamMsg.c:tFreeTSmaWrapper Unexecuted instantiation: streamWindowPlan.c:tFreeTSmaWrapper Unexecuted instantiation: tmsg.c:tFreeTSmaWrapper Unexecuted instantiation: xnode.c:tFreeTSmaWrapper Unexecuted instantiation: tencrypt.c:tFreeTSmaWrapper Unexecuted instantiation: streamJson.c:tFreeTSmaWrapper Unexecuted instantiation: crypt.c:tFreeTSmaWrapper |
7364 | | |
7365 | | int32_t tEncodeSVCreateTSmaReq(SEncoder* pCoder, const SVCreateTSmaReq* pReq); |
7366 | | int32_t tDecodeSVCreateTSmaReq(SDecoder* pCoder, SVCreateTSmaReq* pReq); |
7367 | | |
7368 | | int32_t tEncodeTSma(SEncoder* pCoder, const STSma* pSma); |
7369 | | int32_t tDecodeTSma(SDecoder* pCoder, STSma* pSma, bool deepCopy); |
7370 | | |
7371 | 0 | static int32_t tEncodeTSmaWrapper(SEncoder* pEncoder, const STSmaWrapper* pReq) { |
7372 | 0 | TAOS_CHECK_RETURN(tEncodeI32(pEncoder, pReq->number)); |
7373 | 0 | for (int32_t i = 0; i < pReq->number; ++i) { |
7374 | 0 | TAOS_CHECK_RETURN(tEncodeTSma(pEncoder, pReq->tSma + i)); |
7375 | 0 | } |
7376 | 0 | return 0; |
7377 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeTSmaWrapper Unexecuted instantiation: parser.c:tEncodeTSmaWrapper Unexecuted instantiation: parTranslater.c:tEncodeTSmaWrapper Unexecuted instantiation: parUtil.c:tEncodeTSmaWrapper Unexecuted instantiation: parAstParser.c:tEncodeTSmaWrapper Unexecuted instantiation: parAuthenticator.c:tEncodeTSmaWrapper Unexecuted instantiation: parCalcConst.c:tEncodeTSmaWrapper Unexecuted instantiation: parInsertSql.c:tEncodeTSmaWrapper Unexecuted instantiation: parInsertUtil.c:tEncodeTSmaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeTSmaWrapper Unexecuted instantiation: parAstCreater.c:tEncodeTSmaWrapper Unexecuted instantiation: parInsertSml.c:tEncodeTSmaWrapper Unexecuted instantiation: planner.c:tEncodeTSmaWrapper Unexecuted instantiation: planLogicCreater.c:tEncodeTSmaWrapper Unexecuted instantiation: planOptimizer.c:tEncodeTSmaWrapper Unexecuted instantiation: planPhysiCreater.c:tEncodeTSmaWrapper Unexecuted instantiation: planScaleOut.c:tEncodeTSmaWrapper Unexecuted instantiation: planSpliter.c:tEncodeTSmaWrapper Unexecuted instantiation: planUtil.c:tEncodeTSmaWrapper Unexecuted instantiation: planValidator.c:tEncodeTSmaWrapper Unexecuted instantiation: catalog.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgAsync.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgCache.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgDbg.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgRemote.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgRent.c:tEncodeTSmaWrapper Unexecuted instantiation: ctgUtil.c:tEncodeTSmaWrapper Unexecuted instantiation: extConnector.c:tEncodeTSmaWrapper Unexecuted instantiation: extDialect.c:tEncodeTSmaWrapper Unexecuted instantiation: extDialectDefaults.c:tEncodeTSmaWrapper Unexecuted instantiation: functionMgt.c:tEncodeTSmaWrapper Unexecuted instantiation: tudf.c:tEncodeTSmaWrapper Unexecuted instantiation: builtins.c:tEncodeTSmaWrapper Unexecuted instantiation: builtinsimpl.c:tEncodeTSmaWrapper Unexecuted instantiation: spillDistinctSet.c:tEncodeTSmaWrapper Unexecuted instantiation: thistogram.c:tEncodeTSmaWrapper Unexecuted instantiation: tpercentile.c:tEncodeTSmaWrapper Unexecuted instantiation: tavgfunction.c:tEncodeTSmaWrapper Unexecuted instantiation: tminmax.c:tEncodeTSmaWrapper Unexecuted instantiation: tminmaxavx.c:tEncodeTSmaWrapper Unexecuted instantiation: filter.c:tEncodeTSmaWrapper Unexecuted instantiation: scalar.c:tEncodeTSmaWrapper Unexecuted instantiation: sclfunc.c:tEncodeTSmaWrapper Unexecuted instantiation: sclvector.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tEncodeTSmaWrapper Unexecuted instantiation: extTypeMap.c:tEncodeTSmaWrapper Unexecuted instantiation: queryUtil.c:tEncodeTSmaWrapper Unexecuted instantiation: querymsg.c:tEncodeTSmaWrapper Unexecuted instantiation: trans.c:tEncodeTSmaWrapper Unexecuted instantiation: transCli.c:tEncodeTSmaWrapper Unexecuted instantiation: transComm.c:tEncodeTSmaWrapper Unexecuted instantiation: transSasl.c:tEncodeTSmaWrapper Unexecuted instantiation: transSvr.c:tEncodeTSmaWrapper Unexecuted instantiation: transTLS.c:tEncodeTSmaWrapper Unexecuted instantiation: thttp.c:tEncodeTSmaWrapper Unexecuted instantiation: geomFunc.c:tEncodeTSmaWrapper Unexecuted instantiation: tconfig.c:tEncodeTSmaWrapper Unexecuted instantiation: tdigest.c:tEncodeTSmaWrapper Unexecuted instantiation: tlog.c:tEncodeTSmaWrapper Unexecuted instantiation: tmempool.c:tEncodeTSmaWrapper Unexecuted instantiation: tpagedbuf.c:tEncodeTSmaWrapper Unexecuted instantiation: mpDirect.c:tEncodeTSmaWrapper Unexecuted instantiation: extCapability.c:tEncodeTSmaWrapper Unexecuted instantiation: systable.c:tEncodeTSmaWrapper Unexecuted instantiation: tanalytics.c:tEncodeTSmaWrapper Unexecuted instantiation: tdatablock.c:tEncodeTSmaWrapper Unexecuted instantiation: tdataformat.c:tEncodeTSmaWrapper Unexecuted instantiation: tglobal.c:tEncodeTSmaWrapper Unexecuted instantiation: tmisce.c:tEncodeTSmaWrapper Unexecuted instantiation: tname.c:tEncodeTSmaWrapper Unexecuted instantiation: tpriv.c:tEncodeTSmaWrapper Unexecuted instantiation: ttime.c:tEncodeTSmaWrapper Unexecuted instantiation: tvariant.c:tEncodeTSmaWrapper Unexecuted instantiation: streamMsg.c:tEncodeTSmaWrapper Unexecuted instantiation: streamWindowPlan.c:tEncodeTSmaWrapper Unexecuted instantiation: tmsg.c:tEncodeTSmaWrapper Unexecuted instantiation: xnode.c:tEncodeTSmaWrapper Unexecuted instantiation: tencrypt.c:tEncodeTSmaWrapper Unexecuted instantiation: streamJson.c:tEncodeTSmaWrapper Unexecuted instantiation: crypt.c:tEncodeTSmaWrapper |
7378 | | |
7379 | 0 | static int32_t tDecodeTSmaWrapper(SDecoder* pDecoder, STSmaWrapper* pReq, bool deepCopy) { |
7380 | 0 | TAOS_CHECK_RETURN(tDecodeI32(pDecoder, &pReq->number)); |
7381 | 0 | for (int32_t i = 0; i < pReq->number; ++i) { |
7382 | 0 | TAOS_CHECK_RETURN(tDecodeTSma(pDecoder, pReq->tSma + i, deepCopy)); |
7383 | 0 | } |
7384 | 0 | return 0; |
7385 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeTSmaWrapper Unexecuted instantiation: parser.c:tDecodeTSmaWrapper Unexecuted instantiation: parTranslater.c:tDecodeTSmaWrapper Unexecuted instantiation: parUtil.c:tDecodeTSmaWrapper Unexecuted instantiation: parAstParser.c:tDecodeTSmaWrapper Unexecuted instantiation: parAuthenticator.c:tDecodeTSmaWrapper Unexecuted instantiation: parCalcConst.c:tDecodeTSmaWrapper Unexecuted instantiation: parInsertSql.c:tDecodeTSmaWrapper Unexecuted instantiation: parInsertUtil.c:tDecodeTSmaWrapper Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeTSmaWrapper Unexecuted instantiation: parAstCreater.c:tDecodeTSmaWrapper Unexecuted instantiation: parInsertSml.c:tDecodeTSmaWrapper Unexecuted instantiation: planner.c:tDecodeTSmaWrapper Unexecuted instantiation: planLogicCreater.c:tDecodeTSmaWrapper Unexecuted instantiation: planOptimizer.c:tDecodeTSmaWrapper Unexecuted instantiation: planPhysiCreater.c:tDecodeTSmaWrapper Unexecuted instantiation: planScaleOut.c:tDecodeTSmaWrapper Unexecuted instantiation: planSpliter.c:tDecodeTSmaWrapper Unexecuted instantiation: planUtil.c:tDecodeTSmaWrapper Unexecuted instantiation: planValidator.c:tDecodeTSmaWrapper Unexecuted instantiation: catalog.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgAsync.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgCache.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgDbg.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgRemote.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgRent.c:tDecodeTSmaWrapper Unexecuted instantiation: ctgUtil.c:tDecodeTSmaWrapper Unexecuted instantiation: extConnector.c:tDecodeTSmaWrapper Unexecuted instantiation: extDialect.c:tDecodeTSmaWrapper Unexecuted instantiation: extDialectDefaults.c:tDecodeTSmaWrapper Unexecuted instantiation: functionMgt.c:tDecodeTSmaWrapper Unexecuted instantiation: tudf.c:tDecodeTSmaWrapper Unexecuted instantiation: builtins.c:tDecodeTSmaWrapper Unexecuted instantiation: builtinsimpl.c:tDecodeTSmaWrapper Unexecuted instantiation: spillDistinctSet.c:tDecodeTSmaWrapper Unexecuted instantiation: thistogram.c:tDecodeTSmaWrapper Unexecuted instantiation: tpercentile.c:tDecodeTSmaWrapper Unexecuted instantiation: tavgfunction.c:tDecodeTSmaWrapper Unexecuted instantiation: tminmax.c:tDecodeTSmaWrapper Unexecuted instantiation: tminmaxavx.c:tDecodeTSmaWrapper Unexecuted instantiation: filter.c:tDecodeTSmaWrapper Unexecuted instantiation: scalar.c:tDecodeTSmaWrapper Unexecuted instantiation: sclfunc.c:tDecodeTSmaWrapper Unexecuted instantiation: sclvector.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesCloneFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesCodeFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesEqualFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesMatchFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesMsgFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: nodesUtilFuncs.c:tDecodeTSmaWrapper Unexecuted instantiation: extTypeMap.c:tDecodeTSmaWrapper Unexecuted instantiation: queryUtil.c:tDecodeTSmaWrapper Unexecuted instantiation: querymsg.c:tDecodeTSmaWrapper Unexecuted instantiation: trans.c:tDecodeTSmaWrapper Unexecuted instantiation: transCli.c:tDecodeTSmaWrapper Unexecuted instantiation: transComm.c:tDecodeTSmaWrapper Unexecuted instantiation: transSasl.c:tDecodeTSmaWrapper Unexecuted instantiation: transSvr.c:tDecodeTSmaWrapper Unexecuted instantiation: transTLS.c:tDecodeTSmaWrapper Unexecuted instantiation: thttp.c:tDecodeTSmaWrapper Unexecuted instantiation: geomFunc.c:tDecodeTSmaWrapper Unexecuted instantiation: tconfig.c:tDecodeTSmaWrapper Unexecuted instantiation: tdigest.c:tDecodeTSmaWrapper Unexecuted instantiation: tlog.c:tDecodeTSmaWrapper Unexecuted instantiation: tmempool.c:tDecodeTSmaWrapper Unexecuted instantiation: tpagedbuf.c:tDecodeTSmaWrapper Unexecuted instantiation: mpDirect.c:tDecodeTSmaWrapper Unexecuted instantiation: extCapability.c:tDecodeTSmaWrapper Unexecuted instantiation: systable.c:tDecodeTSmaWrapper Unexecuted instantiation: tanalytics.c:tDecodeTSmaWrapper Unexecuted instantiation: tdatablock.c:tDecodeTSmaWrapper Unexecuted instantiation: tdataformat.c:tDecodeTSmaWrapper Unexecuted instantiation: tglobal.c:tDecodeTSmaWrapper Unexecuted instantiation: tmisce.c:tDecodeTSmaWrapper Unexecuted instantiation: tname.c:tDecodeTSmaWrapper Unexecuted instantiation: tpriv.c:tDecodeTSmaWrapper Unexecuted instantiation: ttime.c:tDecodeTSmaWrapper Unexecuted instantiation: tvariant.c:tDecodeTSmaWrapper Unexecuted instantiation: streamMsg.c:tDecodeTSmaWrapper Unexecuted instantiation: streamWindowPlan.c:tDecodeTSmaWrapper Unexecuted instantiation: tmsg.c:tDecodeTSmaWrapper Unexecuted instantiation: xnode.c:tDecodeTSmaWrapper Unexecuted instantiation: tencrypt.c:tDecodeTSmaWrapper Unexecuted instantiation: streamJson.c:tDecodeTSmaWrapper Unexecuted instantiation: crypt.c:tDecodeTSmaWrapper |
7386 | | |
7387 | | typedef struct { |
7388 | | int idx; |
7389 | | } SMCreateFullTextReq; |
7390 | | |
7391 | | int32_t tSerializeSMCreateFullTextReq(void* buf, int32_t bufLen, SMCreateFullTextReq* pReq); |
7392 | | int32_t tDeserializeSMCreateFullTextReq(void* buf, int32_t bufLen, SMCreateFullTextReq* pReq); |
7393 | | void tFreeSMCreateFullTextReq(SMCreateFullTextReq* pReq); |
7394 | | |
7395 | | typedef struct { |
7396 | | char name[TSDB_TABLE_FNAME_LEN]; |
7397 | | int8_t igNotExists; |
7398 | | } SMDropFullTextReq; |
7399 | | |
7400 | | // int32_t tSerializeSMDropFullTextReq(void* buf, int32_t bufLen, SMDropFullTextReq* pReq); |
7401 | | // int32_t tDeserializeSMDropFullTextReq(void* buf, int32_t bufLen, SMDropFullTextReq* pReq); |
7402 | | |
7403 | | typedef struct { |
7404 | | char indexFName[TSDB_INDEX_FNAME_LEN]; |
7405 | | } SUserIndexReq; |
7406 | | |
7407 | | int32_t tSerializeSUserIndexReq(void* buf, int32_t bufLen, SUserIndexReq* pReq); |
7408 | | int32_t tDeserializeSUserIndexReq(void* buf, int32_t bufLen, SUserIndexReq* pReq); |
7409 | | |
7410 | | typedef struct { |
7411 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7412 | | char tblFName[TSDB_TABLE_FNAME_LEN]; |
7413 | | char colName[TSDB_COL_NAME_LEN]; |
7414 | | char owner[TSDB_USER_LEN]; |
7415 | | char indexType[TSDB_INDEX_TYPE_LEN]; |
7416 | | char indexExts[TSDB_INDEX_EXTS_LEN]; |
7417 | | } SUserIndexRsp; |
7418 | | |
7419 | | int32_t tSerializeSUserIndexRsp(void* buf, int32_t bufLen, const SUserIndexRsp* pRsp); |
7420 | | int32_t tDeserializeSUserIndexRsp(void* buf, int32_t bufLen, SUserIndexRsp* pRsp); |
7421 | | |
7422 | | typedef struct { |
7423 | | char tbFName[TSDB_TABLE_FNAME_LEN]; |
7424 | | } STableIndexReq; |
7425 | | |
7426 | | int32_t tSerializeSTableIndexReq(void* buf, int32_t bufLen, STableIndexReq* pReq); |
7427 | | int32_t tDeserializeSTableIndexReq(void* buf, int32_t bufLen, STableIndexReq* pReq); |
7428 | | |
7429 | | typedef struct { |
7430 | | int8_t intervalUnit; |
7431 | | int8_t slidingUnit; |
7432 | | int64_t interval; |
7433 | | int64_t offset; |
7434 | | int64_t sliding; |
7435 | | int64_t dstTbUid; |
7436 | | int32_t dstVgId; |
7437 | | SEpSet epSet; |
7438 | | char* expr; |
7439 | | } STableIndexInfo; |
7440 | | |
7441 | | typedef struct { |
7442 | | char tbName[TSDB_TABLE_NAME_LEN]; |
7443 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7444 | | uint64_t suid; |
7445 | | int32_t version; |
7446 | | int32_t indexSize; |
7447 | | SArray* pIndex; // STableIndexInfo |
7448 | | } STableIndexRsp; |
7449 | | |
7450 | | int32_t tSerializeSTableIndexRsp(void* buf, int32_t bufLen, const STableIndexRsp* pRsp); |
7451 | | int32_t tDeserializeSTableIndexRsp(void* buf, int32_t bufLen, STableIndexRsp* pRsp); |
7452 | | void tFreeSerializeSTableIndexRsp(STableIndexRsp* pRsp); |
7453 | | |
7454 | | void tFreeSTableIndexInfo(void* pInfo); |
7455 | | |
7456 | | typedef struct { |
7457 | | int8_t mqMsgType; |
7458 | | int32_t code; |
7459 | | int32_t epoch; |
7460 | | int64_t consumerId; |
7461 | | int64_t walsver; |
7462 | | int64_t walever; |
7463 | | } SMqRspHead; |
7464 | | |
7465 | | typedef struct { |
7466 | | SMsgHead head; |
7467 | | char subKey[TSDB_SUBSCRIBE_KEY_LEN]; |
7468 | | int8_t withTbName; |
7469 | | int8_t useSnapshot; |
7470 | | int32_t epoch; |
7471 | | uint64_t reqId; |
7472 | | int64_t consumerId; |
7473 | | int64_t timeout; |
7474 | | STqOffsetVal reqOffset; |
7475 | | int8_t enableReplay; |
7476 | | int8_t sourceExcluded; |
7477 | | int8_t rawData; |
7478 | | int32_t minPollRows; |
7479 | | int8_t enableBatchMeta; |
7480 | | SHashObj* uidHash; // to find if uid is duplicated |
7481 | | } SMqPollReq; |
7482 | | |
7483 | | int32_t tSerializeSMqPollReq(void* buf, int32_t bufLen, SMqPollReq* pReq); |
7484 | | int32_t tDeserializeSMqPollReq(void* buf, int32_t bufLen, SMqPollReq* pReq); |
7485 | | void tDestroySMqPollReq(SMqPollReq* pReq); |
7486 | | |
7487 | | typedef struct { |
7488 | | int32_t vgId; |
7489 | | int64_t offset; |
7490 | | SEpSet epSet; |
7491 | | } SMqSubVgEp; |
7492 | | |
7493 | 0 | static FORCE_INLINE int32_t tEncodeSMqSubVgEp(void** buf, const SMqSubVgEp* pVgEp) { |
7494 | 0 | int32_t tlen = 0; |
7495 | 0 | tlen += taosEncodeFixedI32(buf, pVgEp->vgId); |
7496 | 0 | tlen += taosEncodeFixedI64(buf, pVgEp->offset); |
7497 | 0 | tlen += taosEncodeSEpSet(buf, &pVgEp->epSet); |
7498 | 0 | return tlen; |
7499 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSMqSubVgEp Unexecuted instantiation: parser.c:tEncodeSMqSubVgEp Unexecuted instantiation: parTranslater.c:tEncodeSMqSubVgEp Unexecuted instantiation: parUtil.c:tEncodeSMqSubVgEp Unexecuted instantiation: parAstParser.c:tEncodeSMqSubVgEp Unexecuted instantiation: parAuthenticator.c:tEncodeSMqSubVgEp Unexecuted instantiation: parCalcConst.c:tEncodeSMqSubVgEp Unexecuted instantiation: parInsertSql.c:tEncodeSMqSubVgEp Unexecuted instantiation: parInsertUtil.c:tEncodeSMqSubVgEp Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSMqSubVgEp Unexecuted instantiation: parAstCreater.c:tEncodeSMqSubVgEp Unexecuted instantiation: parInsertSml.c:tEncodeSMqSubVgEp Unexecuted instantiation: planner.c:tEncodeSMqSubVgEp Unexecuted instantiation: planLogicCreater.c:tEncodeSMqSubVgEp Unexecuted instantiation: planOptimizer.c:tEncodeSMqSubVgEp Unexecuted instantiation: planPhysiCreater.c:tEncodeSMqSubVgEp Unexecuted instantiation: planScaleOut.c:tEncodeSMqSubVgEp Unexecuted instantiation: planSpliter.c:tEncodeSMqSubVgEp Unexecuted instantiation: planUtil.c:tEncodeSMqSubVgEp Unexecuted instantiation: planValidator.c:tEncodeSMqSubVgEp Unexecuted instantiation: catalog.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgAsync.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgCache.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgDbg.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgRemote.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgRent.c:tEncodeSMqSubVgEp Unexecuted instantiation: ctgUtil.c:tEncodeSMqSubVgEp Unexecuted instantiation: extConnector.c:tEncodeSMqSubVgEp Unexecuted instantiation: extDialect.c:tEncodeSMqSubVgEp Unexecuted instantiation: extDialectDefaults.c:tEncodeSMqSubVgEp Unexecuted instantiation: functionMgt.c:tEncodeSMqSubVgEp Unexecuted instantiation: tudf.c:tEncodeSMqSubVgEp Unexecuted instantiation: builtins.c:tEncodeSMqSubVgEp Unexecuted instantiation: builtinsimpl.c:tEncodeSMqSubVgEp Unexecuted instantiation: spillDistinctSet.c:tEncodeSMqSubVgEp Unexecuted instantiation: thistogram.c:tEncodeSMqSubVgEp Unexecuted instantiation: tpercentile.c:tEncodeSMqSubVgEp Unexecuted instantiation: tavgfunction.c:tEncodeSMqSubVgEp Unexecuted instantiation: tminmax.c:tEncodeSMqSubVgEp Unexecuted instantiation: tminmaxavx.c:tEncodeSMqSubVgEp Unexecuted instantiation: filter.c:tEncodeSMqSubVgEp Unexecuted instantiation: scalar.c:tEncodeSMqSubVgEp Unexecuted instantiation: sclfunc.c:tEncodeSMqSubVgEp Unexecuted instantiation: sclvector.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSMqSubVgEp Unexecuted instantiation: extTypeMap.c:tEncodeSMqSubVgEp Unexecuted instantiation: queryUtil.c:tEncodeSMqSubVgEp Unexecuted instantiation: querymsg.c:tEncodeSMqSubVgEp Unexecuted instantiation: trans.c:tEncodeSMqSubVgEp Unexecuted instantiation: transCli.c:tEncodeSMqSubVgEp Unexecuted instantiation: transComm.c:tEncodeSMqSubVgEp Unexecuted instantiation: transSasl.c:tEncodeSMqSubVgEp Unexecuted instantiation: transSvr.c:tEncodeSMqSubVgEp Unexecuted instantiation: transTLS.c:tEncodeSMqSubVgEp Unexecuted instantiation: thttp.c:tEncodeSMqSubVgEp Unexecuted instantiation: geomFunc.c:tEncodeSMqSubVgEp Unexecuted instantiation: tconfig.c:tEncodeSMqSubVgEp Unexecuted instantiation: tdigest.c:tEncodeSMqSubVgEp Unexecuted instantiation: tlog.c:tEncodeSMqSubVgEp Unexecuted instantiation: tmempool.c:tEncodeSMqSubVgEp Unexecuted instantiation: tpagedbuf.c:tEncodeSMqSubVgEp Unexecuted instantiation: mpDirect.c:tEncodeSMqSubVgEp Unexecuted instantiation: extCapability.c:tEncodeSMqSubVgEp Unexecuted instantiation: systable.c:tEncodeSMqSubVgEp Unexecuted instantiation: tanalytics.c:tEncodeSMqSubVgEp Unexecuted instantiation: tdatablock.c:tEncodeSMqSubVgEp Unexecuted instantiation: tdataformat.c:tEncodeSMqSubVgEp Unexecuted instantiation: tglobal.c:tEncodeSMqSubVgEp Unexecuted instantiation: tmisce.c:tEncodeSMqSubVgEp Unexecuted instantiation: tname.c:tEncodeSMqSubVgEp Unexecuted instantiation: tpriv.c:tEncodeSMqSubVgEp Unexecuted instantiation: ttime.c:tEncodeSMqSubVgEp Unexecuted instantiation: tvariant.c:tEncodeSMqSubVgEp Unexecuted instantiation: streamMsg.c:tEncodeSMqSubVgEp Unexecuted instantiation: streamWindowPlan.c:tEncodeSMqSubVgEp Unexecuted instantiation: tmsg.c:tEncodeSMqSubVgEp Unexecuted instantiation: xnode.c:tEncodeSMqSubVgEp Unexecuted instantiation: tencrypt.c:tEncodeSMqSubVgEp Unexecuted instantiation: streamJson.c:tEncodeSMqSubVgEp Unexecuted instantiation: crypt.c:tEncodeSMqSubVgEp |
7500 | | |
7501 | 0 | static FORCE_INLINE void* tDecodeSMqSubVgEp(void* buf, SMqSubVgEp* pVgEp) { |
7502 | 0 | buf = taosDecodeFixedI32(buf, &pVgEp->vgId); |
7503 | 0 | buf = taosDecodeFixedI64(buf, &pVgEp->offset); |
7504 | 0 | buf = taosDecodeSEpSet(buf, &pVgEp->epSet); |
7505 | 0 | return buf; |
7506 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSMqSubVgEp Unexecuted instantiation: parser.c:tDecodeSMqSubVgEp Unexecuted instantiation: parTranslater.c:tDecodeSMqSubVgEp Unexecuted instantiation: parUtil.c:tDecodeSMqSubVgEp Unexecuted instantiation: parAstParser.c:tDecodeSMqSubVgEp Unexecuted instantiation: parAuthenticator.c:tDecodeSMqSubVgEp Unexecuted instantiation: parCalcConst.c:tDecodeSMqSubVgEp Unexecuted instantiation: parInsertSql.c:tDecodeSMqSubVgEp Unexecuted instantiation: parInsertUtil.c:tDecodeSMqSubVgEp Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSMqSubVgEp Unexecuted instantiation: parAstCreater.c:tDecodeSMqSubVgEp Unexecuted instantiation: parInsertSml.c:tDecodeSMqSubVgEp Unexecuted instantiation: planner.c:tDecodeSMqSubVgEp Unexecuted instantiation: planLogicCreater.c:tDecodeSMqSubVgEp Unexecuted instantiation: planOptimizer.c:tDecodeSMqSubVgEp Unexecuted instantiation: planPhysiCreater.c:tDecodeSMqSubVgEp Unexecuted instantiation: planScaleOut.c:tDecodeSMqSubVgEp Unexecuted instantiation: planSpliter.c:tDecodeSMqSubVgEp Unexecuted instantiation: planUtil.c:tDecodeSMqSubVgEp Unexecuted instantiation: planValidator.c:tDecodeSMqSubVgEp Unexecuted instantiation: catalog.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgAsync.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgCache.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgDbg.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgRemote.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgRent.c:tDecodeSMqSubVgEp Unexecuted instantiation: ctgUtil.c:tDecodeSMqSubVgEp Unexecuted instantiation: extConnector.c:tDecodeSMqSubVgEp Unexecuted instantiation: extDialect.c:tDecodeSMqSubVgEp Unexecuted instantiation: extDialectDefaults.c:tDecodeSMqSubVgEp Unexecuted instantiation: functionMgt.c:tDecodeSMqSubVgEp Unexecuted instantiation: tudf.c:tDecodeSMqSubVgEp Unexecuted instantiation: builtins.c:tDecodeSMqSubVgEp Unexecuted instantiation: builtinsimpl.c:tDecodeSMqSubVgEp Unexecuted instantiation: spillDistinctSet.c:tDecodeSMqSubVgEp Unexecuted instantiation: thistogram.c:tDecodeSMqSubVgEp Unexecuted instantiation: tpercentile.c:tDecodeSMqSubVgEp Unexecuted instantiation: tavgfunction.c:tDecodeSMqSubVgEp Unexecuted instantiation: tminmax.c:tDecodeSMqSubVgEp Unexecuted instantiation: tminmaxavx.c:tDecodeSMqSubVgEp Unexecuted instantiation: filter.c:tDecodeSMqSubVgEp Unexecuted instantiation: scalar.c:tDecodeSMqSubVgEp Unexecuted instantiation: sclfunc.c:tDecodeSMqSubVgEp Unexecuted instantiation: sclvector.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSMqSubVgEp Unexecuted instantiation: extTypeMap.c:tDecodeSMqSubVgEp Unexecuted instantiation: queryUtil.c:tDecodeSMqSubVgEp Unexecuted instantiation: querymsg.c:tDecodeSMqSubVgEp Unexecuted instantiation: trans.c:tDecodeSMqSubVgEp Unexecuted instantiation: transCli.c:tDecodeSMqSubVgEp Unexecuted instantiation: transComm.c:tDecodeSMqSubVgEp Unexecuted instantiation: transSasl.c:tDecodeSMqSubVgEp Unexecuted instantiation: transSvr.c:tDecodeSMqSubVgEp Unexecuted instantiation: transTLS.c:tDecodeSMqSubVgEp Unexecuted instantiation: thttp.c:tDecodeSMqSubVgEp Unexecuted instantiation: geomFunc.c:tDecodeSMqSubVgEp Unexecuted instantiation: tconfig.c:tDecodeSMqSubVgEp Unexecuted instantiation: tdigest.c:tDecodeSMqSubVgEp Unexecuted instantiation: tlog.c:tDecodeSMqSubVgEp Unexecuted instantiation: tmempool.c:tDecodeSMqSubVgEp Unexecuted instantiation: tpagedbuf.c:tDecodeSMqSubVgEp Unexecuted instantiation: mpDirect.c:tDecodeSMqSubVgEp Unexecuted instantiation: extCapability.c:tDecodeSMqSubVgEp Unexecuted instantiation: systable.c:tDecodeSMqSubVgEp Unexecuted instantiation: tanalytics.c:tDecodeSMqSubVgEp Unexecuted instantiation: tdatablock.c:tDecodeSMqSubVgEp Unexecuted instantiation: tdataformat.c:tDecodeSMqSubVgEp Unexecuted instantiation: tglobal.c:tDecodeSMqSubVgEp Unexecuted instantiation: tmisce.c:tDecodeSMqSubVgEp Unexecuted instantiation: tname.c:tDecodeSMqSubVgEp Unexecuted instantiation: tpriv.c:tDecodeSMqSubVgEp Unexecuted instantiation: ttime.c:tDecodeSMqSubVgEp Unexecuted instantiation: tvariant.c:tDecodeSMqSubVgEp Unexecuted instantiation: streamMsg.c:tDecodeSMqSubVgEp Unexecuted instantiation: streamWindowPlan.c:tDecodeSMqSubVgEp Unexecuted instantiation: tmsg.c:tDecodeSMqSubVgEp Unexecuted instantiation: xnode.c:tDecodeSMqSubVgEp Unexecuted instantiation: tencrypt.c:tDecodeSMqSubVgEp Unexecuted instantiation: streamJson.c:tDecodeSMqSubVgEp Unexecuted instantiation: crypt.c:tDecodeSMqSubVgEp |
7507 | | |
7508 | | typedef struct { |
7509 | | char topic[TSDB_TOPIC_FNAME_LEN]; |
7510 | | char db[TSDB_DB_FNAME_LEN]; |
7511 | | SArray* vgs; // SArray<SMqSubVgEp> |
7512 | | } SMqSubTopicEp; |
7513 | | |
7514 | | int32_t tEncodeMqSubTopicEp(void** buf, const SMqSubTopicEp* pTopicEp); |
7515 | | void* tDecodeMqSubTopicEp(void* buf, SMqSubTopicEp* pTopicEp); |
7516 | | void tDeleteMqSubTopicEp(SMqSubTopicEp* pSubTopicEp); |
7517 | | |
7518 | | typedef struct { |
7519 | | SMqRspHead head; |
7520 | | STqOffsetVal rspOffset; |
7521 | | int16_t resMsgType; |
7522 | | int32_t metaRspLen; |
7523 | | void* metaRsp; |
7524 | | } SMqMetaRsp; |
7525 | | |
7526 | | int32_t tEncodeMqMetaRsp(SEncoder* pEncoder, const SMqMetaRsp* pRsp); |
7527 | | int32_t tDecodeMqMetaRsp(SDecoder* pDecoder, SMqMetaRsp* pRsp); |
7528 | | void tDeleteMqMetaRsp(SMqMetaRsp* pRsp); |
7529 | | |
7530 | | #define MQ_DATA_RSP_VERSION 100 |
7531 | | |
7532 | | typedef struct { |
7533 | | SMqRspHead head; |
7534 | | STqOffsetVal rspOffset; |
7535 | | STqOffsetVal reqOffset; |
7536 | | int32_t blockNum; |
7537 | | int8_t withTbName; |
7538 | | int8_t withSchema; |
7539 | | SArray* blockDataLen; |
7540 | | SArray* blockData; |
7541 | | SArray* blockTbName; |
7542 | | SArray* blockSchema; |
7543 | | |
7544 | | union { |
7545 | | struct { |
7546 | | int64_t sleepTime; |
7547 | | }; |
7548 | | struct { |
7549 | | int32_t createTableNum; |
7550 | | SArray* createTableLen; |
7551 | | SArray* createTableReq; |
7552 | | }; |
7553 | | struct { |
7554 | | int32_t len; |
7555 | | void* rawData; |
7556 | | }; |
7557 | | }; |
7558 | | void* data; // for free in client, only effected if type is data or metadata. raw data not effected |
7559 | | bool blockDataElementFree; // if true, free blockDataElement in blockData,(true in server, false in client) |
7560 | | bool timeout; |
7561 | | } SMqDataRsp; |
7562 | | |
7563 | | int32_t tEncodeMqDataRsp(SEncoder* pEncoder, const SMqDataRsp* pObj); |
7564 | | int32_t tDecodeMqDataRsp(SDecoder* pDecoder, SMqDataRsp* pRsp); |
7565 | | int32_t tDecodeMqRawDataRsp(SDecoder* pDecoder, SMqDataRsp* pRsp); |
7566 | | void tDeleteMqDataRsp(SMqDataRsp* pRsp); |
7567 | | void tDeleteMqRawDataRsp(SMqDataRsp* pRsp); |
7568 | | |
7569 | | int32_t tEncodeSTaosxRsp(SEncoder* pEncoder, const SMqDataRsp* pRsp); |
7570 | | int32_t tDecodeSTaosxRsp(SDecoder* pDecoder, SMqDataRsp* pRsp); |
7571 | | void tDeleteSTaosxRsp(SMqDataRsp* pRsp); |
7572 | | |
7573 | | typedef struct SMqBatchMetaRsp { |
7574 | | SMqRspHead head; // not serialize |
7575 | | STqOffsetVal rspOffset; |
7576 | | SArray* batchMetaLen; |
7577 | | SArray* batchMetaReq; |
7578 | | void* pMetaBuff; // not serialize |
7579 | | uint32_t metaBuffLen; // not serialize |
7580 | | } SMqBatchMetaRsp; |
7581 | | |
7582 | | int32_t tEncodeMqBatchMetaRsp(SEncoder* pEncoder, const SMqBatchMetaRsp* pRsp); |
7583 | | int32_t tDecodeMqBatchMetaRsp(SDecoder* pDecoder, SMqBatchMetaRsp* pRsp); |
7584 | | int32_t tSemiDecodeMqBatchMetaRsp(SDecoder* pDecoder, SMqBatchMetaRsp* pRsp); |
7585 | | void tDeleteMqBatchMetaRsp(SMqBatchMetaRsp* pRsp); |
7586 | | |
7587 | | typedef struct { |
7588 | | int32_t code; |
7589 | | SArray* topics; // SArray<SMqSubTopicEp> |
7590 | | } SMqAskEpRsp; |
7591 | | |
7592 | 0 | static FORCE_INLINE int32_t tEncodeSMqAskEpRsp(void** buf, const SMqAskEpRsp* pRsp) { |
7593 | 0 | int32_t tlen = 0; |
7594 | 0 | // tlen += taosEncodeString(buf, pRsp->cgroup); |
7595 | 0 | int32_t sz = taosArrayGetSize(pRsp->topics); |
7596 | 0 | tlen += taosEncodeFixedI32(buf, sz); |
7597 | 0 | for (int32_t i = 0; i < sz; i++) { |
7598 | 0 | SMqSubTopicEp* pVgEp = (SMqSubTopicEp*)taosArrayGet(pRsp->topics, i); |
7599 | 0 | tlen += tEncodeMqSubTopicEp(buf, pVgEp); |
7600 | 0 | } |
7601 | 0 | tlen += taosEncodeFixedI32(buf, pRsp->code); |
7602 | 0 |
|
7603 | 0 | return tlen; |
7604 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parser.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parTranslater.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parUtil.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parAstParser.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parAuthenticator.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parCalcConst.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parInsertSql.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parInsertUtil.c:tEncodeSMqAskEpRsp Unexecuted instantiation: taos_lemon_sql.tab.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parAstCreater.c:tEncodeSMqAskEpRsp Unexecuted instantiation: parInsertSml.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planner.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planLogicCreater.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planOptimizer.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planPhysiCreater.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planScaleOut.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planSpliter.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planUtil.c:tEncodeSMqAskEpRsp Unexecuted instantiation: planValidator.c:tEncodeSMqAskEpRsp Unexecuted instantiation: catalog.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgAsync.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgCache.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgDbg.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgRemote.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgRent.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ctgUtil.c:tEncodeSMqAskEpRsp Unexecuted instantiation: extConnector.c:tEncodeSMqAskEpRsp Unexecuted instantiation: extDialect.c:tEncodeSMqAskEpRsp Unexecuted instantiation: extDialectDefaults.c:tEncodeSMqAskEpRsp Unexecuted instantiation: functionMgt.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tudf.c:tEncodeSMqAskEpRsp Unexecuted instantiation: builtins.c:tEncodeSMqAskEpRsp Unexecuted instantiation: builtinsimpl.c:tEncodeSMqAskEpRsp Unexecuted instantiation: spillDistinctSet.c:tEncodeSMqAskEpRsp Unexecuted instantiation: thistogram.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tpercentile.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tavgfunction.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tminmax.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tminmaxavx.c:tEncodeSMqAskEpRsp Unexecuted instantiation: filter.c:tEncodeSMqAskEpRsp Unexecuted instantiation: scalar.c:tEncodeSMqAskEpRsp Unexecuted instantiation: sclfunc.c:tEncodeSMqAskEpRsp Unexecuted instantiation: sclvector.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesCloneFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesCodeFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesEqualFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesMatchFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesMsgFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesRemotePlanToSQL.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesToSQLFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesTraverseFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: nodesUtilFuncs.c:tEncodeSMqAskEpRsp Unexecuted instantiation: extTypeMap.c:tEncodeSMqAskEpRsp Unexecuted instantiation: queryUtil.c:tEncodeSMqAskEpRsp Unexecuted instantiation: querymsg.c:tEncodeSMqAskEpRsp Unexecuted instantiation: trans.c:tEncodeSMqAskEpRsp Unexecuted instantiation: transCli.c:tEncodeSMqAskEpRsp Unexecuted instantiation: transComm.c:tEncodeSMqAskEpRsp Unexecuted instantiation: transSasl.c:tEncodeSMqAskEpRsp Unexecuted instantiation: transSvr.c:tEncodeSMqAskEpRsp Unexecuted instantiation: transTLS.c:tEncodeSMqAskEpRsp Unexecuted instantiation: thttp.c:tEncodeSMqAskEpRsp Unexecuted instantiation: geomFunc.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tconfig.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tdigest.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tlog.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tmempool.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tpagedbuf.c:tEncodeSMqAskEpRsp Unexecuted instantiation: mpDirect.c:tEncodeSMqAskEpRsp Unexecuted instantiation: extCapability.c:tEncodeSMqAskEpRsp Unexecuted instantiation: systable.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tanalytics.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tdatablock.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tdataformat.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tglobal.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tmisce.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tname.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tpriv.c:tEncodeSMqAskEpRsp Unexecuted instantiation: ttime.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tvariant.c:tEncodeSMqAskEpRsp Unexecuted instantiation: streamMsg.c:tEncodeSMqAskEpRsp Unexecuted instantiation: streamWindowPlan.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tmsg.c:tEncodeSMqAskEpRsp Unexecuted instantiation: xnode.c:tEncodeSMqAskEpRsp Unexecuted instantiation: tencrypt.c:tEncodeSMqAskEpRsp Unexecuted instantiation: streamJson.c:tEncodeSMqAskEpRsp Unexecuted instantiation: crypt.c:tEncodeSMqAskEpRsp |
7605 | | |
7606 | 0 | static FORCE_INLINE void* tDecodeSMqAskEpRsp(void* buf, SMqAskEpRsp* pRsp) { |
7607 | 0 | // buf = taosDecodeStringTo(buf, pRsp->cgroup); |
7608 | 0 | int32_t sz; |
7609 | 0 | buf = taosDecodeFixedI32(buf, &sz); |
7610 | 0 | pRsp->topics = taosArrayInit(sz, sizeof(SMqSubTopicEp)); |
7611 | 0 | if (pRsp->topics == NULL) { |
7612 | 0 | return NULL; |
7613 | 0 | } |
7614 | 0 | for (int32_t i = 0; i < sz; i++) { |
7615 | 0 | SMqSubTopicEp topicEp; |
7616 | 0 | buf = tDecodeMqSubTopicEp(buf, &topicEp); |
7617 | 0 | if (buf == NULL) { |
7618 | 0 | return NULL; |
7619 | 0 | } |
7620 | 0 | if ((taosArrayPush(pRsp->topics, &topicEp) == NULL)) { |
7621 | 0 | return NULL; |
7622 | 0 | } |
7623 | 0 | } |
7624 | 0 | buf = taosDecodeFixedI32(buf, &pRsp->code); |
7625 | 0 |
|
7626 | 0 | return buf; |
7627 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parser.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parTranslater.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parUtil.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parAstParser.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parAuthenticator.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parCalcConst.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parInsertSql.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parInsertUtil.c:tDecodeSMqAskEpRsp Unexecuted instantiation: taos_lemon_sql.tab.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parAstCreater.c:tDecodeSMqAskEpRsp Unexecuted instantiation: parInsertSml.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planner.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planLogicCreater.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planOptimizer.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planPhysiCreater.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planScaleOut.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planSpliter.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planUtil.c:tDecodeSMqAskEpRsp Unexecuted instantiation: planValidator.c:tDecodeSMqAskEpRsp Unexecuted instantiation: catalog.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgAsync.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgCache.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgDbg.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgRemote.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgRent.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ctgUtil.c:tDecodeSMqAskEpRsp Unexecuted instantiation: extConnector.c:tDecodeSMqAskEpRsp Unexecuted instantiation: extDialect.c:tDecodeSMqAskEpRsp Unexecuted instantiation: extDialectDefaults.c:tDecodeSMqAskEpRsp Unexecuted instantiation: functionMgt.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tudf.c:tDecodeSMqAskEpRsp Unexecuted instantiation: builtins.c:tDecodeSMqAskEpRsp Unexecuted instantiation: builtinsimpl.c:tDecodeSMqAskEpRsp Unexecuted instantiation: spillDistinctSet.c:tDecodeSMqAskEpRsp Unexecuted instantiation: thistogram.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tpercentile.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tavgfunction.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tminmax.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tminmaxavx.c:tDecodeSMqAskEpRsp Unexecuted instantiation: filter.c:tDecodeSMqAskEpRsp Unexecuted instantiation: scalar.c:tDecodeSMqAskEpRsp Unexecuted instantiation: sclfunc.c:tDecodeSMqAskEpRsp Unexecuted instantiation: sclvector.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesCloneFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesCodeFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesEqualFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesMatchFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesMsgFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesRemotePlanToSQL.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesToSQLFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesTraverseFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: nodesUtilFuncs.c:tDecodeSMqAskEpRsp Unexecuted instantiation: extTypeMap.c:tDecodeSMqAskEpRsp Unexecuted instantiation: queryUtil.c:tDecodeSMqAskEpRsp Unexecuted instantiation: querymsg.c:tDecodeSMqAskEpRsp Unexecuted instantiation: trans.c:tDecodeSMqAskEpRsp Unexecuted instantiation: transCli.c:tDecodeSMqAskEpRsp Unexecuted instantiation: transComm.c:tDecodeSMqAskEpRsp Unexecuted instantiation: transSasl.c:tDecodeSMqAskEpRsp Unexecuted instantiation: transSvr.c:tDecodeSMqAskEpRsp Unexecuted instantiation: transTLS.c:tDecodeSMqAskEpRsp Unexecuted instantiation: thttp.c:tDecodeSMqAskEpRsp Unexecuted instantiation: geomFunc.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tconfig.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tdigest.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tlog.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tmempool.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tpagedbuf.c:tDecodeSMqAskEpRsp Unexecuted instantiation: mpDirect.c:tDecodeSMqAskEpRsp Unexecuted instantiation: extCapability.c:tDecodeSMqAskEpRsp Unexecuted instantiation: systable.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tanalytics.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tdatablock.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tdataformat.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tglobal.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tmisce.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tname.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tpriv.c:tDecodeSMqAskEpRsp Unexecuted instantiation: ttime.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tvariant.c:tDecodeSMqAskEpRsp Unexecuted instantiation: streamMsg.c:tDecodeSMqAskEpRsp Unexecuted instantiation: streamWindowPlan.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tmsg.c:tDecodeSMqAskEpRsp Unexecuted instantiation: xnode.c:tDecodeSMqAskEpRsp Unexecuted instantiation: tencrypt.c:tDecodeSMqAskEpRsp Unexecuted instantiation: streamJson.c:tDecodeSMqAskEpRsp Unexecuted instantiation: crypt.c:tDecodeSMqAskEpRsp |
7628 | | |
7629 | 0 | static FORCE_INLINE void tDeleteSMqAskEpRsp(SMqAskEpRsp* pRsp) { |
7630 | 0 | taosArrayDestroyEx(pRsp->topics, (FDelete)tDeleteMqSubTopicEp); |
7631 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parser.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parTranslater.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parUtil.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parAstParser.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parAuthenticator.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parCalcConst.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parInsertSql.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parInsertUtil.c:tDeleteSMqAskEpRsp Unexecuted instantiation: taos_lemon_sql.tab.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parAstCreater.c:tDeleteSMqAskEpRsp Unexecuted instantiation: parInsertSml.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planner.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planLogicCreater.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planOptimizer.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planPhysiCreater.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planScaleOut.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planSpliter.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planUtil.c:tDeleteSMqAskEpRsp Unexecuted instantiation: planValidator.c:tDeleteSMqAskEpRsp Unexecuted instantiation: catalog.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgAsync.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgCache.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgDbg.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgRemote.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgRent.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ctgUtil.c:tDeleteSMqAskEpRsp Unexecuted instantiation: extConnector.c:tDeleteSMqAskEpRsp Unexecuted instantiation: extDialect.c:tDeleteSMqAskEpRsp Unexecuted instantiation: extDialectDefaults.c:tDeleteSMqAskEpRsp Unexecuted instantiation: functionMgt.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tudf.c:tDeleteSMqAskEpRsp Unexecuted instantiation: builtins.c:tDeleteSMqAskEpRsp Unexecuted instantiation: builtinsimpl.c:tDeleteSMqAskEpRsp Unexecuted instantiation: spillDistinctSet.c:tDeleteSMqAskEpRsp Unexecuted instantiation: thistogram.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tpercentile.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tavgfunction.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tminmax.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tminmaxavx.c:tDeleteSMqAskEpRsp Unexecuted instantiation: filter.c:tDeleteSMqAskEpRsp Unexecuted instantiation: scalar.c:tDeleteSMqAskEpRsp Unexecuted instantiation: sclfunc.c:tDeleteSMqAskEpRsp Unexecuted instantiation: sclvector.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesCloneFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesCodeFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesEqualFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesMatchFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesMsgFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesRemotePlanToSQL.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesToSQLFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesTraverseFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: nodesUtilFuncs.c:tDeleteSMqAskEpRsp Unexecuted instantiation: extTypeMap.c:tDeleteSMqAskEpRsp Unexecuted instantiation: queryUtil.c:tDeleteSMqAskEpRsp Unexecuted instantiation: querymsg.c:tDeleteSMqAskEpRsp Unexecuted instantiation: trans.c:tDeleteSMqAskEpRsp Unexecuted instantiation: transCli.c:tDeleteSMqAskEpRsp Unexecuted instantiation: transComm.c:tDeleteSMqAskEpRsp Unexecuted instantiation: transSasl.c:tDeleteSMqAskEpRsp Unexecuted instantiation: transSvr.c:tDeleteSMqAskEpRsp Unexecuted instantiation: transTLS.c:tDeleteSMqAskEpRsp Unexecuted instantiation: thttp.c:tDeleteSMqAskEpRsp Unexecuted instantiation: geomFunc.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tconfig.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tdigest.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tlog.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tmempool.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tpagedbuf.c:tDeleteSMqAskEpRsp Unexecuted instantiation: mpDirect.c:tDeleteSMqAskEpRsp Unexecuted instantiation: extCapability.c:tDeleteSMqAskEpRsp Unexecuted instantiation: systable.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tanalytics.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tdatablock.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tdataformat.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tglobal.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tmisce.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tname.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tpriv.c:tDeleteSMqAskEpRsp Unexecuted instantiation: ttime.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tvariant.c:tDeleteSMqAskEpRsp Unexecuted instantiation: streamMsg.c:tDeleteSMqAskEpRsp Unexecuted instantiation: streamWindowPlan.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tmsg.c:tDeleteSMqAskEpRsp Unexecuted instantiation: xnode.c:tDeleteSMqAskEpRsp Unexecuted instantiation: tencrypt.c:tDeleteSMqAskEpRsp Unexecuted instantiation: streamJson.c:tDeleteSMqAskEpRsp Unexecuted instantiation: crypt.c:tDeleteSMqAskEpRsp |
7632 | | |
7633 | | typedef struct { |
7634 | | int32_t vgId; |
7635 | | STqOffsetVal offset; |
7636 | | int64_t rows; |
7637 | | int64_t ever; |
7638 | | } OffsetRows; |
7639 | | |
7640 | | typedef struct { |
7641 | | char topicName[TSDB_TOPIC_FNAME_LEN]; |
7642 | | SArray* offsetRows; |
7643 | | } TopicOffsetRows; |
7644 | | |
7645 | | typedef struct { |
7646 | | int64_t consumerId; |
7647 | | int32_t epoch; |
7648 | | SArray* topics; |
7649 | | int8_t pollFlag; |
7650 | | } SMqHbReq; |
7651 | | |
7652 | | typedef struct { |
7653 | | char topic[TSDB_TOPIC_FNAME_LEN]; |
7654 | | int8_t noPrivilege; |
7655 | | } STopicPrivilege; |
7656 | | |
7657 | | typedef struct { |
7658 | | SArray* topicPrivileges; // SArray<STopicPrivilege> |
7659 | | int32_t debugFlag; |
7660 | | } SMqHbRsp; |
7661 | | |
7662 | | #define TD_AUTO_CREATE_TABLE 0x1 |
7663 | | typedef struct { |
7664 | | int64_t suid; |
7665 | | int64_t uid; |
7666 | | int32_t sver; |
7667 | | uint32_t nData; |
7668 | | uint8_t* pData; |
7669 | | SVCreateTbReq cTbReq; |
7670 | | } SVSubmitBlk; |
7671 | | |
7672 | | typedef struct { |
7673 | | SMsgHead header; |
7674 | | uint64_t sId; |
7675 | | uint64_t queryId; |
7676 | | uint64_t clientId; |
7677 | | uint64_t taskId; |
7678 | | uint32_t sqlLen; |
7679 | | uint32_t phyLen; |
7680 | | char* sql; |
7681 | | char* msg; |
7682 | | int8_t source; |
7683 | | int8_t secureDelete; |
7684 | | } SVDeleteReq; |
7685 | | |
7686 | | int32_t tSerializeSVDeleteReq(void* buf, int32_t bufLen, SVDeleteReq* pReq); |
7687 | | int32_t tDeserializeSVDeleteReq(void* buf, int32_t bufLen, SVDeleteReq* pReq); |
7688 | | |
7689 | | typedef struct { |
7690 | | int64_t affectedRows; |
7691 | | } SVDeleteRsp; |
7692 | | |
7693 | | int32_t tEncodeSVDeleteRsp(SEncoder* pCoder, const SVDeleteRsp* pReq); |
7694 | | int32_t tDecodeSVDeleteRsp(SDecoder* pCoder, SVDeleteRsp* pReq); |
7695 | | |
7696 | | // One matched point produced by a DELETE carrying an ordinary column filter, for the subtable |
7697 | | // `uid`. The deleter (dataDeleter.c) only ever emits the degenerate form skey == ekey == the |
7698 | | // matched row's ts -- it never widens [skey, ekey] into a true multi-row range, and consecutive |
7699 | | // duplicate timestamps for the same uid collapse into one entry. Do not read this as "every row |
7700 | | // inside [skey, ekey] matches the filter" for a non-degenerate range: that invariant has never |
7701 | | // been established here, and treating a wider range as safe to bulk-delete would delete rows the |
7702 | | // filter never matched. |
7703 | | typedef struct SDeleteInterval { |
7704 | | uint64_t uid; |
7705 | | int64_t skey; |
7706 | | int64_t ekey; |
7707 | | } SDeleteInterval; |
7708 | | |
7709 | | typedef struct SDeleteRes { |
7710 | | uint64_t suid; |
7711 | | SArray* uidList; |
7712 | | int64_t skey; |
7713 | | int64_t ekey; |
7714 | | int64_t affectedRows; |
7715 | | char tableFName[TSDB_TABLE_NAME_LEN]; |
7716 | | char tsColName[TSDB_COL_NAME_LEN]; |
7717 | | int64_t ctimeMs; // fill by vnode |
7718 | | int8_t source; |
7719 | | int8_t secureDelete; // force physical overwrite |
7720 | | // SArray<SDeleteInterval>. In-process scratch only, and NOT one entry per matched row: the |
7721 | | // deleter (dataDeleter.c) collapses consecutive duplicate timestamps for the same uid into a |
7722 | | // single degenerate entry, so this list can be shorter than affectedRows. It is populated by |
7723 | | // qwGetDeleteResFromSink (copied from SDeleterRes.pIntervals, which the deleter itself fills |
7724 | | // in), and read exactly once by vnodePreProcessDeleteMsg on the leader to fan the statement out |
7725 | | // into N independent old-shape SDeleteRes proposals before Raft ever sees anything. |
7726 | | // tEncodeDeleteRes/tDecodeDeleteRes never touch this field -- it must never appear on the wire, |
7727 | | // and every SDeleteRes must be zero-initialized before use so an unset pointer here is never |
7728 | | // mistaken for a live one. |
7729 | | SArray* pSplitPoints; |
7730 | | } SDeleteRes; |
7731 | | |
7732 | | int32_t tEncodeDeleteRes(SEncoder* pCoder, const SDeleteRes* pRes); |
7733 | | int32_t tDecodeDeleteRes(SDecoder* pCoder, SDeleteRes* pRes); |
7734 | | |
7735 | | typedef struct { |
7736 | | // int64_t uid; |
7737 | | char tbname[TSDB_TABLE_NAME_LEN]; |
7738 | | int64_t startTs; |
7739 | | int64_t endTs; |
7740 | | } SSingleDeleteReq; |
7741 | | |
7742 | | int32_t tEncodeSSingleDeleteReq(SEncoder* pCoder, const SSingleDeleteReq* pReq); |
7743 | | int32_t tDecodeSSingleDeleteReq(SDecoder* pCoder, SSingleDeleteReq* pReq); |
7744 | | |
7745 | | typedef struct { |
7746 | | int64_t suid; |
7747 | | SArray* deleteReqs; // SArray<SSingleDeleteReq> |
7748 | | int64_t ctimeMs; // fill by vnode |
7749 | | int8_t level; // 0 tsdb(default), 1 rsma1 , 2 rsma2 |
7750 | | } SBatchDeleteReq; |
7751 | | |
7752 | | int32_t tEncodeSBatchDeleteReq(SEncoder* pCoder, const SBatchDeleteReq* pReq); |
7753 | | int32_t tDecodeSBatchDeleteReq(SDecoder* pCoder, SBatchDeleteReq* pReq); |
7754 | | int32_t tDecodeSBatchDeleteReqSetCtime(SDecoder* pDecoder, SBatchDeleteReq* pReq, int64_t ctimeMs); |
7755 | | |
7756 | | typedef struct { |
7757 | | int32_t msgIdx; |
7758 | | int32_t msgType; |
7759 | | int32_t msgLen; |
7760 | | void* msg; |
7761 | | } SBatchMsg; |
7762 | | |
7763 | | typedef struct { |
7764 | | SMsgHead header; |
7765 | | SArray* pMsgs; // SArray<SBatchMsg> |
7766 | | } SBatchReq; |
7767 | | |
7768 | | typedef struct { |
7769 | | int32_t reqType; |
7770 | | int32_t msgIdx; |
7771 | | int32_t msgLen; |
7772 | | int32_t rspCode; |
7773 | | void* msg; |
7774 | | } SBatchRspMsg; |
7775 | | |
7776 | | typedef struct { |
7777 | | SArray* pRsps; // SArray<SBatchRspMsg> |
7778 | | } SBatchRsp; |
7779 | | |
7780 | | int32_t tSerializeSBatchReq(void* buf, int32_t bufLen, SBatchReq* pReq); |
7781 | | int32_t tDeserializeSBatchReq(void* buf, int32_t bufLen, SBatchReq* pReq); |
7782 | 0 | static FORCE_INLINE void tFreeSBatchReqMsg(void* msg) { |
7783 | 0 | if (NULL == msg) { |
7784 | 0 | return; |
7785 | 0 | } |
7786 | 0 | SBatchMsg* pMsg = (SBatchMsg*)msg; |
7787 | 0 | taosMemoryFree(pMsg->msg); |
7788 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeSBatchReqMsg Unexecuted instantiation: parser.c:tFreeSBatchReqMsg Unexecuted instantiation: parTranslater.c:tFreeSBatchReqMsg Unexecuted instantiation: parUtil.c:tFreeSBatchReqMsg Unexecuted instantiation: parAstParser.c:tFreeSBatchReqMsg Unexecuted instantiation: parAuthenticator.c:tFreeSBatchReqMsg Unexecuted instantiation: parCalcConst.c:tFreeSBatchReqMsg Unexecuted instantiation: parInsertSql.c:tFreeSBatchReqMsg Unexecuted instantiation: parInsertUtil.c:tFreeSBatchReqMsg Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeSBatchReqMsg Unexecuted instantiation: parAstCreater.c:tFreeSBatchReqMsg Unexecuted instantiation: parInsertSml.c:tFreeSBatchReqMsg Unexecuted instantiation: planner.c:tFreeSBatchReqMsg Unexecuted instantiation: planLogicCreater.c:tFreeSBatchReqMsg Unexecuted instantiation: planOptimizer.c:tFreeSBatchReqMsg Unexecuted instantiation: planPhysiCreater.c:tFreeSBatchReqMsg Unexecuted instantiation: planScaleOut.c:tFreeSBatchReqMsg Unexecuted instantiation: planSpliter.c:tFreeSBatchReqMsg Unexecuted instantiation: planUtil.c:tFreeSBatchReqMsg Unexecuted instantiation: planValidator.c:tFreeSBatchReqMsg Unexecuted instantiation: catalog.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgAsync.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgCache.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgDbg.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgRemote.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgRent.c:tFreeSBatchReqMsg Unexecuted instantiation: ctgUtil.c:tFreeSBatchReqMsg Unexecuted instantiation: extConnector.c:tFreeSBatchReqMsg Unexecuted instantiation: extDialect.c:tFreeSBatchReqMsg Unexecuted instantiation: extDialectDefaults.c:tFreeSBatchReqMsg Unexecuted instantiation: functionMgt.c:tFreeSBatchReqMsg Unexecuted instantiation: tudf.c:tFreeSBatchReqMsg Unexecuted instantiation: builtins.c:tFreeSBatchReqMsg Unexecuted instantiation: builtinsimpl.c:tFreeSBatchReqMsg Unexecuted instantiation: spillDistinctSet.c:tFreeSBatchReqMsg Unexecuted instantiation: thistogram.c:tFreeSBatchReqMsg Unexecuted instantiation: tpercentile.c:tFreeSBatchReqMsg Unexecuted instantiation: tavgfunction.c:tFreeSBatchReqMsg Unexecuted instantiation: tminmax.c:tFreeSBatchReqMsg Unexecuted instantiation: tminmaxavx.c:tFreeSBatchReqMsg Unexecuted instantiation: filter.c:tFreeSBatchReqMsg Unexecuted instantiation: scalar.c:tFreeSBatchReqMsg Unexecuted instantiation: sclfunc.c:tFreeSBatchReqMsg Unexecuted instantiation: sclvector.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesCloneFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesCodeFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesEqualFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesMatchFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesMsgFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesToSQLFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesTraverseFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: nodesUtilFuncs.c:tFreeSBatchReqMsg Unexecuted instantiation: extTypeMap.c:tFreeSBatchReqMsg Unexecuted instantiation: queryUtil.c:tFreeSBatchReqMsg Unexecuted instantiation: querymsg.c:tFreeSBatchReqMsg Unexecuted instantiation: trans.c:tFreeSBatchReqMsg Unexecuted instantiation: transCli.c:tFreeSBatchReqMsg Unexecuted instantiation: transComm.c:tFreeSBatchReqMsg Unexecuted instantiation: transSasl.c:tFreeSBatchReqMsg Unexecuted instantiation: transSvr.c:tFreeSBatchReqMsg Unexecuted instantiation: transTLS.c:tFreeSBatchReqMsg Unexecuted instantiation: thttp.c:tFreeSBatchReqMsg Unexecuted instantiation: geomFunc.c:tFreeSBatchReqMsg Unexecuted instantiation: tconfig.c:tFreeSBatchReqMsg Unexecuted instantiation: tdigest.c:tFreeSBatchReqMsg Unexecuted instantiation: tlog.c:tFreeSBatchReqMsg Unexecuted instantiation: tmempool.c:tFreeSBatchReqMsg Unexecuted instantiation: tpagedbuf.c:tFreeSBatchReqMsg Unexecuted instantiation: mpDirect.c:tFreeSBatchReqMsg Unexecuted instantiation: extCapability.c:tFreeSBatchReqMsg Unexecuted instantiation: systable.c:tFreeSBatchReqMsg Unexecuted instantiation: tanalytics.c:tFreeSBatchReqMsg Unexecuted instantiation: tdatablock.c:tFreeSBatchReqMsg Unexecuted instantiation: tdataformat.c:tFreeSBatchReqMsg Unexecuted instantiation: tglobal.c:tFreeSBatchReqMsg Unexecuted instantiation: tmisce.c:tFreeSBatchReqMsg Unexecuted instantiation: tname.c:tFreeSBatchReqMsg Unexecuted instantiation: tpriv.c:tFreeSBatchReqMsg Unexecuted instantiation: ttime.c:tFreeSBatchReqMsg Unexecuted instantiation: tvariant.c:tFreeSBatchReqMsg Unexecuted instantiation: streamMsg.c:tFreeSBatchReqMsg Unexecuted instantiation: streamWindowPlan.c:tFreeSBatchReqMsg Unexecuted instantiation: tmsg.c:tFreeSBatchReqMsg Unexecuted instantiation: xnode.c:tFreeSBatchReqMsg Unexecuted instantiation: tencrypt.c:tFreeSBatchReqMsg Unexecuted instantiation: streamJson.c:tFreeSBatchReqMsg Unexecuted instantiation: crypt.c:tFreeSBatchReqMsg |
7789 | | |
7790 | | int32_t tSerializeSBatchRsp(void* buf, int32_t bufLen, SBatchRsp* pRsp); |
7791 | | int32_t tDeserializeSBatchRsp(void* buf, int32_t bufLen, SBatchRsp* pRsp); |
7792 | | |
7793 | 0 | static FORCE_INLINE void tFreeSBatchRspMsg(void* p) { |
7794 | 0 | if (NULL == p) { |
7795 | 0 | return; |
7796 | 0 | } |
7797 | | |
7798 | 0 | SBatchRspMsg* pRsp = (SBatchRspMsg*)p; |
7799 | 0 | taosMemoryFree(pRsp->msg); |
7800 | 0 | } Unexecuted instantiation: sql-fuzzer.c:tFreeSBatchRspMsg Unexecuted instantiation: parser.c:tFreeSBatchRspMsg Unexecuted instantiation: parTranslater.c:tFreeSBatchRspMsg Unexecuted instantiation: parUtil.c:tFreeSBatchRspMsg Unexecuted instantiation: parAstParser.c:tFreeSBatchRspMsg Unexecuted instantiation: parAuthenticator.c:tFreeSBatchRspMsg Unexecuted instantiation: parCalcConst.c:tFreeSBatchRspMsg Unexecuted instantiation: parInsertSql.c:tFreeSBatchRspMsg Unexecuted instantiation: parInsertUtil.c:tFreeSBatchRspMsg Unexecuted instantiation: taos_lemon_sql.tab.c:tFreeSBatchRspMsg Unexecuted instantiation: parAstCreater.c:tFreeSBatchRspMsg Unexecuted instantiation: parInsertSml.c:tFreeSBatchRspMsg Unexecuted instantiation: planner.c:tFreeSBatchRspMsg Unexecuted instantiation: planLogicCreater.c:tFreeSBatchRspMsg Unexecuted instantiation: planOptimizer.c:tFreeSBatchRspMsg Unexecuted instantiation: planPhysiCreater.c:tFreeSBatchRspMsg Unexecuted instantiation: planScaleOut.c:tFreeSBatchRspMsg Unexecuted instantiation: planSpliter.c:tFreeSBatchRspMsg Unexecuted instantiation: planUtil.c:tFreeSBatchRspMsg Unexecuted instantiation: planValidator.c:tFreeSBatchRspMsg Unexecuted instantiation: catalog.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgAsync.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgCache.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgDbg.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgRemote.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgRent.c:tFreeSBatchRspMsg Unexecuted instantiation: ctgUtil.c:tFreeSBatchRspMsg Unexecuted instantiation: extConnector.c:tFreeSBatchRspMsg Unexecuted instantiation: extDialect.c:tFreeSBatchRspMsg Unexecuted instantiation: extDialectDefaults.c:tFreeSBatchRspMsg Unexecuted instantiation: functionMgt.c:tFreeSBatchRspMsg Unexecuted instantiation: tudf.c:tFreeSBatchRspMsg Unexecuted instantiation: builtins.c:tFreeSBatchRspMsg Unexecuted instantiation: builtinsimpl.c:tFreeSBatchRspMsg Unexecuted instantiation: spillDistinctSet.c:tFreeSBatchRspMsg Unexecuted instantiation: thistogram.c:tFreeSBatchRspMsg Unexecuted instantiation: tpercentile.c:tFreeSBatchRspMsg Unexecuted instantiation: tavgfunction.c:tFreeSBatchRspMsg Unexecuted instantiation: tminmax.c:tFreeSBatchRspMsg Unexecuted instantiation: tminmaxavx.c:tFreeSBatchRspMsg Unexecuted instantiation: filter.c:tFreeSBatchRspMsg Unexecuted instantiation: scalar.c:tFreeSBatchRspMsg Unexecuted instantiation: sclfunc.c:tFreeSBatchRspMsg Unexecuted instantiation: sclvector.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesCloneFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesCodeFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesEqualFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesMatchFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesMsgFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesRemotePlanToSQL.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesToSQLFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesTraverseFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: nodesUtilFuncs.c:tFreeSBatchRspMsg Unexecuted instantiation: extTypeMap.c:tFreeSBatchRspMsg Unexecuted instantiation: queryUtil.c:tFreeSBatchRspMsg Unexecuted instantiation: querymsg.c:tFreeSBatchRspMsg Unexecuted instantiation: trans.c:tFreeSBatchRspMsg Unexecuted instantiation: transCli.c:tFreeSBatchRspMsg Unexecuted instantiation: transComm.c:tFreeSBatchRspMsg Unexecuted instantiation: transSasl.c:tFreeSBatchRspMsg Unexecuted instantiation: transSvr.c:tFreeSBatchRspMsg Unexecuted instantiation: transTLS.c:tFreeSBatchRspMsg Unexecuted instantiation: thttp.c:tFreeSBatchRspMsg Unexecuted instantiation: geomFunc.c:tFreeSBatchRspMsg Unexecuted instantiation: tconfig.c:tFreeSBatchRspMsg Unexecuted instantiation: tdigest.c:tFreeSBatchRspMsg Unexecuted instantiation: tlog.c:tFreeSBatchRspMsg Unexecuted instantiation: tmempool.c:tFreeSBatchRspMsg Unexecuted instantiation: tpagedbuf.c:tFreeSBatchRspMsg Unexecuted instantiation: mpDirect.c:tFreeSBatchRspMsg Unexecuted instantiation: extCapability.c:tFreeSBatchRspMsg Unexecuted instantiation: systable.c:tFreeSBatchRspMsg Unexecuted instantiation: tanalytics.c:tFreeSBatchRspMsg Unexecuted instantiation: tdatablock.c:tFreeSBatchRspMsg Unexecuted instantiation: tdataformat.c:tFreeSBatchRspMsg Unexecuted instantiation: tglobal.c:tFreeSBatchRspMsg Unexecuted instantiation: tmisce.c:tFreeSBatchRspMsg Unexecuted instantiation: tname.c:tFreeSBatchRspMsg Unexecuted instantiation: tpriv.c:tFreeSBatchRspMsg Unexecuted instantiation: ttime.c:tFreeSBatchRspMsg Unexecuted instantiation: tvariant.c:tFreeSBatchRspMsg Unexecuted instantiation: streamMsg.c:tFreeSBatchRspMsg Unexecuted instantiation: streamWindowPlan.c:tFreeSBatchRspMsg Unexecuted instantiation: tmsg.c:tFreeSBatchRspMsg Unexecuted instantiation: xnode.c:tFreeSBatchRspMsg Unexecuted instantiation: tencrypt.c:tFreeSBatchRspMsg Unexecuted instantiation: streamJson.c:tFreeSBatchRspMsg Unexecuted instantiation: crypt.c:tFreeSBatchRspMsg |
7801 | | |
7802 | | int32_t tSerializeSMqAskEpReq(void* buf, int32_t bufLen, SMqAskEpReq* pReq); |
7803 | | int32_t tDeserializeSMqAskEpReq(void* buf, int32_t bufLen, SMqAskEpReq* pReq); |
7804 | | int32_t tSerializeSMqHbReq(void* buf, int32_t bufLen, SMqHbReq* pReq); |
7805 | | int32_t tDeserializeSMqHbReq(void* buf, int32_t bufLen, SMqHbReq* pReq); |
7806 | | void tDestroySMqHbReq(SMqHbReq* pReq); |
7807 | | |
7808 | | int32_t tSerializeSMqHbRsp(void* buf, int32_t bufLen, SMqHbRsp* pRsp); |
7809 | | int32_t tDeserializeSMqHbRsp(void* buf, int32_t bufLen, SMqHbRsp* pRsp); |
7810 | | void tDestroySMqHbRsp(SMqHbRsp* pRsp); |
7811 | | |
7812 | 0 | #define TD_REQ_FROM_APP 0x0 |
7813 | 0 | #define SUBMIT_REQ_AUTO_CREATE_TABLE 0x1 |
7814 | 0 | #define SUBMIT_REQ_COLUMN_DATA_FORMAT 0x2 |
7815 | 0 | #define SUBMIT_REQ_FROM_FILE 0x4 |
7816 | 0 | #define TD_REQ_FROM_TAOX 0x8 |
7817 | | #define TD_REQ_FROM_SML 0x10 |
7818 | 0 | #define SUBMIT_REQUEST_VERSION (2) |
7819 | 0 | #define SUBMIT_REQ_WITH_BLOB 0x10 |
7820 | | #define SUBMIT_REQ_SCHEMA_RES 0x20 |
7821 | | #define SUBMIT_REQ_ONLY_CREATE_TABLE 0x40 |
7822 | | |
7823 | | #define TD_REQ_FROM_TAOX_OLD 0x1 // for compatibility |
7824 | | |
7825 | | typedef struct { |
7826 | | int32_t flags; |
7827 | | SVCreateTbReq* pCreateTbReq; |
7828 | | int64_t suid; |
7829 | | int64_t uid; |
7830 | | int32_t sver; |
7831 | | union { |
7832 | | SArray* aRowP; |
7833 | | SArray* aCol; |
7834 | | }; |
7835 | | int64_t ctimeMs; |
7836 | | SBlobSet* pBlobSet; |
7837 | | } SSubmitTbData; |
7838 | | |
7839 | | typedef struct { |
7840 | | SArray* aSubmitTbData; // SArray<SSubmitTbData> |
7841 | | SArray* aSubmitBlobData; |
7842 | | bool raw; |
7843 | | } SSubmitReq2; |
7844 | | |
7845 | | typedef struct { |
7846 | | SMsgHead header; |
7847 | | int64_t version; |
7848 | | char data[]; // SSubmitReq2 |
7849 | | } SSubmitReq2Msg; |
7850 | | |
7851 | | int32_t transformRawSSubmitTbData(void* data, int64_t suid, int64_t uid, int32_t sver); |
7852 | | int32_t tEncodeSubmitReq(SEncoder* pCoder, const SSubmitReq2* pReq); |
7853 | | int32_t tDecodeSubmitReq(SDecoder* pCoder, SSubmitReq2* pReq, SArray* rawList); |
7854 | | void tDestroySubmitTbData(SSubmitTbData* pTbData, int32_t flag); |
7855 | | void tDestroySubmitReq(SSubmitReq2* pReq, int32_t flag); |
7856 | | |
7857 | | typedef struct { |
7858 | | int32_t affectedRows; |
7859 | | SArray* aCreateTbRsp; // SArray<SVCreateTbRsp> |
7860 | | } SSubmitRsp2; |
7861 | | |
7862 | | int32_t tEncodeSSubmitRsp2(SEncoder* pCoder, const SSubmitRsp2* pRsp); |
7863 | | int32_t tDecodeSSubmitRsp2(SDecoder* pCoder, SSubmitRsp2* pRsp); |
7864 | | void tDestroySSubmitRsp2(SSubmitRsp2* pRsp, int32_t flag); |
7865 | | |
7866 | 0 | #define TSDB_MSG_FLG_ENCODE 0x1 |
7867 | 0 | #define TSDB_MSG_FLG_DECODE 0x2 |
7868 | 0 | #define TSDB_MSG_FLG_CMPT 0x3 |
7869 | | |
7870 | | typedef struct { |
7871 | | union { |
7872 | | struct { |
7873 | | void* msgStr; |
7874 | | int32_t msgLen; |
7875 | | int64_t ver; |
7876 | | }; |
7877 | | void* pDataBlock; |
7878 | | }; |
7879 | | } SPackedData; |
7880 | | |
7881 | | typedef struct { |
7882 | | char fullname[TSDB_VIEW_FNAME_LEN]; |
7883 | | char name[TSDB_VIEW_NAME_LEN]; |
7884 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7885 | | char* querySql; |
7886 | | char* sql; |
7887 | | int8_t orReplace; |
7888 | | int8_t precision; |
7889 | | int32_t numOfCols; |
7890 | | SSchema* pSchema; |
7891 | | } SCMCreateViewReq; |
7892 | | |
7893 | | int32_t tSerializeSCMCreateViewReq(void* buf, int32_t bufLen, const SCMCreateViewReq* pReq); |
7894 | | int32_t tDeserializeSCMCreateViewReq(void* buf, int32_t bufLen, SCMCreateViewReq* pReq); |
7895 | | void tFreeSCMCreateViewReq(SCMCreateViewReq* pReq); |
7896 | | |
7897 | | typedef struct { |
7898 | | char fullname[TSDB_VIEW_FNAME_LEN]; |
7899 | | char name[TSDB_VIEW_NAME_LEN]; |
7900 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7901 | | char* sql; |
7902 | | int8_t igNotExists; |
7903 | | } SCMDropViewReq; |
7904 | | |
7905 | | int32_t tSerializeSCMDropViewReq(void* buf, int32_t bufLen, const SCMDropViewReq* pReq); |
7906 | | int32_t tDeserializeSCMDropViewReq(void* buf, int32_t bufLen, SCMDropViewReq* pReq); |
7907 | | void tFreeSCMDropViewReq(SCMDropViewReq* pReq); |
7908 | | |
7909 | | typedef struct { |
7910 | | char fullname[TSDB_VIEW_FNAME_LEN]; |
7911 | | } SViewMetaReq; |
7912 | | int32_t tSerializeSViewMetaReq(void* buf, int32_t bufLen, const SViewMetaReq* pReq); |
7913 | | int32_t tDeserializeSViewMetaReq(void* buf, int32_t bufLen, SViewMetaReq* pReq); |
7914 | | |
7915 | | typedef struct { |
7916 | | char name[TSDB_VIEW_NAME_LEN]; |
7917 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7918 | | char* createUser; |
7919 | | int64_t ownerId; |
7920 | | uint64_t dbId; |
7921 | | uint64_t viewId; |
7922 | | char* querySql; |
7923 | | int8_t precision; |
7924 | | int8_t type; |
7925 | | int32_t version; |
7926 | | int32_t numOfCols; |
7927 | | SSchema* pSchema; |
7928 | | } SViewMetaRsp; |
7929 | | int32_t tSerializeSViewMetaRsp(void* buf, int32_t bufLen, const SViewMetaRsp* pRsp); |
7930 | | int32_t tDeserializeSViewMetaRsp(void* buf, int32_t bufLen, SViewMetaRsp* pRsp); |
7931 | | void tFreeSViewMetaRsp(SViewMetaRsp* pRsp); |
7932 | | typedef struct { |
7933 | | char name[TSDB_TABLE_FNAME_LEN]; // table name or tsma name |
7934 | | bool fetchingWithTsmaName; // if we are fetching with tsma name |
7935 | | } STableTSMAInfoReq; |
7936 | | |
7937 | | int32_t tSerializeTableTSMAInfoReq(void* buf, int32_t bufLen, const STableTSMAInfoReq* pReq); |
7938 | | int32_t tDeserializeTableTSMAInfoReq(void* buf, int32_t bufLen, STableTSMAInfoReq* pReq); |
7939 | | |
7940 | | typedef struct { |
7941 | | char name[TSDB_TABLE_NAME_LEN]; // rsmaName |
7942 | | union { |
7943 | | uint8_t flags; |
7944 | | struct { |
7945 | | uint8_t withColName : 1; |
7946 | | uint8_t reserved : 7; |
7947 | | }; |
7948 | | }; |
7949 | | |
7950 | | } SRsmaInfoReq; |
7951 | | |
7952 | | int32_t tSerializeRsmaInfoReq(void* buf, int32_t bufLen, const SRsmaInfoReq* pReq); |
7953 | | int32_t tDeserializeRsmaInfoReq(void* buf, int32_t bufLen, SRsmaInfoReq* pReq); |
7954 | | |
7955 | | typedef struct { |
7956 | | int32_t funcId; |
7957 | | col_id_t colId; |
7958 | | } STableTSMAFuncInfo; |
7959 | | |
7960 | | typedef struct { |
7961 | | char name[TSDB_TABLE_NAME_LEN]; |
7962 | | uint64_t tsmaId; |
7963 | | char targetTb[TSDB_TABLE_NAME_LEN]; |
7964 | | char targetDbFName[TSDB_DB_FNAME_LEN]; |
7965 | | char tb[TSDB_TABLE_NAME_LEN]; |
7966 | | char dbFName[TSDB_DB_FNAME_LEN]; |
7967 | | uint64_t suid; |
7968 | | uint64_t destTbUid; |
7969 | | uint64_t dbId; |
7970 | | int32_t version; |
7971 | | int64_t interval; |
7972 | | int8_t unit; |
7973 | | SArray* pFuncs; // SArray<STableTSMAFuncInfo> |
7974 | | SArray* pTags; // SArray<SSchema> |
7975 | | SArray* pUsedCols; // SArray<SSchema> |
7976 | | char* ast; |
7977 | | |
7978 | | int64_t streamUid; |
7979 | | int64_t reqTs; |
7980 | | int64_t rspTs; |
7981 | | int64_t delayDuration; // ms |
7982 | | bool fillHistoryFinished; |
7983 | | |
7984 | | void* streamAddr; // for stream task, the address of the stream task |
7985 | | } STableTSMAInfo; |
7986 | | |
7987 | | int32_t tSerializeTableTSMAInfoRsp(void* buf, int32_t bufLen, const STableTSMAInfoRsp* pRsp); |
7988 | | int32_t tDeserializeTableTSMAInfoRsp(void* buf, int32_t bufLen, STableTSMAInfoRsp* pRsp); |
7989 | | int32_t tCloneTbTSMAInfo(STableTSMAInfo* pInfo, STableTSMAInfo** pRes); |
7990 | | void tFreeTableTSMAInfo(void* p); |
7991 | | void tFreeAndClearTableTSMAInfo(void* p); |
7992 | | void tFreeTableTSMAInfoRsp(STableTSMAInfoRsp* pRsp); |
7993 | | |
7994 | | #define STSMAHbRsp STableTSMAInfoRsp |
7995 | | #define tSerializeTSMAHbRsp tSerializeTableTSMAInfoRsp |
7996 | | #define tDeserializeTSMAHbRsp tDeserializeTableTSMAInfoRsp |
7997 | | #define tFreeTSMAHbRsp tFreeTableTSMAInfoRsp |
7998 | | |
7999 | | typedef struct SDropCtbWithTsmaSingleVgReq { |
8000 | | SVgroupInfo vgInfo; |
8001 | | SArray* pTbs; // SVDropTbReq |
8002 | | } SMDropTbReqsOnSingleVg; |
8003 | | |
8004 | | int32_t tEncodeSMDropTbReqOnSingleVg(SEncoder* pEncoder, const SMDropTbReqsOnSingleVg* pReq); |
8005 | | int32_t tDecodeSMDropTbReqOnSingleVg(SDecoder* pDecoder, SMDropTbReqsOnSingleVg* pReq); |
8006 | | void tFreeSMDropTbReqOnSingleVg(void* p); |
8007 | | |
8008 | | typedef struct SDropTbsReq { |
8009 | | SArray* pVgReqs; // SMDropTbReqsOnSingleVg |
8010 | | } SMDropTbsReq; |
8011 | | |
8012 | | int32_t tSerializeSMDropTbsReq(void* buf, int32_t bufLen, const SMDropTbsReq* pReq); |
8013 | | int32_t tDeserializeSMDropTbsReq(void* buf, int32_t bufLen, SMDropTbsReq* pReq); |
8014 | | void tFreeSMDropTbsReq(void*); |
8015 | | |
8016 | | typedef struct SVFetchTtlExpiredTbsRsp { |
8017 | | SArray* pExpiredTbs; // SVDropTbReq |
8018 | | int32_t vgId; |
8019 | | } SVFetchTtlExpiredTbsRsp; |
8020 | | |
8021 | | int32_t tEncodeVFetchTtlExpiredTbsRsp(SEncoder* pCoder, const SVFetchTtlExpiredTbsRsp* pRsp); |
8022 | | int32_t tDecodeVFetchTtlExpiredTbsRsp(SDecoder* pCoder, SVFetchTtlExpiredTbsRsp* pRsp); |
8023 | | |
8024 | | void tFreeFetchTtlExpiredTbsRsp(void* p); |
8025 | | |
8026 | | void setDefaultOptionsForField(SFieldWithOptions* field); |
8027 | | void setFieldWithOptions(SFieldWithOptions* fieldWithOptions, SField* field); |
8028 | | |
8029 | | int32_t tSerializeSVSubTablesRspImpl(SEncoder* pEncoder, SVSubTablesRsp* pRsp); |
8030 | | int32_t tDeserializeSVSubTablesRspImpl(SDecoder* pDecoder, SVSubTablesRsp* pRsp); |
8031 | | |
8032 | | typedef struct { |
8033 | | char id[TSDB_INSTANCE_ID_LEN]; |
8034 | | char type[TSDB_INSTANCE_TYPE_LEN]; |
8035 | | char desc[TSDB_INSTANCE_DESC_LEN]; |
8036 | | int32_t expire; |
8037 | | } SInstanceRegisterReq; |
8038 | | |
8039 | | int32_t tSerializeSInstanceRegisterReq(void* buf, int32_t bufLen, SInstanceRegisterReq* pReq); |
8040 | | int32_t tDeserializeSInstanceRegisterReq(void* buf, int32_t bufLen, SInstanceRegisterReq* pReq); |
8041 | | |
8042 | | typedef struct { |
8043 | | char filter_type[TSDB_INSTANCE_TYPE_LEN]; |
8044 | | } SInstanceListReq; |
8045 | | |
8046 | | typedef struct { |
8047 | | int32_t count; |
8048 | | char** ids; // Array of instance IDs |
8049 | | } SInstanceListRsp; |
8050 | | |
8051 | | int32_t tSerializeSInstanceListReq(void* buf, int32_t bufLen, SInstanceListReq* pReq); |
8052 | | int32_t tDeserializeSInstanceListReq(void* buf, int32_t bufLen, SInstanceListReq* pReq); |
8053 | | int32_t tSerializeSInstanceListRsp(void* buf, int32_t bufLen, SInstanceListRsp* pRsp); |
8054 | | int32_t tDeserializeSInstanceListRsp(void* buf, int32_t bufLen, SInstanceListRsp* pRsp); |
8055 | | |
8056 | | #ifdef USE_MOUNT |
8057 | | typedef struct { |
8058 | | char mountName[TSDB_MOUNT_NAME_LEN]; |
8059 | | int8_t ignoreExist; |
8060 | | int16_t nMounts; |
8061 | | int32_t* dnodeIds; |
8062 | | char** mountPaths; |
8063 | | int32_t sqlLen; |
8064 | | char* sql; |
8065 | | } SCreateMountReq; |
8066 | | |
8067 | | int32_t tSerializeSCreateMountReq(void* buf, int32_t bufLen, SCreateMountReq* pReq); |
8068 | | int32_t tDeserializeSCreateMountReq(void* buf, int32_t bufLen, SCreateMountReq* pReq); |
8069 | | void tFreeSCreateMountReq(SCreateMountReq* pReq); |
8070 | | |
8071 | | typedef struct { |
8072 | | char mountName[TSDB_MOUNT_NAME_LEN]; |
8073 | | int8_t ignoreNotExists; |
8074 | | int32_t sqlLen; |
8075 | | char* sql; |
8076 | | } SDropMountReq; |
8077 | | |
8078 | | int32_t tSerializeSDropMountReq(void* buf, int32_t bufLen, SDropMountReq* pReq); |
8079 | | int32_t tDeserializeSDropMountReq(void* buf, int32_t bufLen, SDropMountReq* pReq); |
8080 | | void tFreeSDropMountReq(SDropMountReq* pReq); |
8081 | | |
8082 | | typedef struct { |
8083 | | char mountName[TSDB_MOUNT_NAME_LEN]; |
8084 | | char mountPath[TSDB_MOUNT_PATH_LEN]; |
8085 | | int64_t mountUid; |
8086 | | int32_t dnodeId; |
8087 | | uint32_t valLen; |
8088 | | int8_t ignoreExist; |
8089 | | void* pVal; |
8090 | | } SRetrieveMountPathReq; |
8091 | | |
8092 | | int32_t tSerializeSRetrieveMountPathReq(void* buf, int32_t bufLen, SRetrieveMountPathReq* pReq); |
8093 | | int32_t tDeserializeSRetrieveMountPathReq(void* buf, int32_t bufLen, SRetrieveMountPathReq* pReq); |
8094 | | |
8095 | | typedef struct { |
8096 | | // path |
8097 | | int32_t diskPrimary; |
8098 | | // vgInfo |
8099 | | int32_t vgId; |
8100 | | int32_t cacheLastSize; |
8101 | | int32_t szPage; |
8102 | | int32_t szCache; |
8103 | | uint64_t szBuf; |
8104 | | int8_t cacheLast; |
8105 | | int8_t standby; |
8106 | | int8_t hashMethod; |
8107 | | uint32_t hashBegin; |
8108 | | uint32_t hashEnd; |
8109 | | int16_t hashPrefix; |
8110 | | int16_t hashSuffix; |
8111 | | int16_t sttTrigger; |
8112 | | // syncInfo |
8113 | | int32_t replications; |
8114 | | // tsdbInfo |
8115 | | int8_t precision; |
8116 | | int8_t compression; |
8117 | | int8_t slLevel; |
8118 | | int32_t daysPerFile; |
8119 | | int32_t keep0; |
8120 | | int32_t keep1; |
8121 | | int32_t keep2; |
8122 | | int32_t keepTimeOffset; |
8123 | | int32_t minRows; |
8124 | | int32_t maxRows; |
8125 | | int32_t tsdbPageSize; |
8126 | | int32_t ssChunkSize; |
8127 | | int32_t ssKeepLocal; |
8128 | | int8_t ssCompact; |
8129 | | union { |
8130 | | uint8_t flags; |
8131 | | struct { |
8132 | | uint8_t isAudit : 1; |
8133 | | uint8_t allowDrop : 1; |
8134 | | uint8_t securityLevel : 3; |
8135 | | uint8_t reserved : 3; |
8136 | | }; |
8137 | | }; |
8138 | | int8_t secureDelete; |
8139 | | // walInfo |
8140 | | int32_t walFsyncPeriod; // millisecond |
8141 | | int32_t walRetentionPeriod; // secs |
8142 | | int32_t walRollPeriod; // secs |
8143 | | int64_t walRetentionSize; |
8144 | | int64_t walSegSize; |
8145 | | int32_t walLevel; |
8146 | | // encryptInfo |
8147 | | int32_t encryptAlgorithm; |
8148 | | // SVState |
8149 | | int64_t committed; |
8150 | | int64_t commitID; |
8151 | | int64_t commitTerm; |
8152 | | // stats |
8153 | | int64_t numOfSTables; |
8154 | | int64_t numOfCTables; |
8155 | | int64_t numOfNTables; |
8156 | | // dbInfo |
8157 | | uint64_t dbId; |
8158 | | } SMountVgInfo; |
8159 | | |
8160 | | typedef struct { |
8161 | | SMCreateStbReq req; |
8162 | | SArray* pColExts; // element: column id |
8163 | | SArray* pTagExts; // element: tag id |
8164 | | } SMountStbInfo; |
8165 | | |
8166 | | int32_t tSerializeSMountStbInfo(void* buf, int32_t bufLen, int32_t* pFLen, SMountStbInfo* pInfo); |
8167 | | int32_t tDeserializeSMountStbInfo(void* buf, int32_t bufLen, int32_t flen, SMountStbInfo* pInfo); |
8168 | | |
8169 | | typedef struct { |
8170 | | char dbName[TSDB_DB_FNAME_LEN]; |
8171 | | uint64_t dbId; |
8172 | | SArray* pVgs; // SMountVgInfo |
8173 | | SArray* pStbs; // 0 serialized binary of SMountStbInfo, 1 SMountStbInfo |
8174 | | } SMountDbInfo; |
8175 | | |
8176 | | typedef struct { |
8177 | | // common fields |
8178 | | char mountName[TSDB_MOUNT_NAME_LEN]; |
8179 | | char mountPath[TSDB_MOUNT_PATH_LEN]; |
8180 | | int8_t ignoreExist; |
8181 | | int64_t mountUid; |
8182 | | int64_t clusterId; |
8183 | | int32_t dnodeId; |
8184 | | uint32_t valLen; |
8185 | | void* pVal; |
8186 | | |
8187 | | // response fields |
8188 | | SArray* pDbs; // SMountDbInfo |
8189 | | |
8190 | | // memory fields, no serialized |
8191 | | SArray* pDisks[TFS_MAX_TIERS]; |
8192 | | TdFilePtr pFile; |
8193 | | } SMountInfo; |
8194 | | |
8195 | | int32_t tSerializeSMountInfo(void* buf, int32_t bufLen, SMountInfo* pReq); |
8196 | | int32_t tDeserializeSMountInfo(SDecoder* decoder, SMountInfo* pReq, bool extractStb); |
8197 | | void tFreeMountInfo(SMountInfo* pReq, bool stbExtracted); |
8198 | | |
8199 | | typedef struct { |
8200 | | SCreateVnodeReq createReq; |
8201 | | char mountPath[TSDB_MOUNT_FPATH_LEN]; |
8202 | | char mountName[TSDB_MOUNT_NAME_LEN]; |
8203 | | int64_t mountId; |
8204 | | int32_t diskPrimary; |
8205 | | int32_t mountVgId; |
8206 | | int64_t committed; |
8207 | | int64_t commitID; |
8208 | | int64_t commitTerm; |
8209 | | int64_t numOfSTables; |
8210 | | int64_t numOfCTables; |
8211 | | int64_t numOfNTables; |
8212 | | } SMountVnodeReq; |
8213 | | |
8214 | | int32_t tSerializeSMountVnodeReq(void* buf, int32_t* cBufLen, int32_t* tBufLen, SMountVnodeReq* pReq); |
8215 | | int32_t tDeserializeSMountVnodeReq(void* buf, int32_t bufLen, SMountVnodeReq* pReq); |
8216 | | int32_t tFreeSMountVnodeReq(SMountVnodeReq* pReq); |
8217 | | |
8218 | | #endif // USE_MOUNT |
8219 | | |
8220 | | #pragma pack(pop) |
8221 | | |
8222 | | typedef struct { |
8223 | | char db[TSDB_DB_FNAME_LEN]; |
8224 | | STimeWindow timeRange; |
8225 | | int32_t sqlLen; |
8226 | | char* sql; |
8227 | | SArray* vgroupIds; |
8228 | | } SScanDbReq; |
8229 | | |
8230 | | int32_t tSerializeSScanDbReq(void* buf, int32_t bufLen, SScanDbReq* pReq); |
8231 | | int32_t tDeserializeSScanDbReq(void* buf, int32_t bufLen, SScanDbReq* pReq); |
8232 | | void tFreeSScanDbReq(SScanDbReq* pReq); |
8233 | | |
8234 | | typedef struct { |
8235 | | int32_t scanId; |
8236 | | int8_t bAccepted; |
8237 | | } SScanDbRsp; |
8238 | | |
8239 | | int32_t tSerializeSScanDbRsp(void* buf, int32_t bufLen, SScanDbRsp* pRsp); |
8240 | | int32_t tDeserializeSScanDbRsp(void* buf, int32_t bufLen, SScanDbRsp* pRsp); |
8241 | | |
8242 | | typedef struct { |
8243 | | int32_t scanId; |
8244 | | int32_t sqlLen; |
8245 | | char* sql; |
8246 | | } SKillScanReq; |
8247 | | |
8248 | | int32_t tSerializeSKillScanReq(void* buf, int32_t bufLen, SKillScanReq* pReq); |
8249 | | int32_t tDeserializeSKillScanReq(void* buf, int32_t bufLen, SKillScanReq* pReq); |
8250 | | void tFreeSKillScanReq(SKillScanReq* pReq); |
8251 | | |
8252 | | typedef struct { |
8253 | | int32_t scanId; |
8254 | | int32_t vgId; |
8255 | | int32_t dnodeId; |
8256 | | } SVKillScanReq; |
8257 | | |
8258 | | int32_t tSerializeSVKillScanReq(void* buf, int32_t bufLen, SVKillScanReq* pReq); |
8259 | | int32_t tDeserializeSVKillScanReq(void* buf, int32_t bufLen, SVKillScanReq* pReq); |
8260 | | |
8261 | | typedef struct { |
8262 | | int32_t scanId; |
8263 | | int32_t vgId; |
8264 | | int32_t dnodeId; |
8265 | | int32_t numberFileset; |
8266 | | int32_t finished; |
8267 | | int32_t progress; |
8268 | | int64_t remainingTime; |
8269 | | } SQueryScanProgressRsp; |
8270 | | |
8271 | | int32_t tSerializeSQueryScanProgressRsp(void* buf, int32_t bufLen, SQueryScanProgressRsp* pReq); |
8272 | | int32_t tDeserializeSQueryScanProgressRsp(void* buf, int32_t bufLen, SQueryScanProgressRsp* pReq); |
8273 | | |
8274 | | typedef struct { |
8275 | | int32_t scanId; |
8276 | | int32_t vgId; |
8277 | | int32_t dnodeId; |
8278 | | } SQueryScanProgressReq; |
8279 | | |
8280 | | int32_t tSerializeSQueryScanProgressReq(void* buf, int32_t bufLen, SQueryScanProgressReq* pReq); |
8281 | | int32_t tDeserializeSQueryScanProgressReq(void* buf, int32_t bufLen, SQueryScanProgressReq* pReq); |
8282 | | |
8283 | | typedef struct { |
8284 | | int64_t dbUid; |
8285 | | char db[TSDB_DB_FNAME_LEN]; |
8286 | | int64_t scanStartTime; |
8287 | | STimeWindow tw; |
8288 | | int32_t scanId; |
8289 | | } SScanVnodeReq; |
8290 | | |
8291 | | int32_t tSerializeSScanVnodeReq(void* buf, int32_t bufLen, SScanVnodeReq* pReq); |
8292 | | int32_t tDeserializeSScanVnodeReq(void* buf, int32_t bufLen, SScanVnodeReq* pReq); |
8293 | | |
8294 | | // ============== Federated query: external source DDL messages ============== |
8295 | | |
8296 | | typedef struct SCreateExtSourceReq { |
8297 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; // external source name |
8298 | | int8_t type; // EExtSourceType |
8299 | | char host[TSDB_EXT_SOURCE_HOST_LEN]; |
8300 | | int32_t port; |
8301 | | char user[TSDB_EXT_SOURCE_USER_LEN]; |
8302 | | char password[TSDB_EXT_SOURCE_PASSWORD_LEN]; // plaintext (transport only) |
8303 | | char database[TSDB_EXT_SOURCE_DATABASE_LEN]; // default database (empty = not configured) |
8304 | | char schema_name[TSDB_EXT_SOURCE_SCHEMA_LEN];// default schema (PG only; empty otherwise) |
8305 | | char options[TSDB_EXT_SOURCE_OPTIONS_LEN]; // OPTIONS JSON string |
8306 | | int8_t ignoreExists; // IF NOT EXISTS flag |
8307 | | } SCreateExtSourceReq; |
8308 | | |
8309 | | int32_t tSerializeSCreateExtSourceReq(void* buf, int32_t bufLen, SCreateExtSourceReq* pReq); |
8310 | | int32_t tDeserializeSCreateExtSourceReq(void* buf, int32_t bufLen, SCreateExtSourceReq* pReq); |
8311 | | void tFreeSCreateExtSourceReq(SCreateExtSourceReq* pReq); |
8312 | | |
8313 | | // alterMask bit definitions: bit0=host, bit1=port, bit2=user, bit3=password, |
8314 | | // bit4=database, bit5=schema, bit6=options |
8315 | 0 | #define EXT_SOURCE_ALTER_HOST (1 << 0) |
8316 | 0 | #define EXT_SOURCE_ALTER_PORT (1 << 1) |
8317 | 0 | #define EXT_SOURCE_ALTER_USER (1 << 2) |
8318 | 0 | #define EXT_SOURCE_ALTER_PASSWORD (1 << 3) |
8319 | 0 | #define EXT_SOURCE_ALTER_DATABASE (1 << 4) |
8320 | 0 | #define EXT_SOURCE_ALTER_SCHEMA (1 << 5) |
8321 | 0 | #define EXT_SOURCE_ALTER_OPTIONS (1 << 6) |
8322 | | |
8323 | | typedef struct SAlterExtSourceReq { |
8324 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; |
8325 | | int32_t alterMask; // bit flags indicating which fields to update |
8326 | | char host[TSDB_EXT_SOURCE_HOST_LEN]; |
8327 | | int32_t port; |
8328 | | char user[TSDB_EXT_SOURCE_USER_LEN]; |
8329 | | char password[TSDB_EXT_SOURCE_PASSWORD_LEN]; |
8330 | | char database[TSDB_EXT_SOURCE_DATABASE_LEN]; |
8331 | | char schema_name[TSDB_EXT_SOURCE_SCHEMA_LEN]; |
8332 | | char options[TSDB_EXT_SOURCE_OPTIONS_LEN]; |
8333 | | int8_t ignoreNotExists; // IF EXISTS flag |
8334 | | } SAlterExtSourceReq; |
8335 | | |
8336 | | int32_t tSerializeSAlterExtSourceReq(void* buf, int32_t bufLen, SAlterExtSourceReq* pReq); |
8337 | | int32_t tDeserializeSAlterExtSourceReq(void* buf, int32_t bufLen, SAlterExtSourceReq* pReq); |
8338 | | void tFreeSAlterExtSourceReq(SAlterExtSourceReq* pReq); |
8339 | | |
8340 | | typedef struct SDropExtSourceReq { |
8341 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; |
8342 | | int8_t ignoreNotExists; // IF EXISTS flag |
8343 | | } SDropExtSourceReq; |
8344 | | |
8345 | | int32_t tSerializeSDropExtSourceReq(void* buf, int32_t bufLen, SDropExtSourceReq* pReq); |
8346 | | int32_t tDeserializeSDropExtSourceReq(void* buf, int32_t bufLen, SDropExtSourceReq* pReq); |
8347 | | void tFreeSDropExtSourceReq(SDropExtSourceReq* pReq); |
8348 | | |
8349 | | typedef struct SRefreshExtSourceReq { |
8350 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; |
8351 | | } SRefreshExtSourceReq; |
8352 | | |
8353 | | int32_t tSerializeSRefreshExtSourceReq(void* buf, int32_t bufLen, SRefreshExtSourceReq* pReq); |
8354 | | int32_t tDeserializeSRefreshExtSourceReq(void* buf, int32_t bufLen, SRefreshExtSourceReq* pReq); |
8355 | | void tFreeSRefreshExtSourceReq(SRefreshExtSourceReq* pReq); |
8356 | | |
8357 | | // Catalog -> Mnode: query a single external source (on cache miss) |
8358 | | typedef struct SGetExtSourceReq { |
8359 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; |
8360 | | } SGetExtSourceReq; |
8361 | | |
8362 | | int32_t tSerializeSGetExtSourceReq(void* buf, int32_t bufLen, SGetExtSourceReq* pReq); |
8363 | | int32_t tDeserializeSGetExtSourceReq(void* buf, int32_t bufLen, SGetExtSourceReq* pReq); |
8364 | | void tFreeSGetExtSourceReq(SGetExtSourceReq* pReq); |
8365 | | |
8366 | | // Mnode -> Catalog: external source info response (password decrypted by mnode for internal RPC) |
8367 | | typedef struct SGetExtSourceRsp { |
8368 | | char source_name[TSDB_EXT_SOURCE_NAME_LEN]; |
8369 | | int8_t type; // EExtSourceType |
8370 | | char host[TSDB_EXT_SOURCE_HOST_LEN]; |
8371 | | int32_t port; |
8372 | | char user[TSDB_EXT_SOURCE_USER_LEN]; |
8373 | | char password[TSDB_EXT_SOURCE_PASSWORD_LEN]; // mnode decrypts and fills plaintext |
8374 | | char database[TSDB_EXT_SOURCE_DATABASE_LEN]; |
8375 | | char schema_name[TSDB_EXT_SOURCE_SCHEMA_LEN]; |
8376 | | char options[TSDB_EXT_SOURCE_OPTIONS_LEN]; |
8377 | | int64_t meta_version; // incremented on every ALTER/REFRESH |
8378 | | int64_t create_time; |
8379 | | } SGetExtSourceRsp; |
8380 | | |
8381 | | int32_t tSerializeSGetExtSourceRsp(void* buf, int32_t bufLen, SGetExtSourceRsp* pRsp); |
8382 | | int32_t tDeserializeSGetExtSourceRsp(void* buf, int32_t bufLen, SGetExtSourceRsp* pRsp); |
8383 | | void tFreeSGetExtSourceRsp(SGetExtSourceRsp* pRsp); |
8384 | | |
8385 | | // Heartbeat version struct for external sources (used by HEARTBEAT_KEY_EXTSOURCE) |
8386 | | typedef struct SExtSourceVersion { |
8387 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
8388 | | int64_t metaVersion; |
8389 | | } SExtSourceVersion; |
8390 | | |
8391 | | // Heartbeat response entry for one external source |
8392 | | typedef struct SExtSourceHbInfo { |
8393 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
8394 | | int64_t metaVersion; |
8395 | | bool deleted; |
8396 | | } SExtSourceHbInfo; |
8397 | | |
8398 | | // Full heartbeat response payload for HEARTBEAT_KEY_EXTSOURCE |
8399 | | typedef struct SExtSourceHbRsp { |
8400 | | int64_t globalVer; // monotonic version of the external-source catalog |
8401 | | SArray *pSources; // SExtSourceHbInfo[] |
8402 | | } SExtSourceHbRsp; |
8403 | | |
8404 | | int32_t tSerializeSExtSourceHbRsp(void *buf, int32_t bufLen, SExtSourceHbRsp *pRsp); |
8405 | | int32_t tDeserializeSExtSourceHbRsp(void *buf, int32_t bufLen, SExtSourceHbRsp *pRsp); |
8406 | | void tFreeSExtSourceHbRsp(SExtSourceHbRsp *pRsp); |
8407 | | |
8408 | | // SQueryTableRsp.extErrMsg / extPushdownDiag: federated query diagnostics payload. |
8409 | | // Both are appended optional fields at the end of SQueryTableRsp. |
8410 | | // See SQueryTableRsp definition above; tSerializeSQueryTableRsp / tDeserializeSQueryTableRsp |
8411 | | // encode/decode both fields with dedicated has-* flags after all existing fields. |
8412 | | |
8413 | | // SExtTableMetaReq - identifies an external table to be resolved by catalog. |
8414 | | // Parser registers one per external table reference during collectMetaKey. |
8415 | | // sourceName matches the ext source name; rawMidSegs holds 0-2 intermediate |
8416 | | // path segments (db / schema) whose interpretation depends on source type; |
8417 | | // tableName is the leaf table name. The number of active segments is inferred |
8418 | | // from whether rawMidSegs[0] and rawMidSegs[1] are non-empty. |
8419 | | typedef struct SExtTableMetaReq { |
8420 | | char sourceName[TSDB_EXT_SOURCE_NAME_LEN]; |
8421 | | char rawMidSegs[2][TSDB_DB_NAME_LEN]; |
8422 | | char tableName[TSDB_TABLE_NAME_LEN]; |
8423 | | } SExtTableMetaReq; |
8424 | | |
8425 | | // ============== end of federated query messages ============== |
8426 | | |
8427 | | #ifdef __cplusplus |
8428 | | } |
8429 | | #endif |
8430 | | |
8431 | | #endif /*_TD_COMMON_TAOS_MSG_H_*/ |