minor changes
This commit is contained in:
parent
2e2ede8725
commit
53e5bfb820
|
@ -21,7 +21,7 @@
|
||||||
#include "mndTrans.h"
|
#include "mndTrans.h"
|
||||||
#include "tbase64.h"
|
#include "tbase64.h"
|
||||||
|
|
||||||
#define TSDB_USER_VER_NUMBER 1
|
#define TSDB_USER_VER_NUMBER 1
|
||||||
#define TSDB_USER_RESERVE_SIZE 64
|
#define TSDB_USER_RESERVE_SIZE 64
|
||||||
|
|
||||||
static int32_t mndCreateDefaultUsers(SMnode *pMnode);
|
static int32_t mndCreateDefaultUsers(SMnode *pMnode);
|
||||||
|
@ -270,7 +270,7 @@ static int32_t mndCreateUser(SMnode *pMnode, char *acct, SCreateUserReq *pCreate
|
||||||
userObj.updateTime = userObj.createdTime;
|
userObj.updateTime = userObj.createdTime;
|
||||||
userObj.superUser = pCreate->superUser;
|
userObj.superUser = pCreate->superUser;
|
||||||
|
|
||||||
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK,TRN_TYPE_CREATE_USER, &pReq->rpcMsg);
|
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_TYPE_CREATE_USER, &pReq->rpcMsg);
|
||||||
if (pTrans == NULL) {
|
if (pTrans == NULL) {
|
||||||
mError("user:%s, failed to create since %s", pCreate->user, terrstr());
|
mError("user:%s, failed to create since %s", pCreate->user, terrstr());
|
||||||
return -1;
|
return -1;
|
||||||
|
@ -350,7 +350,7 @@ CREATE_USER_OVER:
|
||||||
}
|
}
|
||||||
|
|
||||||
static int32_t mndUpdateUser(SMnode *pMnode, SUserObj *pOld, SUserObj *pNew, SNodeMsg *pReq) {
|
static int32_t mndUpdateUser(SMnode *pMnode, SUserObj *pOld, SUserObj *pNew, SNodeMsg *pReq) {
|
||||||
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_TYPE_ALTER_USER,&pReq->rpcMsg);
|
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_TYPE_ALTER_USER, &pReq->rpcMsg);
|
||||||
if (pTrans == NULL) {
|
if (pTrans == NULL) {
|
||||||
mError("user:%s, failed to update since %s", pOld->user, terrstr());
|
mError("user:%s, failed to update since %s", pOld->user, terrstr());
|
||||||
return -1;
|
return -1;
|
||||||
|
@ -511,7 +511,7 @@ ALTER_USER_OVER:
|
||||||
}
|
}
|
||||||
|
|
||||||
static int32_t mndDropUser(SMnode *pMnode, SNodeMsg *pReq, SUserObj *pUser) {
|
static int32_t mndDropUser(SMnode *pMnode, SNodeMsg *pReq, SUserObj *pUser) {
|
||||||
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK,TRN_TYPE_DROP_USER, &pReq->rpcMsg);
|
STrans *pTrans = mndTransCreate(pMnode, TRN_POLICY_ROLLBACK, TRN_TYPE_DROP_USER, &pReq->rpcMsg);
|
||||||
if (pTrans == NULL) {
|
if (pTrans == NULL) {
|
||||||
mError("user:%s, failed to drop since %s", pUser->user, terrstr());
|
mError("user:%s, failed to drop since %s", pUser->user, terrstr());
|
||||||
return -1;
|
return -1;
|
||||||
|
|
Loading…
Reference in New Issue