Custom SFU plugin - Issue with remote feed taking time to appear

Hey, I am currently developing a custom SFU similar to the videoroom plugin, but suited for my own special case.

I was able to successfully initiate a publisher peer connection from the Browser to Janus and subscriber peer connection from Janus to the browser.

However, I am experiencing an issue where the remote peer connection is successfully getting a remote video track but takes a while to display it in the browser. When inspecting stats in webrtc-internals on Chrome, I can clearly see rtp packets flowing except for a weird behavior where the codec section takes some time to appear and then the remote stream becomes visible on the page.

Am I missing something fundamental here?

I have attached a GIF hoping it’s visible and will make it more clear.

output-14

Nevermind, I figured out that I also need to send a FIR request asap.