Metadata: creation timestamp and/or modification timestamp?

#1
I have a requirement: when returning an object from cache (vs the live backend) I should provide a debug information which includes the timestamp when the object was placed into the cache.

To my surprise, I cannot find this timestamp in the object metadata. TTL is there, but not the timestamp from which to compute that TTL.

Did I miss something, or should I attach the timestamp to the object metadata explicitly?
 

admin

Administrator
#1
Hi Vladimir,

No, you didn't miss anything--the internal stored by the service is deliberately lean for the sake of efficiency. As you've already noticed, the object's original TTL is tracked, but that's mainly so that it can be reset back to its original value if you're using sliding timeouts. The creation timestamp is not stored.

So yes, you'll need to track the creation time explicitly, either directly on your object or in the ObjectMetadata's IndexCollection.
 
Top