Remove superfluous logging

Just because of a debug build you do not want the transaction
parser to log.
This commit is contained in:
Johan Wikman
2017-04-06 10:35:47 +03:00
parent 5998457142
commit 27e97a546d

View File

@ -22,6 +22,10 @@ namespace maxscale
#define TBP_EXPECT_TOKEN(string_literal) string_literal, (sizeof(string_literal) - 1) #define TBP_EXPECT_TOKEN(string_literal) string_literal, (sizeof(string_literal) - 1)
// For debugging purposes.
// #define TBP_LOG_UNEXPECTED_AND_EXHAUSTED
#undef TBP_LOG_UNEXPECTED_AND_EXHAUSTED
/** /**
* @class TrxBoundaryParser * @class TrxBoundaryParser
* *
@ -149,7 +153,7 @@ private:
void log_unexpected() void log_unexpected()
{ {
#ifdef SS_DEBUG #ifdef TBP_LOG_UNEXPECTED_AND_EXHAUSTED
MXS_NOTICE("Transaction tracking: In statement '%.*s', unexpected token at '%.*s'.", MXS_NOTICE("Transaction tracking: In statement '%.*s', unexpected token at '%.*s'.",
(int)m_len, m_pSql, (int)(m_pEnd - m_pI), m_pI); (int)m_len, m_pSql, (int)(m_pEnd - m_pI), m_pI);
#endif #endif
@ -157,7 +161,7 @@ private:
void log_exhausted() void log_exhausted()
{ {
#ifdef SS_DEBUG #ifdef TBP_LOG_UNEXPECTED_AND_EXHAUSTED
MXS_NOTICE("Transaction tracking: More tokens expected in statement '%.*s'.", (int)m_len, m_pSql); MXS_NOTICE("Transaction tracking: More tokens expected in statement '%.*s'.", (int)m_len, m_pSql);
#endif #endif
} }