def _startCollection(cls):
        "Periodically clean up old entries until the stop flag is set"

        while cls.__stopCollecting is not True:
            time.sleep(cls.collectionInterval)
            cls.collectAll()
Periodically clean up old entries until the stop flag is set
recipes/Python/442513_Caching_decorator_timeout_selective/recipe-442513.py