Probably a bit offtopic, but interesting nevertheless.
In C++, each Worker represents a single operating systems process. Comunication is done over IPC, so their memory address are isolated, so it’s not possible to transfer info that can’t be serialized between them.
But, each Worker can host multiple Router instances, and all of them live in the same memory address, so transfer a Transport or RtpObserver object from one to another would be mostly remove it from a std Map in the source Router and add it to the Map in the destination Router, maybe with some additional (de)initialization calls. Am I right? (I’m lefting out transfer of Producers and Consumers for simplicity, probably transfer of Transports are just enough).
In addition to that, Rust implementation is using threads instead of processes, so all of them live in the same memory space and you could (in theory) also transfer Router instances. Also, with the Rust concept of ownership, it gets almost obvious that the transfer of the objects will invalidate any access to them in the original thread, being safe to do. Is this correct?
Is there any technical limitation (besides time, sponsorship, etc) that prevents do this? What would be the steps to achieve this?