enh: support spread active codes
This commit is contained in:
parent
9e12ad408e
commit
63a17295a7
|
@ -28,8 +28,9 @@ int32_t mndGetClusterName(SMnode *pMnode, char *clusterName, int32_t len);
|
||||||
int64_t mndGetClusterId(SMnode *pMnode);
|
int64_t mndGetClusterId(SMnode *pMnode);
|
||||||
int64_t mndGetClusterCreateTime(SMnode *pMnode);
|
int64_t mndGetClusterCreateTime(SMnode *pMnode);
|
||||||
int32_t mndGetClusterGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo);
|
int32_t mndGetClusterGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo);
|
||||||
|
int32_t mndSetClusterGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo);
|
||||||
int64_t mndGetClusterUpTime(SMnode *pMnode);
|
int64_t mndGetClusterUpTime(SMnode *pMnode);
|
||||||
int32_t mndProcessGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo);
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
@ -379,7 +379,7 @@ static int32_t mndProcessUptimeTimer(SRpcMsg *pReq) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t mndProcessGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo) {
|
int32_t mndSetClusterGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo) {
|
||||||
SClusterObj clusterObj = {0};
|
SClusterObj clusterObj = {0};
|
||||||
void *pIter = NULL;
|
void *pIter = NULL;
|
||||||
SClusterObj *pCluster = mndAcquireCluster(pMnode, &pIter);
|
SClusterObj *pCluster = mndAcquireCluster(pMnode, &pIter);
|
||||||
|
@ -399,7 +399,6 @@ int32_t mndProcessGrantedInfo(SMnode *pMnode, SGrantedInfo *pInfo) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
mInfo("update cluster granted info to %" PRIi64 ",%" PRIi64, clusterObj.grantedTime, clusterObj.connGrantedTime);
|
|
||||||
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_CONFLICT_NOTHING, NULL, "granted-info");
|
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_CONFLICT_NOTHING, NULL, "granted-info");
|
||||||
if (pTrans == NULL) return -1;
|
if (pTrans == NULL) return -1;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue