-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
change lock status memory ordering, tag spans
This changes the memory ordering for the lock status load to `SeqCst` from `Relaxed` to eliminate a potential source of panics. Panics had the frames: ``` pingora_proxy::proxy_cache::<T>::handle_lock_status (proxy_cache.rs:748) pingora_proxy::proxy_cache::<T>::proxy_cache::{{closure}} (proxy_cache.rs:211) pingora_proxy::HttpProxy<T>::process_request::{{closure}} (lib.rs:509) pingora_proxy::HttpProxy<T>::process_new_http::{{closure}} (lib.rs:727) ``` which showed we were checking on the status of the lock, after waiting on it, and still seeing its status as waiting. The status is returned by value, so this is not a time-of-check to time-of-use problem, this is an inconsistency in how the lock status is managed. The change in memory order is mostly for the sake of this programmer's attempts to understand what is happening. This also completes a couple of TODOs to limit the wait period as well as tag the span with the lock status.
- Loading branch information
1 parent
5e3e774
commit e288bfe
Showing
4 changed files
with
28 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
30c624970d46b07efd110fcfb8dd0b6f9a099e2b | ||
2351cdf592f9986201d754e6ee1f37f493f69abb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters