Rename UPSTREAM to MXS_UPSTREAM
And DOWNSTREAM to MXS_DOWNSTREAM
This commit is contained in:
@ -50,7 +50,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARA
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -86,9 +86,9 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down; /*< The downstream filter */
|
||||
int hints_left; /*< Number of hints left to add to queries*/
|
||||
time_t last_modification; /*< Time of the last data modifying operation */
|
||||
MXS_DOWNSTREAM down; /*< The downstream filter */
|
||||
int hints_left; /*< Number of hints left to add to queries*/
|
||||
time_t last_modification; /*< Time of the last data modifying operation */
|
||||
} CCR_SESSION;
|
||||
|
||||
/**
|
||||
@ -269,7 +269,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
CCR_SESSION *my_session = (CCR_SESSION *)session;
|
||||
|
||||
|
@ -98,7 +98,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -260,11 +260,11 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
SESSION* session; /*< Client session structure */
|
||||
char* errmsg; /*< Rule specific error message */
|
||||
QUERYSPEED* query_speed; /*< How fast the user has executed queries */
|
||||
DOWNSTREAM down; /*< Next object in the downstream chain */
|
||||
UPSTREAM up; /*< Next object in the upstream chain */
|
||||
SESSION *session; /*< Client session structure */
|
||||
char *errmsg; /*< Rule specific error message */
|
||||
QUERYSPEED *query_speed; /*< How fast the user has executed queries */
|
||||
MXS_DOWNSTREAM down; /*< Next object in the downstream chain */
|
||||
MXS_UPSTREAM up; /*< Next object in the upstream chain */
|
||||
} FW_SESSION;
|
||||
|
||||
bool parse_at_times(const char** tok, char** saveptr, RULE* ruledef);
|
||||
@ -1638,7 +1638,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
FW_SESSION *my_session = (FW_SESSION *) session;
|
||||
my_session->down = *downstream;
|
||||
|
@ -27,7 +27,7 @@ static MXS_FILTER *createInstance(const char* name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -176,7 +176,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
HINT_SESSION *my_session = (HINT_SESSION *)session;
|
||||
|
||||
|
@ -90,11 +90,11 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down;
|
||||
GWBUF *request;
|
||||
int query_len;
|
||||
HINTSTACK *stack;
|
||||
NAMEDHINTS *named_hints; /* The named hints defined in this session */
|
||||
MXS_DOWNSTREAM down;
|
||||
GWBUF *request;
|
||||
int query_len;
|
||||
HINTSTACK *stack;
|
||||
NAMEDHINTS *named_hints; /* The named hints defined in this session */
|
||||
} HINT_SESSION;
|
||||
|
||||
/* Some useful macros */
|
||||
|
@ -50,8 +50,8 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, UPSTREAM *upstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, MXS_DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, MXS_UPSTREAM *upstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, GWBUF *queue);
|
||||
static int clientReply(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, GWBUF *queue);
|
||||
static void diagnostics(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, DCB *dcb);
|
||||
@ -153,14 +153,14 @@ static void maxrows_response_state_reset(MAXROWS_RESPONSE_STATE *state);
|
||||
|
||||
typedef struct maxrows_session_data
|
||||
{
|
||||
MAXROWS_INSTANCE *instance; /**< The maxrows instance the session is associated with. */
|
||||
DOWNSTREAM down; /**< The previous filter or equivalent. */
|
||||
UPSTREAM up; /**< The next filter or equivalent. */
|
||||
MAXROWS_RESPONSE_STATE res; /**< The response state. */
|
||||
SESSION *session; /**< The session this data is associated with. */
|
||||
MAXROWS_INSTANCE *instance; /**< The maxrows instance the session is associated with. */
|
||||
MXS_DOWNSTREAM down; /**< The previous filter or equivalent. */
|
||||
MXS_UPSTREAM up; /**< The next filter or equivalent. */
|
||||
MAXROWS_RESPONSE_STATE res; /**< The response state. */
|
||||
SESSION *session; /**< The session this data is associated with. */
|
||||
maxrows_session_state_t state;
|
||||
bool large_packet; /**< Large packet (> 16MB)) indicator */
|
||||
bool discard_resultset; /**< Discard resultset indicator */
|
||||
bool large_packet; /**< Large packet (> 16MB)) indicator */
|
||||
bool discard_resultset; /**< Discard resultset indicator */
|
||||
} MAXROWS_SESSION_DATA;
|
||||
|
||||
static MAXROWS_SESSION_DATA *maxrows_session_data_create(MAXROWS_INSTANCE *instance, SESSION *session);
|
||||
@ -252,7 +252,7 @@ static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata)
|
||||
* @param sdata The session data of the session
|
||||
* @param down The downstream filter or router
|
||||
*/
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, DOWNSTREAM *down)
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, MXS_DOWNSTREAM *down)
|
||||
{
|
||||
MAXROWS_INSTANCE *cinstance = (MAXROWS_INSTANCE*)instance;
|
||||
MAXROWS_SESSION_DATA *csdata = (MAXROWS_SESSION_DATA*)sdata;
|
||||
@ -267,7 +267,7 @@ static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, DOWNS
|
||||
* @param sdata The session data of the session
|
||||
* @param up The upstream filter or router
|
||||
*/
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, UPSTREAM *up)
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *sdata, MXS_UPSTREAM *up)
|
||||
{
|
||||
MAXROWS_INSTANCE *cinstance = (MAXROWS_INSTANCE*)instance;
|
||||
MAXROWS_SESSION_DATA *csdata = (MAXROWS_SESSION_DATA*)sdata;
|
||||
|
@ -87,8 +87,8 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, UPSTREAM *upstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_UPSTREAM *upstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static int clientReply(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
@ -229,8 +229,8 @@ typedef struct
|
||||
{
|
||||
char* uid; /**Unique identifier used to tag messages*/
|
||||
char* db; /**The currently active database*/
|
||||
DOWNSTREAM down;
|
||||
UPSTREAM up;
|
||||
MXS_DOWNSTREAM down;
|
||||
MXS_UPSTREAM up;
|
||||
SESSION* session;
|
||||
bool was_query; /**True if the previous routeQuery call had valid content*/
|
||||
} MQ_SESSION;
|
||||
@ -873,13 +873,13 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
MQ_SESSION *my_session = (MQ_SESSION *) session;
|
||||
my_session->down = *downstream;
|
||||
}
|
||||
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, UPSTREAM *upstream)
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_UPSTREAM *upstream)
|
||||
{
|
||||
MQ_SESSION *my_session = (MQ_SESSION *) session;
|
||||
my_session->up = *upstream;
|
||||
|
@ -44,7 +44,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -66,7 +66,7 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down; /* The downstream filter */
|
||||
MXS_DOWNSTREAM down; /* The downstream filter */
|
||||
int n_diverted; /* No. of statements diverted */
|
||||
int n_undiverted; /* No. of statements not diverted */
|
||||
int active; /* Is filter active */
|
||||
@ -258,7 +258,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
REGEXHINT_SESSION *my_session = (REGEXHINT_SESSION *) session;
|
||||
my_session->down = *downstream;
|
||||
|
@ -77,7 +77,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -121,7 +121,7 @@ typedef struct
|
||||
typedef struct
|
||||
{
|
||||
int active;
|
||||
DOWNSTREAM down;
|
||||
MXS_DOWNSTREAM down;
|
||||
char *filename; /* The session-specific log file name */
|
||||
FILE *fp; /* The session-specific log file */
|
||||
const char *remote;
|
||||
@ -483,7 +483,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
QLA_SESSION *my_session = (QLA_SESSION *) session;
|
||||
|
||||
|
@ -44,7 +44,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -72,7 +72,7 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down; /* The downstream filter */
|
||||
MXS_DOWNSTREAM down; /* The downstream filter */
|
||||
SPINLOCK lock;
|
||||
int no_change; /* No. of unchanged requests */
|
||||
int replacements; /* No. of changed requests */
|
||||
@ -308,7 +308,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
REGEX_SESSION *my_session = (REGEX_SESSION *) session;
|
||||
my_session->down = *downstream;
|
||||
|
@ -101,8 +101,8 @@ static MXS_FILTER *createInstance(const char* name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, UPSTREAM *upstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_UPSTREAM *upstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static int clientReply(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
@ -133,8 +133,8 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down; /* The downstream filter */
|
||||
UPSTREAM up; /* The upstream filter */
|
||||
MXS_DOWNSTREAM down; /* The downstream filter */
|
||||
MXS_UPSTREAM up; /* The upstream filter */
|
||||
int active; /* filter is active? */
|
||||
bool use_ok;
|
||||
int client_multistatement;
|
||||
@ -631,7 +631,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
TEE_SESSION *my_session = (TEE_SESSION *) session;
|
||||
my_session->down = *downstream;
|
||||
@ -646,7 +646,7 @@ setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *dow
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, UPSTREAM *upstream)
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_UPSTREAM *upstream)
|
||||
{
|
||||
TEE_SESSION *my_session = (TEE_SESSION *) session;
|
||||
my_session->up = *upstream;
|
||||
|
@ -34,7 +34,7 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PAR
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
static uint64_t getCapabilities(void);
|
||||
@ -57,8 +57,8 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down;
|
||||
int count;
|
||||
MXS_DOWNSTREAM down;
|
||||
int count;
|
||||
} TEST_SESSION;
|
||||
|
||||
/**
|
||||
@ -184,7 +184,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
TEST_SESSION *my_session = (TEST_SESSION *)session;
|
||||
|
||||
|
@ -52,8 +52,8 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PARAM
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, UPSTREAM *upstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_UPSTREAM *upstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static int clientReply(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
@ -99,8 +99,8 @@ typedef struct topnq
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down;
|
||||
UPSTREAM up;
|
||||
MXS_DOWNSTREAM down;
|
||||
MXS_UPSTREAM up;
|
||||
int active;
|
||||
char *clientHost;
|
||||
char *userName;
|
||||
@ -426,7 +426,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
TOPN_SESSION *my_session = (TOPN_SESSION *) session;
|
||||
|
||||
@ -442,7 +442,7 @@ setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *dow
|
||||
* @param upstream The upstream filter or session.
|
||||
*/
|
||||
static void
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, UPSTREAM *upstream)
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_UPSTREAM *upstream)
|
||||
{
|
||||
TOPN_SESSION *my_session = (TOPN_SESSION *) session;
|
||||
|
||||
|
@ -79,8 +79,8 @@ static MXS_FILTER *createInstance(const char *name, char **options, CONFIG_PAR
|
||||
static MXS_FILTER_SESSION *newSession(MXS_FILTER *instance, SESSION *session);
|
||||
static void closeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, UPSTREAM *upstream);
|
||||
static void setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_DOWNSTREAM *downstream);
|
||||
static void setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, MXS_UPSTREAM *upstream);
|
||||
static int routeQuery(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static int clientReply(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, GWBUF *queue);
|
||||
static void diagnostic(MXS_FILTER *instance, MXS_FILTER_SESSION *fsession, DCB *dcb);
|
||||
@ -116,8 +116,8 @@ typedef struct
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
DOWNSTREAM down;
|
||||
UPSTREAM up;
|
||||
MXS_DOWNSTREAM down;
|
||||
MXS_UPSTREAM up;
|
||||
int active;
|
||||
char *clientHost;
|
||||
char *userName;
|
||||
@ -392,7 +392,7 @@ freeSession(MXS_FILTER *instance, MXS_FILTER_SESSION *session)
|
||||
* @param downstream The downstream filter or router.
|
||||
*/
|
||||
static void
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *downstream)
|
||||
setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_DOWNSTREAM *downstream)
|
||||
{
|
||||
TPM_SESSION *my_session = (TPM_SESSION *)session;
|
||||
|
||||
@ -408,7 +408,7 @@ setDownstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, DOWNSTREAM *dow
|
||||
* @param upstream The upstream filter or session.
|
||||
*/
|
||||
static void
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, UPSTREAM *upstream)
|
||||
setUpstream(MXS_FILTER *instance, MXS_FILTER_SESSION *session, MXS_UPSTREAM *upstream)
|
||||
{
|
||||
TPM_SESSION *my_session = (TPM_SESSION *)session;
|
||||
|
||||
|
Reference in New Issue
Block a user