start refactor, reduce number of message records.