[ENG-10884](https://linear.app/comm/issue/ENG-10884/handle-localmessageinfo-when-restoring-on-secondary) and [ENG-10885](https://linear.app/comm/issue/ENG-10885/handle-localmessageinfo-when-restoring-on-primary).
Context is in the tasks.
Creating one diff because there is a lot of boilerplate, we're doing it many times, so saving some time in splitting this into smaller chunks and reviewing each one separately