Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
dc30a83f
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
dc30a83f
编写于
3月 02, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
monitor
上级
8b1a9911
变更
31
隐藏空白更改
内联
并排
Showing
31 changed file
with
135 addition
and
105 deletion
+135
-105
include/dnode/mnode/mnode.h
include/dnode/mnode/mnode.h
+8
-17
include/libs/monitor/monitor.h
include/libs/monitor/monitor.h
+26
-26
source/common/CMakeLists.txt
source/common/CMakeLists.txt
+1
-1
source/common/src/tname.c
source/common/src/tname.c
+2
-1
source/dnode/bnode/CMakeLists.txt
source/dnode/bnode/CMakeLists.txt
+1
-1
source/dnode/mgmt/daemon/CMakeLists.txt
source/dnode/mgmt/daemon/CMakeLists.txt
+1
-1
source/dnode/mgmt/impl/CMakeLists.txt
source/dnode/mgmt/impl/CMakeLists.txt
+1
-12
source/dnode/mgmt/impl/inc/dndInt.h
source/dnode/mgmt/impl/inc/dndInt.h
+1
-0
source/dnode/mgmt/impl/inc/dndMnode.h
source/dnode/mgmt/impl/inc/dndMnode.h
+3
-0
source/dnode/mgmt/impl/src/dndMgmt.c
source/dnode/mgmt/impl/src/dndMgmt.c
+16
-2
source/dnode/mgmt/impl/src/dndMnode.c
source/dnode/mgmt/impl/src/dndMnode.c
+10
-0
source/dnode/mgmt/impl/test/sut/CMakeLists.txt
source/dnode/mgmt/impl/test/sut/CMakeLists.txt
+1
-1
source/dnode/mnode/impl/CMakeLists.txt
source/dnode/mnode/impl/CMakeLists.txt
+2
-8
source/dnode/mnode/impl/inc/mndInt.h
source/dnode/mnode/impl/inc/mndInt.h
+19
-3
source/dnode/mnode/impl/src/mnode.c
source/dnode/mnode/impl/src/mnode.c
+7
-3
source/dnode/mnode/sdb/CMakeLists.txt
source/dnode/mnode/sdb/CMakeLists.txt
+2
-5
source/dnode/qnode/CMakeLists.txt
source/dnode/qnode/CMakeLists.txt
+1
-1
source/dnode/snode/CMakeLists.txt
source/dnode/snode/CMakeLists.txt
+1
-1
source/libs/cache/CMakeLists.txt
source/libs/cache/CMakeLists.txt
+1
-1
source/libs/catalog/CMakeLists.txt
source/libs/catalog/CMakeLists.txt
+1
-1
source/libs/function/CMakeLists.txt
source/libs/function/CMakeLists.txt
+1
-1
source/libs/index/CMakeLists.txt
source/libs/index/CMakeLists.txt
+1
-1
source/libs/monitor/src/monitor.c
source/libs/monitor/src/monitor.c
+19
-5
source/libs/parser/CMakeLists.txt
source/libs/parser/CMakeLists.txt
+1
-1
source/libs/planner/CMakeLists.txt
source/libs/planner/CMakeLists.txt
+1
-1
source/libs/scheduler/CMakeLists.txt
source/libs/scheduler/CMakeLists.txt
+1
-1
source/libs/sync/CMakeLists.txt
source/libs/sync/CMakeLists.txt
+1
-1
source/libs/transport/CMakeLists.txt
source/libs/transport/CMakeLists.txt
+1
-1
source/libs/wal/CMakeLists.txt
source/libs/wal/CMakeLists.txt
+1
-1
source/os/CMakeLists.txt
source/os/CMakeLists.txt
+2
-6
source/util/src/thttp.c
source/util/src/thttp.c
+1
-1
未找到文件。
include/dnode/mnode/mnode.h
浏览文件 @
dc30a83f
...
...
@@ -16,6 +16,8 @@
#ifndef _TD_MND_H_
#define _TD_MND_H_
#include "monitor.h"
#ifdef __cplusplus
extern
"C"
{
#endif
...
...
@@ -30,20 +32,6 @@ typedef int32_t (*PutReqToMWriteQFp)(SDnode *pDnode, struct SRpcMsg *rpcMsg);
typedef
int32_t
(
*
PutReqToMReadQFp
)(
SDnode
*
pDnode
,
struct
SRpcMsg
*
rpcMsg
);
typedef
void
(
*
SendRedirectRspFp
)(
SDnode
*
pDnode
,
struct
SRpcMsg
*
rpcMsg
);
typedef
struct
SMnodeLoad
{
int64_t
numOfDnode
;
int64_t
numOfMnode
;
int64_t
numOfVgroup
;
int64_t
numOfDatabase
;
int64_t
numOfSuperTable
;
int64_t
numOfChildTable
;
int64_t
numOfNormalTable
;
int64_t
numOfColumn
;
int64_t
totalPoints
;
int64_t
totalStorage
;
int64_t
compStorage
;
}
SMnodeLoad
;
typedef
struct
{
int32_t
dnodeId
;
int64_t
clusterId
;
...
...
@@ -92,13 +80,16 @@ int32_t mndAlter(SMnode *pMnode, const SMnodeOpt *pOption);
void
mndDestroy
(
const
char
*
path
);
/**
* @brief Get mnode
statistics
info.
* @brief Get mnode
monitor
info.
*
* @param pMnode The mnode object.
* @param pLoad Statistics of the mnode.
* @param pClusterInfo
* @param pVgroupInfo
* @param pGrantInfo
* @return int32_t 0 for success, -1 for failure.
*/
int32_t
mndGetLoad
(
SMnode
*
pMnode
,
SMnodeLoad
*
pLoad
);
int32_t
mndGetMonitorInfo
(
SMnode
*
pMnode
,
SMonClusterInfo
*
pClusterInfo
,
SMonVgroupInfo
*
pVgroupInfo
,
SMonGrantInfo
*
pGrantInfo
);
/**
* @brief Get user authentication info.
...
...
include/libs/monitor/monitor.h
浏览文件 @
dc30a83f
...
...
@@ -55,6 +55,30 @@ typedef struct {
SArray
*
mnodes
;
// array of SMonMnodeDesc
}
SMonClusterInfo
;
typedef
struct
{
int32_t
dnode_id
;
int8_t
vnode_online
;
char
vnode_role
[
8
];
}
SMonVnodeDesc
;
typedef
struct
{
int32_t
vgroup_id
;
SMonVnodeDesc
vnodes
[
TSDB_MAX_REPLICA
];
}
SMonVgroupDesc
;
typedef
struct
{
char
database_name
[
TSDB_DB_NAME_LEN
];
int32_t
tables_num
;
int8_t
status
;
SArray
*
vgroups
;
// array of SMonVgroupDesc
}
SMonVgroupInfo
;
typedef
struct
{
int32_t
expire_time
;
int32_t
timeseries_used
;
int32_t
timeseries_total
;
}
SMonGrantInfo
;
typedef
struct
{
float
uptime
;
// day
float
cpu_engine
;
...
...
@@ -96,36 +120,12 @@ typedef struct {
SArray
*
disks
;
// array of SMonDiskDesc
}
SMonDiskInfo
;
typedef
struct
{
int32_t
dnode_id
;
int8_t
vnode_online
;
char
vnode_role
[
8
];
}
SMonVnodeDesc
;
typedef
struct
{
int32_t
vgroup_id
;
SMonVnodeDesc
vnodes
[
TSDB_MAX_REPLICA
];
}
SMonVgroupDesc
;
typedef
struct
{
char
database_name
[
TSDB_DB_NAME_LEN
];
int32_t
tables_num
;
int8_t
status
;
SArray
*
vgroups
;
// array of SMonVgroupDesc
}
SMonVgroupInfo
;
typedef
struct
{
int64_t
ts
;
int8_t
level
;
char
content
[
1024
];
}
SMonLogItem
;
typedef
struct
{
int32_t
expire_time
;
int32_t
timeseries_used
;
int32_t
timeseries_total
;
}
SMonGrantInfo
;
typedef
struct
SMonInfo
SMonInfo
;
typedef
struct
{
...
...
@@ -141,10 +141,10 @@ void monAddLogItem(SMonLogItem *pItem);
SMonInfo
*
monCreateMonitorInfo
();
void
monSetBasicInfo
(
SMonInfo
*
pMonitor
,
SMonBasicInfo
*
pInfo
);
void
monSetClusterInfo
(
SMonInfo
*
pMonitor
,
SMonClusterInfo
*
pInfo
);
void
monSetVgroupInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
);
void
monSetGrantInfo
(
SMonInfo
*
pMonitor
,
SMonGrantInfo
*
pInfo
);
void
monSetDnodeInfo
(
SMonInfo
*
pMonitor
,
SMonDnodeInfo
*
pInfo
);
void
monSetDiskInfo
(
SMonInfo
*
pMonitor
,
SMonDiskInfo
*
pInfo
);
void
monSetVgroupInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
);
void
monSetGrantInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
);
void
monSendReport
(
SMonInfo
*
pMonitor
);
void
monCleanupMonitorInfo
(
SMonInfo
*
pMonitor
);
...
...
source/common/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src COMMON_SRC
)
add_library
(
common
${
COMMON_SRC
}
)
add_library
(
common
STATIC
${
COMMON_SRC
}
)
target_include_directories
(
common
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/common"
...
...
source/common/src/tname.c
浏览文件 @
dc30a83f
...
...
@@ -22,6 +22,7 @@ bool tscValidateTableNameLength(size_t len) {
return
len
<
TSDB_TABLE_NAME_LEN
;
}
#if 0
// TODO refactor
SColumnFilterInfo* tFilterInfoDup(const SColumnFilterInfo* src, int32_t numOfFilters) {
if (numOfFilters == 0 || src == NULL) {
...
...
@@ -46,7 +47,7 @@ SColumnFilterInfo* tFilterInfoDup(const SColumnFilterInfo* src, int32_t numOfFil
return pFilter;
}
#endif
#if 0
int64_t taosGetIntervalStartTimestamp(int64_t startTime, int64_t slidingTime, int64_t intervalTime, char timeUnit, int16_t precision) {
if (slidingTime == 0) {
...
...
source/dnode/bnode/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src BNODE_SRC
)
add_library
(
bnode
${
BNODE_SRC
}
)
add_library
(
bnode
STATIC
${
BNODE_SRC
}
)
target_include_directories
(
bnode
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/dnode/bnode"
...
...
source/dnode/mgmt/daemon/CMakeLists.txt
浏览文件 @
dc30a83f
...
...
@@ -6,4 +6,4 @@ target_include_directories(
PRIVATE
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/inc"
)
target_link_libraries
(
taosd dnode
util os
)
target_link_libraries
(
taosd dnode
)
source/dnode/mgmt/impl/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src DNODE_SRC
)
add_library
(
dnode STATIC
${
DNODE_SRC
}
)
target_link_libraries
(
dnode
PUBLIC cjson
PUBLIC mnode
PUBLIC vnode
PUBLIC qnode
PUBLIC snode
PUBLIC bnode
PUBLIC wal
PUBLIC sync
PUBLIC taos
PUBLIC tfs
PUBLIC monitor
dnode cjson mnode vnode qnode snode bnode wal sync taos tfs monitor
)
target_include_directories
(
dnode
...
...
source/dnode/mgmt/impl/inc/dndInt.h
浏览文件 @
dc30a83f
...
...
@@ -36,6 +36,7 @@ extern "C" {
#include "ttime.h"
#include "tworker.h"
#include "tglobal.h"
#include "monitor.h"
#include "dnode.h"
...
...
source/dnode/mgmt/impl/inc/dndMnode.h
浏览文件 @
dc30a83f
...
...
@@ -32,6 +32,9 @@ int32_t dndProcessCreateMnodeReq(SDnode *pDnode, SRpcMsg *pRpcMsg);
int32_t
dndProcessAlterMnodeReq
(
SDnode
*
pDnode
,
SRpcMsg
*
pRpcMsg
);
int32_t
dndProcessDropMnodeReq
(
SDnode
*
pDnode
,
SRpcMsg
*
pRpcMsg
);
int32_t
dndGetMnodeMonitorInfo
(
SDnode
*
pDnode
,
SMonClusterInfo
*
pClusterInfo
,
SMonVgroupInfo
*
pVgroupInfo
,
SMonGrantInfo
*
pGrantInfo
);
#ifdef __cplusplus
}
#endif
...
...
source/dnode/mgmt/impl/src/dndMgmt.c
浏览文件 @
dc30a83f
...
...
@@ -474,6 +474,11 @@ void dndProcessStartupReq(SDnode *pDnode, SRpcMsg *pReq) {
rpcSendResponse
(
&
rpcRsp
);
}
void
dndGetBasicInfo
(
SDnode
*
pDnode
,
SMonBasicInfo
*
pInfo
)
{
pInfo
->
dnode_id
=
dndGetDnodeId
(
pDnode
);
tstrncpy
(
pInfo
->
dnode_ep
,
tsLocalEp
,
TSDB_EP_LEN
);
}
static
void
dndSendMonitorReport
(
SDnode
*
pDnode
)
{
if
(
!
tsEnableMonitor
||
tsMonitorFqdn
[
0
]
==
0
)
return
;
SMonInfo
*
pMonitor
=
monCreateMonitorInfo
();
...
...
@@ -481,10 +486,19 @@ static void dndSendMonitorReport(SDnode *pDnode) {
dTrace
(
"pDnode:%p, send monitor report to %s:%u"
,
pDnode
,
tsMonitorFqdn
,
tsMonitorPort
);
SMonBasicInfo
basicInfo
=
{
.
dnode_id
=
dndGetDnodeId
(
pDnode
)
};
tstrncpy
(
basicInfo
.
dnode_ep
,
tsLocalEp
,
TSDB_EP_LEN
);
SMonBasicInfo
basicInfo
=
{
0
};
dndGetBasicInfo
(
pDnode
,
&
basicInfo
);
monSetBasicInfo
(
pMonitor
,
&
basicInfo
);
SMonClusterInfo
clusterInfo
=
{
0
};
SMonVgroupInfo
vgroupInfo
=
{
0
};
SMonGrantInfo
grantInfo
=
{
0
};
if
(
dndGetMnodeMonitorInfo
(
pDnode
,
&
clusterInfo
,
&
vgroupInfo
,
&
grantInfo
)
==
0
)
{
monSetClusterInfo
(
pMonitor
,
&
clusterInfo
);
monSetVgroupInfo
(
pMonitor
,
&
vgroupInfo
);
monSetGrantInfo
(
pMonitor
,
&
grantInfo
);
}
monSendReport
(
pMonitor
);
monCleanupMonitorInfo
(
pMonitor
);
}
...
...
source/dnode/mgmt/impl/src/dndMnode.c
浏览文件 @
dc30a83f
...
...
@@ -630,3 +630,13 @@ int32_t dndGetUserAuthFromMnode(SDnode *pDnode, char *user, char *spi, char *enc
dTrace
(
"user:%s, retrieve auth spi:%d encrypt:%d"
,
user
,
*
spi
,
*
encrypt
);
return
code
;
}
int32_t
dndGetMnodeMonitorInfo
(
SDnode
*
pDnode
,
SMonClusterInfo
*
pClusterInfo
,
SMonVgroupInfo
*
pVgroupInfo
,
SMonGrantInfo
*
pGrantInfo
)
{
SMnode
*
pMnode
=
dndAcquireMnode
(
pDnode
);
if
(
pMnode
==
NULL
)
return
-
1
;
int32_t
code
=
mndGetMonitorInfo
(
pMnode
,
pClusterInfo
,
pVgroupInfo
,
pGrantInfo
);
dndReleaseMnode
(
pDnode
,
pMnode
);
return
code
;
}
\ No newline at end of file
source/dnode/mgmt/impl/test/sut/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src SUT_SRC
)
add_library
(
sut STATIC
${
SUT_SRC
}
)
add_library
(
sut STATIC
STATIC
${
SUT_SRC
}
)
target_link_libraries
(
sut
PUBLIC dnode
...
...
source/dnode/mnode/impl/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src MNODE_SRC
)
add_library
(
mnode
${
MNODE_SRC
}
)
add_library
(
mnode
STATIC
${
MNODE_SRC
}
)
target_include_directories
(
mnode
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/dnode/mnode"
PRIVATE
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/inc"
)
target_link_libraries
(
mnode
PRIVATE scheduler
PRIVATE sdb
PRIVATE wal
PRIVATE transport
PRIVATE cjson
PRIVATE sync
mnode scheduler sdb wal transport cjson sync monitor
)
if
(
${
BUILD_TEST
}
)
...
...
source/dnode/mnode/impl/inc/mndInt.h
浏览文件 @
dc30a83f
...
...
@@ -21,11 +21,11 @@
#include "sdb.h"
#include "tcache.h"
#include "tep.h"
#include "tglobal.h"
#include "tqueue.h"
#include "ttime.h"
#include "wal.h"
#include "version.h"
#include "
tglob
al.h"
#include "
w
al.h"
#ifdef __cplusplus
extern
"C"
{
...
...
@@ -38,6 +38,20 @@ typedef int32_t (*ShowMetaFp)(SMnodeMsg *pMsg, SShowObj *pShow, STableMetaRsp *p
typedef
int32_t
(
*
ShowRetrieveFp
)(
SMnodeMsg
*
pMsg
,
SShowObj
*
pShow
,
char
*
data
,
int32_t
rows
);
typedef
void
(
*
ShowFreeIterFp
)(
SMnode
*
pMnode
,
void
*
pIter
);
typedef
struct
SMnodeLoad
{
int64_t
numOfDnode
;
int64_t
numOfMnode
;
int64_t
numOfVgroup
;
int64_t
numOfDatabase
;
int64_t
numOfSuperTable
;
int64_t
numOfChildTable
;
int64_t
numOfNormalTable
;
int64_t
numOfColumn
;
int64_t
totalPoints
;
int64_t
totalStorage
;
int64_t
compStorage
;
}
SMnodeLoad
;
typedef
struct
{
const
char
*
name
;
MndInitFp
initFp
;
...
...
@@ -104,7 +118,9 @@ int32_t mndSendReqToMnode(SMnode *pMnode, SRpcMsg *pMsg);
void
mndSendRedirectRsp
(
SMnode
*
pMnode
,
SRpcMsg
*
pMsg
);
void
mndSetMsgHandle
(
SMnode
*
pMnode
,
tmsg_t
msgType
,
MndMsgFp
fp
);
uint64_t
mndGenerateUid
(
char
*
name
,
int32_t
len
)
;
uint64_t
mndGenerateUid
(
char
*
name
,
int32_t
len
);
int32_t
mndGetLoad
(
SMnode
*
pMnode
,
SMnodeLoad
*
pLoad
);
#ifdef __cplusplus
}
...
...
source/dnode/mnode/impl/src/mnode.c
浏览文件 @
dc30a83f
...
...
@@ -22,6 +22,7 @@
#include "mndDb.h"
#include "mndDnode.h"
#include "mndFunc.h"
#include "mndInfoSchema.h"
#include "mndMnode.h"
#include "mndOffset.h"
#include "mndProfile.h"
...
...
@@ -36,7 +37,6 @@
#include "mndTrans.h"
#include "mndUser.h"
#include "mndVgroup.h"
#include "mndInfoSchema.h"
#define MQ_TIMER_MS 3000
#define TRNAS_TIMER_MS 6000
...
...
@@ -400,6 +400,11 @@ int32_t mndGetLoad(SMnode *pMnode, SMnodeLoad *pLoad) {
return
0
;
}
int32_t
mndGetMonitorInfo
(
SMnode
*
pMnode
,
SMonClusterInfo
*
pClusterInfo
,
SMonVgroupInfo
*
pVgroupInfo
,
SMonGrantInfo
*
pGrantInfo
)
{
return
0
;
}
SMnodeMsg
*
mndInitMsg
(
SMnode
*
pMnode
,
SRpcMsg
*
pRpcMsg
)
{
SMnodeMsg
*
pMsg
=
taosAllocateQitem
(
sizeof
(
SMnodeMsg
));
if
(
pMsg
==
NULL
)
{
...
...
@@ -505,10 +510,9 @@ void mndSetMsgHandle(SMnode *pMnode, tmsg_t msgType, MndMsgFp fp) {
}
}
// Note: uid 0 is reserved
uint64_t
mndGenerateUid
(
char
*
name
,
int32_t
len
)
{
int32_t
hashval
=
MurmurHash3_32
(
name
,
len
);
int32_t
hashval
=
MurmurHash3_32
(
name
,
len
);
do
{
int64_t
us
=
taosGetTimestampUs
();
...
...
source/dnode/mnode/sdb/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src MNODE_SRC
)
add_library
(
sdb
${
MNODE_SRC
}
)
add_library
(
sdb
STATIC
${
MNODE_SRC
}
)
target_include_directories
(
sdb
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/dnode/mnode/sdb"
PRIVATE
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/inc"
)
target_link_libraries
(
sdb
PRIVATE os
PRIVATE common
PRIVATE util
sdb os common util
)
\ No newline at end of file
source/dnode/qnode/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src QNODE_SRC
)
add_library
(
qnode
${
QNODE_SRC
}
)
add_library
(
qnode
STATIC
${
QNODE_SRC
}
)
target_include_directories
(
qnode
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/dnode/qnode"
...
...
source/dnode/snode/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src SNODE_SRC
)
add_library
(
snode
${
SNODE_SRC
}
)
add_library
(
snode
STATIC
${
SNODE_SRC
}
)
target_include_directories
(
snode
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/dnode/snode"
...
...
source/libs/cache/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src CACHE_SRC
)
add_library
(
cache
${
CACHE_SRC
}
)
add_library
(
cache
STATIC
${
CACHE_SRC
}
)
target_include_directories
(
cache
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/cache"
...
...
source/libs/catalog/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src CATALOG_SRC
)
add_library
(
catalog
${
CATALOG_SRC
}
)
add_library
(
catalog
STATIC
${
CATALOG_SRC
}
)
target_include_directories
(
catalog
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/catalog"
...
...
source/libs/function/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src FUNCTION_SRC
)
add_library
(
function
${
FUNCTION_SRC
}
)
add_library
(
function
STATIC
${
FUNCTION_SRC
}
)
target_include_directories
(
function
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/function"
...
...
source/libs/index/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src INDEX_SRC
)
add_library
(
index
${
INDEX_SRC
}
)
add_library
(
index
STATIC
${
INDEX_SRC
}
)
target_include_directories
(
index
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/index"
...
...
source/libs/monitor/src/monitor.c
浏览文件 @
dc30a83f
...
...
@@ -96,8 +96,22 @@ void monSetBasicInfo(SMonInfo *pMonitor, SMonBasicInfo *pInfo) {
tjsonAddStringToObject
(
pJson
,
"ts"
,
buf
);
}
void
monSetClusterInfo
(
SMonInfo
*
pMonitor
,
SMonClusterInfo
*
pInfo
);
void
monSetDnodeInfo
(
SMonInfo
*
pMonitor
,
SMonDnodeInfo
*
pInfo
);
void
monSetDiskInfo
(
SMonInfo
*
pMonitor
,
SMonDiskInfo
*
pInfo
);
void
monSetVgroupInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
);
void
monSetGrantInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
);
void
monSetClusterInfo
(
SMonInfo
*
pMonitor
,
SMonClusterInfo
*
pInfo
)
{
}
void
monSetVgroupInfo
(
SMonInfo
*
pMonitor
,
SMonVgroupInfo
*
pInfo
)
{
}
void
monSetGrantInfo
(
SMonInfo
*
pMonitor
,
SMonGrantInfo
*
pInfo
)
{
}
void
monSetDnodeInfo
(
SMonInfo
*
pMonitor
,
SMonDnodeInfo
*
pInfo
)
{
}
void
monSetDiskInfo
(
SMonInfo
*
pMonitor
,
SMonDiskInfo
*
pInfo
)
{
}
source/libs/parser/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src PARSER_SRC
)
add_library
(
parser
${
PARSER_SRC
}
)
add_library
(
parser
STATIC
${
PARSER_SRC
}
)
target_include_directories
(
parser
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/parser"
...
...
source/libs/planner/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src PLANNER_SRC
)
add_library
(
planner
${
PLANNER_SRC
}
)
add_library
(
planner
STATIC
${
PLANNER_SRC
}
)
target_include_directories
(
planner
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/planner"
...
...
source/libs/scheduler/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src SCHEDULER_SRC
)
add_library
(
scheduler
${
SCHEDULER_SRC
}
)
add_library
(
scheduler
STATIC
${
SCHEDULER_SRC
}
)
target_include_directories
(
scheduler
...
...
source/libs/sync/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src SYNC_SRC
)
add_library
(
sync
${
SYNC_SRC
}
)
add_library
(
sync
STATIC
${
SYNC_SRC
}
)
target_link_libraries
(
sync
...
...
source/libs/transport/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src TRANSPORT_SRC
)
add_library
(
transport
${
TRANSPORT_SRC
}
)
add_library
(
transport
STATIC
${
TRANSPORT_SRC
}
)
target_include_directories
(
transport
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/transport"
...
...
source/libs/wal/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src WAL_SRC
)
add_library
(
wal
${
WAL_SRC
}
)
add_library
(
wal
STATIC
${
WAL_SRC
}
)
target_include_directories
(
wal
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/libs/wal"
...
...
source/os/CMakeLists.txt
浏览文件 @
dc30a83f
aux_source_directory
(
src OS_SRC
)
add_library
(
os
${
OS_SRC
}
)
add_library
(
os
STATIC
${
OS_SRC
}
)
target_include_directories
(
os
PUBLIC
"
${
CMAKE_SOURCE_DIR
}
/include/os"
PRIVATE
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/include"
)
target_link_libraries
(
os
PUBLIC pthread
PUBLIC dl
PUBLIC rt
PUBLIC m
os pthread dl rt m
)
\ No newline at end of file
source/util/src/thttp.c
浏览文件 @
dc30a83f
...
...
@@ -32,7 +32,7 @@ int32_t taosSendHttpReport(const char* server, uint16_t port, const char* pCont,
fd
=
taosOpenTcpClientSocket
(
ip
,
port
,
0
);
if
(
fd
<
0
)
{
terrno
=
TAOS_SYSTEM_ERROR
(
errno
);
uError
(
"failed to create socket to %s:%u since %s"
,
server
,
port
,
terrstr
());
uError
(
"failed to create
http
socket to %s:%u since %s"
,
server
,
port
,
terrstr
());
goto
SEND_OVER
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录