diff options
author | Marc Alff <marc.alff@oracle.com> | 2010-10-06 18:03:27 -0600 |
---|---|---|
committer | Marc Alff <marc.alff@oracle.com> | 2010-10-06 18:03:27 -0600 |
commit | d51cd894dac501d808da0c3bc08636f387014eb3 (patch) | |
tree | 1ae61e6cff185521683ed02b0ceefc681fb764e8 /storage/perfschema | |
parent | 985fa88f8b07743dd3a848c11bc1d93b826d3d62 (diff) | |
download | mariadb-git-d51cd894dac501d808da0c3bc08636f387014eb3.tar.gz |
Bug#57154 Rename THREADS.ID to THREADS.PROCESSLIST_ID in 5.5
This change is to align the 5.5 performance_schema.THREADS
table definition with the 5.6 performance_schema.THREADS table,
to facilitate the 5.5 -> 5.6 migration later.
In the table performance_schema.THREADS:
- renamed ID to PROCESSLIST_ID, removed not null
- changed NAME from varchar(64) to varchar(128)
to match the columns definitions from 5.6
Adjusted the test cases accordingly.
Note: this fix is for 5.5 only, to null merge into 5.6
Diffstat (limited to 'storage/perfschema')
-rw-r--r-- | storage/perfschema/table_threads.cc | 11 | ||||
-rw-r--r-- | storage/perfschema/table_threads.h | 4 |
2 files changed, 8 insertions, 7 deletions
diff --git a/storage/perfschema/table_threads.cc b/storage/perfschema/table_threads.cc index bba7806cab9..d9aa600a21e 100644 --- a/storage/perfschema/table_threads.cc +++ b/storage/perfschema/table_threads.cc @@ -34,13 +34,13 @@ static const TABLE_FIELD_TYPE field_types[]= { NULL, 0} }, { - { C_STRING_WITH_LEN("ID") }, + { C_STRING_WITH_LEN("PROCESSLIST_ID") }, { C_STRING_WITH_LEN("int(11)") }, { NULL, 0} }, { { C_STRING_WITH_LEN("NAME") }, - { C_STRING_WITH_LEN("varchar(64)") }, + { C_STRING_WITH_LEN("varchar(128)") }, { NULL, 0} } }; @@ -140,7 +140,7 @@ void table_threads::make_row(PFS_thread *pfs) } int table_threads::read_row_values(TABLE *table, - unsigned char *, + unsigned char *buf, Field **fields, bool read_all) { @@ -150,7 +150,8 @@ int table_threads::read_row_values(TABLE *table, return HA_ERR_RECORD_DELETED; /* Set the null bits */ - DBUG_ASSERT(table->s->null_bytes == 0); + DBUG_ASSERT(table->s->null_bytes == 1); + buf[0]= 0; for (; (f= *fields) ; fields++) { @@ -161,7 +162,7 @@ int table_threads::read_row_values(TABLE *table, case 0: /* THREAD_ID */ set_field_ulong(f, m_row.m_thread_internal_id); break; - case 1: /* ID */ + case 1: /* PROCESSLIST_ID */ set_field_ulong(f, m_row.m_thread_id); break; case 2: /* NAME */ diff --git a/storage/perfschema/table_threads.h b/storage/perfschema/table_threads.h index 9df323f6d82..fb239007069 100644 --- a/storage/perfschema/table_threads.h +++ b/storage/perfschema/table_threads.h @@ -36,7 +36,7 @@ struct row_threads { /** Column THREAD_ID. */ ulong m_thread_internal_id; - /** Column ID. */ + /** Column PROCESSLIST_ID. */ ulong m_thread_id; /** Column NAME. */ const char *m_name; @@ -79,7 +79,7 @@ private: /** Current row. */ row_threads m_row; - /** True is the current row exists. */ + /** True if the current row exists. */ bool m_row_exists; /** Current position. */ PFS_simple_index m_pos; |