Drizzled Public API Documentation
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
query_log.h
1
/* - mode: c; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
*
4
* Copyright 2011 Daniel Nichter
5
*
6
* This program is free software: you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation, either version 3 of the License, or
9
* (at your option) any later version.
10
*
11
* This program is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
15
*
16
* You should have received a copy of the GNU General Public License
17
* along with this program. If not, see <http://www.gnu.org/licenses/>.
18
*/
19
20
#pragma once
21
22
#include <drizzled/plugin/event_observer.h>
23
#include "file.h"
24
#include "
event.h
"
25
26
namespace
drizzled {
27
namespace
plugin {
28
43
class
QueryLog
:
public
drizzled::plugin::EventObserver
44
{
45
public
:
46
QueryLog
(
bool
enabled,
QueryLoggerFile
*logger_file);
47
48
void
registerSessionEventsDo(
Session
&session,
EventObserverList
&observers);
49
bool
observeEventDo(
EventData
&);
50
bool
afterStatement
(
AfterStatementEventData
&data);
51
56
bool
sysvar_enabled
;
57
bool
sysvar_file_enabled;
58
std::string sysvar_file;
59
uint32_constraint
sysvar_threshold_execution_time;
60
uint32_constraint
sysvar_threshold_lock_time;
61
uint32_constraint
sysvar_threshold_rows_examined;
62
uint32_constraint
sysvar_threshold_rows_sent;
63
uint32_constraint
sysvar_threshold_tmp_tables;
64
uint32_constraint
sysvar_threshold_warnings;
65
uint32_constraint
sysvar_threshold_session_time;
66
67
private
:
68
QueryLoggerFile
*_logger_file;
69
event_t
_event;
70
};
71
72
}
/* namespace plugin */
73
}
/* namespace drizzled */
plugin
query_log
query_log.h
Generated on Mon Jun 10 2013 09:48:21 for drizzle by
1.8.1.2