Model cache management

Added logic for managing the size of the message cache kept in the backbone collection.