| 1439 | } |
| 1440 | |
| 1441 | void ImpalaServer::AddSessionToConnection( |
| 1442 | const TUniqueId& session_id, SessionState* session) { |
| 1443 | const TUniqueId& connection_id = ThriftServer::GetThreadConnectionId(); |
| 1444 | { |
| 1445 | lock_guard<mutex> l(connection_to_sessions_map_lock_); |
| 1446 | connection_to_sessions_map_[connection_id].insert(session_id); |
| 1447 | } |
| 1448 | |
| 1449 | std::lock_guard<std::mutex> session_lock(session->lock); |
| 1450 | if (session->connections.empty()) { |
| 1451 | // This session was previously disconnected but now has an associated |
| 1452 | // connection. It should no longer be considered for the disconnected timeout. |
| 1453 | UnregisterSessionTimeout(FLAGS_disconnected_session_timeout); |
| 1454 | } |
| 1455 | session->connections.insert(connection_id); |
| 1456 | } |
| 1457 | |
| 1458 | void ImpalaServer::PingImpalaHS2Service(TPingImpalaHS2ServiceResp& return_val, |
| 1459 | const TPingImpalaHS2ServiceReq& req) { |
no test coverage detected