~LatencyAwarePolicyTest() {
    stop_query_execution();
    uv_mutex_destroy(&lock_);
    uv_cond_destroy(&condition_);

    test_utils::CassFuturePtr close_future(cass_session_close(session_.get()));
    cass_future_wait(close_future.get());
  }
Exemple #2
0
SingleSessionTest::~SingleSessionTest() {
  if (session) {
    CassFuturePtr close_future(cass_session_close(session));
    cass_future_wait(close_future.get());
  }
  if (ssl) {
    cass_ssl_free(ssl);
  }
}
Exemple #3
0
/**
 * Close a session
 *
 * @param session Session to close
 */
static void close_session(void* session) {
  test_utils::CassFuturePtr close_future(cass_session_close(static_cast<CassSession*>(session)));
  test_utils::wait_and_check_error(close_future.get(), 20 * test_utils::ONE_SECOND_IN_MICROS);
}
Exemple #4
0
 /**
  * Close the session
  */
 void close_session() {
   if (session_) {
     test_utils::CassFuturePtr close_future(cass_session_close(session_.get()));
     cass_future_wait(close_future.get());
   }
 }
Exemple #5
0
CassFuture* cass_session_close(CassSession* session) {
  cass::SessionFuture::Ptr close_future(new cass::SessionFuture());
  session->close_async(close_future);
  close_future->inc_ref();
  return CassFuture::to(close_future.get());
}