add online statistics and new msg save mechanism