MXS-1475 Address review issues
- Clean up session header. - Add test case
This commit is contained in:
@ -154,6 +154,8 @@ typedef struct session_variable
|
|||||||
} SESSION_VARIABLE;
|
} SESSION_VARIABLE;
|
||||||
|
|
||||||
typedef std::tr1::unordered_map<std::string, SESSION_VARIABLE> SessionVarsByName;
|
typedef std::tr1::unordered_map<std::string, SESSION_VARIABLE> SessionVarsByName;
|
||||||
|
#else
|
||||||
|
typedef void SessionVarsByName;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -190,11 +192,7 @@ typedef struct session
|
|||||||
const struct server *target; /**< Where the statement was sent */
|
const struct server *target; /**< Where the statement was sent */
|
||||||
} stmt; /**< Current statement being executed */
|
} stmt; /**< Current statement being executed */
|
||||||
bool qualifies_for_pooling; /**< Whether this session qualifies for the connection pool */
|
bool qualifies_for_pooling; /**< Whether this session qualifies for the connection pool */
|
||||||
#ifdef __cplusplus
|
|
||||||
SessionVarsByName* variables; /*< @maxscale variables associated with this session */
|
SessionVarsByName* variables; /*< @maxscale variables associated with this session */
|
||||||
#else
|
|
||||||
void* variables;
|
|
||||||
#endif
|
|
||||||
skygw_chk_t ses_chk_tail;
|
skygw_chk_t ses_chk_tail;
|
||||||
} MXS_SESSION;
|
} MXS_SESSION;
|
||||||
|
|
||||||
|
@ -218,6 +218,12 @@ struct TEST_CASE
|
|||||||
"@MAXSCALE.CACHE.ENABLED",
|
"@MAXSCALE.CACHE.ENABLED",
|
||||||
"TRUE"
|
"TRUE"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"SET @MAXSCALE.CACHE.ENABLED = TRUE, @maxscale.cache.enabled = FALSE",
|
||||||
|
P::IS_SET_MAXSCALE,
|
||||||
|
"@maxscale.cache.enabled",
|
||||||
|
"FALSE"
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const int N_TEST_CASES = sizeof(test_cases) / sizeof(test_cases[0]);
|
const int N_TEST_CASES = sizeof(test_cases) / sizeof(test_cases[0]);
|
||||||
|
Reference in New Issue
Block a user