setWithTtl

suspend fun setWithTtl(key: CacheableInput, value: Any?, ttl: Duration)

Thread-safe write with TTL. The entry will be evicted on the next read after ttl has elapsed since this write.