Page Speed Optimization Libraries  1.5.27.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Static Public Member Functions | Protected Member Functions
net_instaweb::SystemServerContext Class Reference

A server context with features specific to a PSOL port on a unix system. More...

#include "system_server_context.h"

Inheritance diagram for net_instaweb::SystemServerContext:
net_instaweb::ServerContext net_instaweb::ApacheServerContext

List of all members.

Public Member Functions

 SystemServerContext (SystemRewriteDriverFactory *driver_factory)
void FlushCacheIfNecessary ()
SystemRewriteOptionssystem_rewrite_options ()

Static Public Member Functions

static void InitStats (Statistics *statistics)

Protected Member Functions

virtual bool UpdateCacheFlushTimestampMs (int64 timestamp_ms)

Detailed Description

A server context with features specific to a PSOL port on a unix system.


Member Function Documentation

Implementations should call this method on every request, both for html and resources, to avoid serving stale resources.

Todo:
TODO(jmarantz): allow a URL-based mechanism to flush cache, even if we implement it by simply writing the cache.flush file so other servers can see it. Note that using shared-memory is not a great plan because we need the cache-invalidation to persist across server restart.
virtual bool net_instaweb::SystemServerContext::UpdateCacheFlushTimestampMs ( int64  timestamp_ms) [protected, virtual]

Flush the cache by updating the cache flush timestamp in the global options. This will change its signature, which is part of the cache key, and so all previously cached entries will be unreachable.

Returns true if it actually updated the timestamp, false if the existing cache flush timestamp was newer or the same as the one provided.

Subclasses which add aditional configurations need to override this method to additionally update the cache flush timestamp in those other configurations. See ApacheServerContext::UpdateCacheFlushTimestampMs where the separate SpdyConfig that mod_pagespeed uses when using SPDY also needs to have it's timestamp bumped.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines