From 2cd1ed9175e0aa57e3740e54d27377de21b331af Mon Sep 17 00:00:00 2001 From: Carlos Santos <4a.santos@gmail.com> Date: Mon, 23 Sep 2024 08:29:17 +0200 Subject: [PATCH] backend: Add support for partial recording download using range headers Refactor recording controller to include range parameter in getRecordingAsStream function --- openvidu-call-back/src/controllers/recording.controller.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openvidu-call-back/src/controllers/recording.controller.ts b/openvidu-call-back/src/controllers/recording.controller.ts index f769e2d2..05924d3d 100644 --- a/openvidu-call-back/src/controllers/recording.controller.ts +++ b/openvidu-call-back/src/controllers/recording.controller.ts @@ -83,7 +83,7 @@ export const streamRecording = async (req: Request, res: Response) => { try { logger.info(`Streaming recording ${recordingId}`); - const { fileSize, fileStream, start, end } = await recordingService.getRecordingAsStream(recordingId); + const { fileSize, fileStream, start, end } = await recordingService.getRecordingAsStream(recordingId, range); res.setHeader('Accept-Ranges', 'bytes');