You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
m_commands, this variable will still have the previously select(call by unprotected_select()) command
even if commands.pop(), this variable m_commandspushed again (by unprotected_send)
also, m_buffer have duplicate data..
"SELECT" cmd sended twice, so callback data can be weired.. (even if reconnecting successful) 🙀
after try_commit() end of reconnect(), some commands request & response can pushed
but reply is not a current callback, the callback is previous old data when reconnecting (by re_select functions called)
solving problem
I suggest this code:
re_auth(); // => m_commands pushedresend_failed_commands(); // build buffer from old command and m_commands pushedre_select(); // build buffer from this new one!try_commit();
problem context
0. a client have two database index, so need to re_select()
the problem is here.
cpp_redis/sources/core/client.cpp
Line 330 in d1fc9c7
cpp_redis/sources/core/client.cpp
Lines 433 to 482 in d1fc9c7
cpp_redis/sources/core/client.cpp
Lines 1949 to 1958 in d1fc9c7
cpp_redis/sources/core/client.cpp
Lines 194 to 198 in d1fc9c7
m_commands
is not empty, so ...cpp_redis/sources/core/client.cpp
Lines 308 to 327 in d1fc9c7
m_commands
, this variable will still have the previously select(call byunprotected_select()
) commandeven if
commands.pop()
, this variablem_commands
pushed again (byunprotected_send
)also,
m_buffer
have duplicate data.."SELECT" cmd sended twice, so callback data can be weired.. (even if reconnecting successful) 🙀
but reply is not a current callback, the callback is previous old data when reconnecting (by re_select functions called)
solving problem
I suggest this code:
original code:
cpp_redis/sources/core/client.cpp
Lines 478 to 481 in d1fc9c7
The text was updated successfully, but these errors were encountered: