|
|
|
|
|
by FooBarWidget
4178 days ago
|
|
The first example looks nothing like parsing a specific cookie. It merely sanitizes the cookie headers a little, but it doesn't extract out a specific cookie to use as cache key. And both examples you link to remove cookies. That's not what we're after. We're after the extraction of a specific cookie without removing anything. It's also not marketing for a commercial product. The research is for an open source project, and the code is public and open source. The entire point of the blog post is to call for research participants who could not only test our ideas, but who could also point out anything we might have missed. |
|
You say you don't parse a specific cookie, but doesn't extract a specific cookie as a cache key? The blog post says the opposite:
> We modified Passenger to parse cookies, and to vary turbocache responses based on the value of this user_id cookie. We invoke Passenger like this: passenger start --vary-turbocache-by-cookie user_id
In other words: parse the user_id cookie.
The mentioned commit even adds a ~250 LoC file (ext/common/ServerKit/CookieUtils.h) to do cookie parsing: https://github.com/phusion/passenger/commit/a760649cd79fde43...
---
Anyway, what you're getting at is that Phusion only parses a certain value from the cookie and then uses it as a custom Vary header, whereas the examples I linked to clean up the Cookie header and then varies on that cleaned up Cookie header. That boils down to exactly the same thing.
P.S.: downvoting? Not very nice.