MCPcopy Create free account
hub / github.com/apache/arrow / Forget

Method Forget

cpp/src/arrow/filesystem/azurefs.cc:1700–1714  ·  view source on GitHub ↗

\brief Prevent any release attempts in the destructor. When it's known they would certainly fail. \see LeaseGuard::BreakBeforeDeletion()

Source from the content-addressed store, hash-verified

1698 /// When it's known they would certainly fail.
1699 /// \see LeaseGuard::BreakBeforeDeletion()
1700 ARROW_NOINLINE void Forget() {
1701 if (!PendingRelease()) {
1702 release_attempt_pending_ = false;
1703 return;
1704 }
1705 release_attempt_pending_ = false;
1706 // Remember the latest known expiry time so we can gracefully handle lease
1707 // acquisition failures by waiting until the latest forgotten lease.
1708 auto latest = latest_known_expiry_time_.load(std::memory_order_relaxed);
1709 while (
1710 latest < break_or_expires_at_ &&
1711 !latest_known_expiry_time_.compare_exchange_weak(latest, break_or_expires_at_)) {
1712 }
1713 DCHECK_GE(latest_known_expiry_time_.load(), break_or_expires_at_);
1714 }
1715
1716 ARROW_NOINLINE static void WaitUntilLatestKnownExpiryTime() {
1717 auto remaining_time = latest_known_expiry_time_.load() - SteadyClock::now();

Callers 2

RenameContainerFunction · 0.80
MovePathWithDataLakeAPIFunction · 0.80

Calls 1

loadMethod · 0.45

Tested by

no test coverage detected