In by executing steps first for producer and then for consumer, successfully work. But When I disconnect producer and reconnect it, and only updating step3 for consumer with newProducerId doesnt work.
I thought by only changing producerId for consumer and calling .consume(newProducerId) will succesfully work, but it didnt. Can anybody tell me how I can reuse plainTransport for consumer?
when I say disconnecting producer;
I mean disconnection of producer (closing producer transport and producer.close())
So when I reconnect producer, I create new transport for it and then with new producer transport I call transport.produce(rtpSendParams)
Got it, it is not going to work like that because you are closing the producer transport.
So if you close only the producer and not transport then you should be able to consume that new producer by calling .consume on consuming end like you are doing now.
But if you need to close the producing transport then I guess you will have to alteast call .connect() with new remote ip and port, and then you can call .consume, if it doesn’t work then I am afraid you will have to create, connect, consume transport again on consuming end.