While the server writes the response to Store, the client side may
synchronously abort the entry. This happens, for example, when the
server receives a 304 response and handleIMSReply calls
sendClientOldEntry, which calls storeUnregister with our entry,
resulting in CheckQuickAbort.
Once server store write returns, if the server is done, it calls
FwdState::completed(). At that time, the server does not know that (and
should not care whether) the entry was aborted. Thus, we need to handle
aborted entries in FwdState::completed.
This is a Measurement Factory project.
flags.forward_completed = 1;
+ if (EBIT_TEST(entry->flags, ENTRY_ABORTED)) {
+ debugs(17, 3, HERE << "entry aborted");
+ return ;
+ }
+
#if URL_CHECKSUM_DEBUG
entry->mem_obj->checkUrlChecksum();
void
FwdState::complete()
{
- assert(entry->store_status == STORE_PENDING);
debugs(17, 3, HERE << entry->url() << "\n\tstatus " << entry->getReply()->sline.status );
#if URL_CHECKSUM_DEBUG
{
StoreEntry *e = entry;
http_status s;
+
+ if (EBIT_TEST(e->flags, ENTRY_ABORTED)) {
+ debugs(17, 3, HERE << "entry aborted");
+ return 0;
+ }
+
assert(e->store_status == STORE_PENDING);
assert(e->mem_obj);
#if URL_CHECKSUM_DEBUG