keep track of messages and aggregate them