🐛(backend) preserve recording metadata when updating room access

Updating room access rewrote the entire metadata payload, removing information
about active recordings. This caused the frontend to lose track of ongoing
recordings and could trigger 409 errors when attempting to start a new
recording.

Consolidate the duplicated metadata update logic into
`RoomManagement.update_metadata()` and preserve merge behavior instead of
overwriting the full metadata object.
This commit is contained in:
leo
2026-07-28 10:38:36 +02:00
committed by aleb_the_flash
parent 6a00d3d087
commit f4569c64e5
9 changed files with 125 additions and 123 deletions
@@ -13,8 +13,7 @@ import { useRoomContext } from '@livekit/components-react'
import { useRoomData } from './useRoomData'
/**
* Shape of the LiveKit room metadata blob pushed by the backend.
* Matches RoomManagement.update_metadata → {"configuration": room.configuration}
* The subset of LiveKit's room metadata this hook actually uses.
*/
type RoomLiveKitMetadata = {
configuration?: RoomConfiguration