turn events into a persistent object with a length and limit the number of items it can contain