Invalid cache entries on aborted requests #1081
Comments
We need to check This may also affect nginx; I'll check. |
I checked: this doesn't affect nginx. In nginx we check |
The fix is very simple:
|
Testing this is really annoying. I have a manual test set up, which works fine, but to test this properly we need a rate-limiting webserver and to do this on apache 2.2 we need to install other modules. I tried writing a shell script:
but couldn't get it to work reliably. Not sure why. |
re: simple fix: re: testing rate limiting |
Sorry - I meant #1066 instead of the ngx_pagespeed part of that |
@oschaaf yes, #1066 would make this easier to test. I tried doing it with PHP and couldn't pass flushes through; that seems to be why. @morlovich are you going to get a chance to look at #1066? You'd said you were interested in looking at it, but if not I can.
I don't think we can DCHECK, because we don't know how to tell that the download was aborted except in a server-specific way (apache: |
@jeffkaufman: "I don't think we can DCHECK, because we don't know how to tell that the download was aborted except in a server-specific way (apache: r->connection->aborted, nginx: don't receive last_buf)." perhaps somehow assuming failure in the recorder until success is explicitly indicated via an api call would help here? Though that might require an api change which might be too much. |
Maybe adding:
? |
So anyone working with |
@jeffkaufman yes, that would make it explicit, and would be easy maintenance-wise, which sounds great to me. |
Actually, what if I just do this as another (required) argument to
|
@jeffkaufman I think that would be even better. That would follow the Done(success) interface of the other classes more closely, which seems more natural. |
…note this and not record the truncated resource to cache. Fixes #1081 Nginx side of the change: apache/incubator-pagespeed-ngx#966
…note this and not record the truncated resource to cache. Fixes #1081 Nginx side of the change: apache/incubator-pagespeed-ngx#966
In debugging #1048 we found a case where we weren't handling IPRO recording properly. To reproduce:
The text was updated successfully, but these errors were encountered: