Skip to content

Commit

Permalink
Get rid of not implemented SESSION_GTIDS_TRACKER
Browse files Browse the repository at this point in the history
One less new/delete per connection.

Part of MDEV-14984 - regression in connect performance
  • Loading branch information
svoj committed May 3, 2019
1 parent 2be28a9 commit 55bdd7f
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 17 deletions.
16 changes: 0 additions & 16 deletions sql/session_tracker.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,20 +34,6 @@ void State_tracker::mark_as_changed(THD *thd, LEX_CSTRING *tracked_item_name)
}


class Not_implemented_tracker : public State_tracker
{
public:
bool enable(THD *thd)
{ return false; }
bool update(THD *, set_var *)
{ return false; }
bool store(THD *, String *)
{ return false; }
void mark_as_changed(THD *, LEX_CSTRING *tracked_item_name)
{}

};

/**
Session_sysvars_tracker
Expand Down Expand Up @@ -1443,8 +1429,6 @@ void Session_tracker::enable(THD *thd)
new (std::nothrow) Current_schema_tracker;
m_trackers[SESSION_STATE_CHANGE_TRACKER]=
new (std::nothrow) Session_state_change_tracker;
m_trackers[SESSION_GTIDS_TRACKER]=
new (std::nothrow) Not_implemented_tracker;
m_trackers[TRANSACTION_INFO_TRACKER]=
new (std::nothrow) Transaction_state_tracker;

Expand Down
1 change: 0 additions & 1 deletion sql/session_tracker.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ enum enum_session_tracker
SESSION_SYSVARS_TRACKER, /* Session system variables */
CURRENT_SCHEMA_TRACKER, /* Current schema */
SESSION_STATE_CHANGE_TRACKER,
SESSION_GTIDS_TRACKER, /* Tracks GTIDs */
TRANSACTION_INFO_TRACKER, /* Transaction state */
SESSION_TRACKER_END /* must be the last */
};
Expand Down

0 comments on commit 55bdd7f

Please sign in to comment.