Stop write_fail actions from going to origin if parentage with go_direct=false
- Dominant language
- C++
- Stars
- 2k
- Forks
- 874
- Avg merge
- 6d 15h
- Merged PRs (30d)
- 46
Description
The way the current write_fail action code is written I believe it allows children caches of parents to bypass parents in the case where they are not able to obtain a write lock on an object. This would usually happen during a thundering herd event when an upstream origin has issues and so there is already one request waiting on a response, no headers have been received, so there is no object in cache but the write lock is blocked.
This prevents RWR from coalescing requests since there are no headers. There are already options to return a failure or stale in these instances however the default option appears to allow children caches to completely bypass their parents and go directly to the origin even if their parent line specifies go_direct=false. The write_lock failure should take parentage/go_direct into account since right now this is the only method I know of that will completely bypass parents
Contributor guide
Assessment
This issue has not been assessed yet.