percona-server
percona-server copied to clipboard
Add thd_wait_begin & thd_wait_end call for BINLOG dump
To decrease the active thread count under thread pool mode, else active_thread_pool may not be zero for specific thread group
Can you elaborate? Why binlog dump thread should not count towards thread pool group size? And if it should not, perhaps it should be implemented through checking the thread type, as thd_wait_begin/end has different semantics?
if requests arrived and there is now active thread (active_thread_count = 0), thread pool will create a new worker for new message right now. But if the binlog dump thread is running (it will never return unless binlog dump end), the active_thread_count will never be 0, and there will be no worker thread for newly arrived requests.
thd_wait_begin means that I am waiting io resource, don't think I am a active thread for other requests.