Page Speed Optimization Libraries
1.13.35.1
|
#include "experiment_matcher.h"
Public Member Functions | |
virtual bool | ClassifyIntoExperiment (const RequestHeaders &headers, const UserAgentMatcher &matcher, RewriteOptions *options) |
virtual void | StoreExperimentData (int state, const StringPiece &url, int64 expiration_time_ms, ResponseHeaders *headers) |
Provides a way to replace the mapping of clients/sessions to experiments.
The default implementation of the experiment framework uses cookies to send clients to the same experiment consistently. This implementation can be overridden to divide clients/sessions into experiments using a different mechanism.
|
virtual |
Decides which experiment to place the current client/session into. Returns true if the mapping needs to be stored.
|
virtual |
Stores the client/session -> experiment mapping for the domain indicated by url. The experiment id is indicated by state. The default implementation stores this in a cookie in the response headers, setting it to expire at expiration_time_ms (specified as ms since the epoch).