[SERVER-15570] Pluggable storage engine and TTL? Created: 08/Oct/14  Updated: 04/Jun/16  Resolved: 14/Oct/14

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: None
Fix Version/s: 2.7.8

Type: Improvement Priority: Major - P3
Reporter: Hannes Magnusson Assignee: Max Hirschhorn
Resolution: Done Votes: 0
Labels: 28qa
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-16749 Unhandled DBException in TTLMonitor t... Closed
is related to SERVER-13635 Clean up the storage abstraction layer Closed
is related to SERVER-14378 Build replacements for system.indexes... Closed
Tested
Participants:

 Description   

Will TTL indexes be supported by other storage engines?
While reviewing totally different things I came across:

db.query( dbName + ".system.indexes" ,

in ttl.cpp, which I believe will not work on non-mmap_v1 storage engines.



 Comments   
Comment by Githook User [ 14/Oct/14 ]

Author:

{u'username': u'visemet', u'name': u'Max Hirschhorn', u'email': u'max.hirschhorn@mongodb.com'}

Message: SERVER-15570 Avoid querying system.indexes in ttl.cpp.

Changed so that the TTL indexes are processed in multiple phases:

  • Acquire an IS-mode lock on the database and find all of the
    TTL indexes

For each TTL index,

  • Acquire an IX-mode lock on the collection and delete all of the
    expired documents

Also avoid checking `userFlags` of collection stats in TTL index
tests since it is not set by some storage engines.
Branch: master
https://github.com/mongodb/mongo/commit/1a44dc6a150524de75dd46c8dc464c7182a37389

Generated at Thu Feb 08 03:38:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.