Closed Bug 1009500 Opened 11 years ago Closed 11 years ago

HTTP cache v2: respect OPEN_BYPASS_IF_BUSY in the new cache

Categories

(Core :: Networking: Cache, defect)

defect
Not set
major

Tracking

()

RESOLVED FIXED
mozilla32

People

(Reporter: mayhemer, Assigned: mayhemer)

References

Details

Attachments

(1 file)

There are still scenarios the consumer using this flag can get blocked like: - channel 1 opens an entry - is given a new empty entry - entry is at WRITING state (bypasses any callbacks until write done/failed) - channel 1 is suspended - channel 2 opens the same entry, specifies OPEN_BYPASS_IF_BUSY - channel 1 is never resumed (the scenario waits for channel 2 to finish first) => channel 2 never gets it's cache entry and gets stuck
Yep!
Attached patch v1Splinter Review
- callbacks get in only via CacheEntry::AsyncOpen - all of them pass via CacheEntry::RememberCallback - when the state is detected to be WRITING/REVAL and BYPASS flag is set, immediately (from AsyncOpen) invoke with null/NOT_FOUND error at that method (and actually don't remember the callback) - test infra is added a new flag DONTFILL to bypass the metadata and data automatic write in OpenCallback js helper class - the test itself opens an entry but never writes/validates/closes it, the second open with BYPASS must be invoked then
Attachment #8421913 - Flags: review?(michal.novotny)
Attachment #8421913 - Flags: review?(michal.novotny) → review+
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla32
Depends on: 1027789
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: