summaryrefslogtreecommitdiff
path: root/storage/perfschema/table_esms_by_digest.cc
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2019-12-10 15:35:00 +0100
committerSergei Golubchik <serg@mariadb.org>2020-03-10 19:24:22 +0100
commit0ea717f51a152afdb3791195c4a25ee0baa2faac (patch)
tree0eb10fc1413d1583ffdec2c18a66491d7befeec2 /storage/perfschema/table_esms_by_digest.cc
parentdfe6e914e58472159f34a8a4c9288ff61eac479f (diff)
downloadmariadb-git-0ea717f51a152afdb3791195c4a25ee0baa2faac.tar.gz
P_S 5.7.28
Diffstat (limited to 'storage/perfschema/table_esms_by_digest.cc')
-rw-r--r--storage/perfschema/table_esms_by_digest.cc17
1 files changed, 12 insertions, 5 deletions
diff --git a/storage/perfschema/table_esms_by_digest.cc b/storage/perfschema/table_esms_by_digest.cc
index 5295c29dc40..acb9e059711 100644
--- a/storage/perfschema/table_esms_by_digest.cc
+++ b/storage/perfschema/table_esms_by_digest.cc
@@ -26,7 +26,7 @@
*/
#include "my_global.h"
-#include "my_pthread.h"
+#include "my_thread.h"
#include "pfs_instr_class.h"
#include "pfs_column_types.h"
#include "pfs_column_values.h"
@@ -37,6 +37,7 @@
#include "pfs_visitor.h"
#include "table_esms_by_digest.h"
#include "pfs_digest.h"
+#include "field.h"
THR_LOCK table_esms_by_digest::m_table_lock;
@@ -48,8 +49,7 @@ table_esms_by_digest::m_share=
table_esms_by_digest::create,
NULL, /* write_row */
table_esms_by_digest::delete_all_rows,
- NULL, /* get_row_count */
- 1000, /* records */
+ table_esms_by_digest::get_row_count,
sizeof(PFS_simple_index),
&m_table_lock,
{ C_STRING_WITH_LEN("CREATE TABLE events_statements_summary_by_digest("
@@ -81,7 +81,8 @@ table_esms_by_digest::m_share=
"SUM_NO_INDEX_USED BIGINT unsigned not null,"
"SUM_NO_GOOD_INDEX_USED BIGINT unsigned not null,"
"FIRST_SEEN TIMESTAMP(0) NOT NULL default 0,"
- "LAST_SEEN TIMESTAMP(0) NOT NULL default 0)") }
+ "LAST_SEEN TIMESTAMP(0) NOT NULL default 0)") },
+ false /* perpetual */
};
PFS_engine_table*
@@ -97,6 +98,12 @@ table_esms_by_digest::delete_all_rows(void)
return 0;
}
+ha_rows
+table_esms_by_digest::get_row_count(void)
+{
+ return digest_max;
+}
+
table_esms_by_digest::table_esms_by_digest()
: PFS_engine_table(&m_share, &m_pos),
m_row_exists(false), m_pos(0), m_next_pos(0)
@@ -183,7 +190,7 @@ int table_esms_by_digest
if (unlikely(! m_row_exists))
return HA_ERR_RECORD_DELETED;
- /*
+ /*
Set the null bits. It indicates how many fields could be null
in the table.
*/