MemcachedTTLConverter
trait MemcachedTTLConverter
Value members
Concrete methods
Convert an optional Duration
to an int suitable for passing to Memcached.
Convert an optional Duration
to an int suitable for passing to Memcached.
From the Memcached protocol spec:
The actual value sent may either be Unix time (number of seconds since January 1, 1970, as a 32-bit value), or a number of seconds starting from current time. In the latter case, this number of seconds may not exceed 606024*30 (number of seconds in 30 days); if the number sent by a client is larger than that, the server will consider it to be real Unix time value rather than an offset from current time.
- Value Params
- ttl
optional TTL
- Returns
corresponding Memcached expiry