-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Index Maintenance, Querying
-
None
-
Fully Compatible
-
ALL
Issue Status as of December 30th, 2013
ISSUE SUMMARY
TTL indexes remove all documents before the current date due to non-numeric types supplied to expiresAfterSeconds being interpreted as 0.
USER IMPACT
Users who supply a non-numeric value to expiresAfterSeconds could have data deleted.
SOLUTION
Mongod will produce an error for TTL indexes created with a non-numeric value for expiresAfterSeconds.
WORKAROUNDS
Users should ensure their application does not pass non-numeric values for expiresAfterSeconds.
PATCHES
Production release v2.4.9 contains the fix for this issue, and production release v2.6.0 will contain the fix as well.
The query will delete everything before the current date as if the supplied expiresAfterSeconds was 0.