[SPARK-3562]Periodic cleanup event logs

link #2391 
There isn't a need to synchronize on `applications` (here nor in the other method). The idea is that you create the new list and atomically replace the old one (note how it's `volatile`).