MCPcopy Create free account
hub / github.com/ceph/ceph / discard

Method discard

src/msg/async/AsyncConnection.cc:684–702  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

682}
683
684void AsyncConnection::DelayedDelivery::discard() {
685 stop_dispatch = true;
686 center->submit_to(center->get_id(),
687 [this]() mutable {
688 std::lock_guard<std::mutex> l(delay_lock);
689 while (!delay_queue.empty()) {
690 Message *m = delay_queue.front();
691 dispatch_queue->dispatch_throttle_release(
692 m->get_dispatch_throttle_size());
693 m->put();
694 delay_queue.pop_front();
695 }
696 for (auto i : register_time_events)
697 center->delete_time_event(i);
698 register_time_events.clear();
699 stop_dispatch = false;
700 },
701 true);
702}
703
704void AsyncConnection::DelayedDelivery::flush() {
705 stop_dispatch = true;

Callers 2

reset_sessionMethod · 0.45
session_resetMethod · 0.45

Calls 10

submit_toMethod · 0.80
delete_time_eventMethod · 0.80
get_idMethod · 0.45
emptyMethod · 0.45
frontMethod · 0.45
putMethod · 0.45
pop_frontMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected