1 videoroom per user vs 1 videoroom for all users

I’m using Janus videoroom to record user streams. There are only publishers (no subscribers). Recording is enabled.

I can create 1 videoroom per user, resulting in n videorooms if I have n users. Or, I can create only 1 room for all users so they all publish to the same room.

Which way is more efficient (less resource intensive)? I’m expecting 1k - 2k users (publishers) per project on production.

Here’s a code snippet the client uses to publish.

videoRoomHandle.createOffer({
    media: mediaSettings,
    success: (jsep) => {
        Janus.debug('Got publisher SDP!');
        Janus.debug(jsep);

        const publish = {
            request: 'configure',
            audio: true,
            video: true,
            videocodec: 'h264',
            record: true,
            filename: filename,
        };

        videoRoomHandle.send({ message: publish, jsep: jsep });
    },
    error: (error) => {
        Janus.error('WebRTC error:', error);
    },
});

A separate room per each user is probably better, since if you use a single room, all users in that room will be notified when someone else joins and publishes, which is probably not what you want (and can be a huge signalling traffic overhad too).

Got it. Thank you for the quick response!