[ https://issues.apache.org/jira/browse/GEODE-8991?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17335947#comment-17335947 ]
ASF GitHub Bot commented on GEODE-8991: --------------------------------------- pdxcodemonkey edited a comment on pull request #798: URL: https://github.com/apache/geode-native/pull/798#issuecomment-829648077 After a little debugging on Windows, we saw the code throwing from this block ``` if (bytes_read == 0) { auto elapsedTime = std::chrono::duration<double, std::micro>( std::chrono::system_clock::now() - beforeReadPoint); if (elapsedTime < timeout) { LOGDEBUG("Throwing an IO exception"); socket_.cancel(); // Get the abort io_context_.restart(); io_context_.run(); throw boost::system::system_error{boost::asio::error::broken_pipe}; } ``` in TcpConn::receive_nothrowiftimeout. Here's the callstack: ``` pivotal-gemfire.dll!apache::geode::client::TcpConn::receive(char * buff, unsigned __int64 len, std::chrono::duration<__int64,std::ratio<1,1000> > timeout, bool throwTimeoutException) Line 233 at c:\users\bblake\src\geode-native\cppcache\src\tcpconn.cpp(233) pivotal-gemfire.dll!apache::geode::client::TcpConn::receive(char * buff, unsigned __int64 len, std::chrono::duration<__int64,std::ratio<1,1000> > timeout) Line 186 at c:\users\bblake\src\geode-native\cppcache\src\tcpconn.cpp(186) pivotal-gemfire.dll!apache::geode::client::TcrConnection::receiveData(char * buffer, unsigned __int64 length, std::chrono::duration<__int64,std::ratio<1,1000000> > timeout) Line 495 at c:\users\bblake\src\geode-native\cppcache\src\tcrconnection.cpp(495) pivotal-gemfire.dll!apache::geode::client::TcrConnection::readMessage(unsigned __int64 * recvLen, std::chrono::duration<__int64,std::ratio<1,1000000> > receiveTimeoutSec, bool doHeaderTimeoutRetries, apache::geode::client::ConnErrType * opErr, bool isNotificationMessage, int request) Line 650 at c:\users\bblake\src\geode-native\cppcache\src\tcrconnection.cpp(650) pivotal-gemfire.dll!apache::geode::client::TcrConnection::receive(unsigned __int64 * recvLen, apache::geode::client::ConnErrType * opErr, std::chrono::duration<__int64,std::ratio<1,1000000> > receiveTimeoutSec) Line 634 at c:\users\bblake\src\geode-native\cppcache\src\tcrconnection.cpp(634) pivotal-gemfire.dll!apache::geode::client::TcrEndpoint::receiveNotification(std::atomic<bool> & isRunning) Line 556 at c:\users\bblake\src\geode-native\cppcache\src\tcrendpoint.cpp(556) pivotal-gemfire.dll!apache::geode::client::Task<apache::geode::client::TcrEndpoint>::svc() Line 79 at c:\users\bblake\src\geode-native\cppcache\src\task.hpp(79) pivotal-gemfire.dll!std::_Invoker_pmf_pointer::_Call<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>(void(apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)() _Pmf, apache::geode::client::Task<apache::geode::client::TcrEndpoint> * && _Arg1) pivotal-gemfire.dll!std::invoke<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>(void(apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)() && _Obj, apache::geode::client::Task<apache::geode::client::TcrEndpoint> * && <_Args_0>) pivotal-gemfire.dll!std::_LaunchPad<std::unique_ptr<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>,std::default_delete<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *> > > >::_Execute<0,1>(std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *> & _Tup, std::integer_sequence<unsigned __int64,0,1> __formal) Line 239 at c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.16.27023\include\thr\xthread(239) pivotal-gemfire.dll!std::_LaunchPad<std::unique_ptr<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>,std::default_delete<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *> > > >::_Run(std::_LaunchPad<std::unique_ptr<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>,std::default_delete<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *> > > > * _Ln) Line 245 at c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.16.27023\include\thr\xthread(245) pivotal-gemfire.dll!std::_LaunchPad<std::unique_ptr<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *>,std::default_delete<std::tuple<void (__cdecl apache::geode::client::Task<apache::geode::client::TcrEndpoint>::*)(void),apache::geode::client::Task<apache::geode::client::TcrEndpoint> *> > > >::_Go() Line 231 at c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.16.27023\include\thr\xthread(231) pivotal-gemfire.dll!std::_Pad::_Call_func(void * _Data) Line 209 at c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.16.27023\include\thr\xthread(209) ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org > Cached regions are not cleaned up whenever the connection to the cluster is > lost > -------------------------------------------------------------------------------- > > Key: GEODE-8991 > URL: https://issues.apache.org/jira/browse/GEODE-8991 > Project: Geode > Issue Type: Bug > Components: native client > Affects Versions: 1.15.0 > Reporter: Mario Salazar de Torres > Assignee: Mario Salazar de Torres > Priority: Major > Labels: pull-request-available > > Under a cluster restart scenario it can't be guaranteed that all the entries > that existed before, exist after the restart. Hence if geode-native client > has any cached region registered it should be cleared after the connection is > lost towards the cluster in order to ensure cache consistency. > This is happenig in the case of the Java client, as described in this part of > the documentation: > [https://geode.apache.org/docs/guide/12/developing/events/how_client_server_distribution_works.html#how_client_server_distribution_works__section_928BB60066414BEB9FAA7FB3120334A3] > However, this is not the case for the native client -- This message was sent by Atlassian Jira (v8.3.4#803005)