Commit e499b25c authored by Sergei Golubchik's avatar Sergei Golubchik

cleanup: clarify ha_innobase::column_bitmaps_signal()

it was created to handle the case of the concurrent
inplace add index. So it should only work in that case,
otherwise it's doing server's job (marks virtual column dependencies)
and hides server's bugs. And it was redundant.
parent eaa87eb8
...@@ -5116,13 +5116,21 @@ ha_innobase::keys_to_use_for_scanning() ...@@ -5116,13 +5116,21 @@ ha_innobase::keys_to_use_for_scanning()
return(&key_map_full); return(&key_map_full);
} }
/** Ensure that indexed virtual columns will be computed. */ /****************************************************************//**
Ensure that indexed virtual columns will be computed.
Needs to be done for indexes that are being added with inplace ALTER
in a different thread, because from the server point of view these
columns are not yet indexed.
*/
void ha_innobase::column_bitmaps_signal() void ha_innobase::column_bitmaps_signal()
{ {
if (!table->vfield || table->current_lock != F_WRLCK) if (!table->vfield || table->current_lock != F_WRLCK)
return; return;
dict_index_t* clust_index= dict_table_get_first_index(m_prebuilt->table); dict_index_t* clust_index= dict_table_get_first_index(m_prebuilt->table);
if (!clust_index->online_log)
return;
uint num_v= 0; uint num_v= 0;
for (uint j = 0; j < table->s->virtual_fields; j++) for (uint j = 0; j < table->s->virtual_fields; j++)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment