-
Couldn't load subscription status.
- Fork 57
clarify timezone handling #46
Conversation
3.5/indexing-ttl.md Outdated
| * `2019-05-27T21:20:00.123-02:00`: May 27th 2019, 21:20:00.123, -02:00 offset from UTC time | ||
| | ||
| Using an invalid date string value in a document's TTL index attribute will prevent the document | ||
| from being inserted into the TTL index, so it will not be expired and removed automatically. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
neither be expired nor be removed automatically
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using an invalid date string value in a document's TTL index attribute will prevent the document from being inserted into the TTL index
Will this raise an error or it will be accepted as a successful operation?
Also, what if user tries to insert a document that have an already expired valid datetime string?
a) ArangoDB doesn't even insert it and returns no error.
b) ArangoDB doesn't insert it returns and error.
c) ArangoDB inserts the document and lets background job remove it on next iteration?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No error will be raised if a document is inserted with an invalid date string or with a date string value in the past.
Documents with invalid date string values will not be indexed, so they will not expire and not be removed automatically.
Documents with valid date string values that are in the past should be removed on the next run of the TTL background thread.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls. change that
| Just tried to confirm if it works. My server is in GMT+3 timezone. This is I've inserted 10 documents each having different datetime format in After inserting all 10 documents and waiting for TTL background thread kick in, only the first two are removed from collection. Rest of them still resides in collection. Is this expected behavior? |
| @ramazanpolat : can you try (there is a superfluous |
| @jsteemann Ok, I've updated datetime strings. Results: This is my server time: Although my server time is passed the |
| @ramazanpolat : if this is your server time as you stated: Then any documents with an expire time before Looking at the results you posted: they seem correct. Let me comment each line: |
Clarify how to use time-zoned values in the TTL index.