As described in Section 6.7, you create expiration policies and associate them with caching rules to refresh content from the origin server.
Even with expiration policies, it is often difficult to predict when exactly content becomes stale.
As an alternative, Oracle Web Cache provides mechanisms for explicitly invalidating content when an administrator or application knows that such content has become stale.
With invalidation, Oracle Web Cache marks objects as invalid.
For more information about using ESI invalidation, see Section 11.3.
Response header invalidation is Oracle Web Cache functionality that enables an origin server to return a transactional response whose response body contains something other than HTML.
When objects are marked as invalid and a client requests them, they are removed and then refreshed with new content from the origin servers.
You can choose to remove and refresh invalid objects immediately, or base the removal and refresh on the current load of the origin servers.
Oracle Web Cache supports the following forms of invalidation: and provides a useful way for origin servers to "piggyback" invalidation messages on HTTP responses sent to Oracle Web Cache.
Specifically, origin servers embed an XML invalidation document within the HTML of the response body using ESI tags.
For instance, when a customer purchases a vegetarian cookbook on an e-commerce site, the confirmation response could contain instructions for invalidating all catalog pages related to the book, its author and vegetables.The ability to send invalidation message inline reduces the connection overhead associated with sending out-of-band invalidations and is a useful tool for ESI developers.