Add qc_get_preparable_stmt

This function will return the preparable statement of a PREPARE
statement as a COM_QUERY GWBUF. That is, once obtained, the normal
query classifier functions can be used for obtaining information
about the preparable statement itself.
This commit is contained in:
Johan Wikman
2017-01-16 15:28:31 +02:00
parent 7fee90a399
commit e349319400
5 changed files with 97 additions and 2 deletions

View File

@ -96,7 +96,7 @@ int32_t qc_dummy_setup(const char* args)
return QC_RESULT_OK;
}
int qc_dummy_process_init(void)
int32_t qc_dummy_process_init(void)
{
return QC_RESULT_OK;
}
@ -105,7 +105,7 @@ void qc_dummy_process_end(void)
{
}
int qc_dummy_thread_init(void)
int32_t qc_dummy_thread_init(void)
{
return QC_RESULT_OK;
}
@ -114,6 +114,12 @@ void qc_dummy_thread_end(void)
{
}
int32_t qc_dummy_get_preparable_stmt(GWBUF* stmt, GWBUF** preparable_stmt)
{
*preparable_stmt = NULL;
return QC_RESULT_OK;
}
extern "C"
{
MXS_MODULE* MXS_CREATE_MODULE()
@ -138,6 +144,7 @@ extern "C"
qc_dummy_get_prepare_operation,
qc_dummy_get_field_info,
qc_dummy_get_function_info,
qc_dummy_get_preparable_stmt,
};
static MXS_MODULE info =