BSD style: see
license.txt
July 2004: Initial release
Kris
- class CacheInvalidator : NetworkClient ¶#
-
Utility class to invalidate specific cache entries across a
network. Any active CacheInvalidatee objects listening upon
the channel specified for this class will "wake up" whenever
the invalidate() method is invoked.
- this(ICluster cluster, char[] channel) ¶#
-
Construct an invalidator on the specified channel. Only
those CacheInvalidatee instances configured for the same
channel will be listening to this invalidator.
- void invalidate(char[] key, Time timeLimit = Time.max) ¶#
-
Invalidate all network cache instances on this channel
using the specified key. When 'timeLimit' is specified,
only those cache entries with a time lesser or equal to
that specified will be removed. This is often useful if
you wish to avoid invalidating a cache (local or remote)
that has just been updated; simply pass the time value
of the 'old' IMessage as the argument.
Note that this is asynchronous! An invalidation is just
a request to remove the item within a short time period.
If you need the entry removed synchronously, you should
use the NetworkCache extract() method instead.
- class InvalidatorPayload : NetworkMessage [package] ¶#
-
- char[] key() ¶#
-
- void key(char[] key) ¶#
-
- void read(IReader input) [override] ¶#
-
Read our attributes, after telling our superclass to do
likewise. The order of this is important with respect to
inheritance, such that a subclass and superclass may be
populated in isolation where appropriate.
Note that we slice our text attribute, rather than copying
it. Since this class is temporal we can forego allocation
of memory, and just map it directly from the input buffer.
- void write(IWriter output) [override] ¶#
-