Refactor how we aquire the jwt token for the local user. (only fetch it
once) The local jwt token needs to be aquired via the right endpoint. The endpoint defines how our rtcBackendIdentity is computed. Based on us using sticky events or state events we also need to use the right endpoint. This cannot be done generically in the connection manager. The jwt token now is computed in the localTransport and the resolved sfu config is passed to the connection manager. Add JWT endpoint version and SFU config support Pin matrix-js-sdk to a specific commit and update dev auth image tag. Propagate SFU config and JWT endpoint choice through local transport, ConnectionManager and Connection; add JwtEndpointVersion enum and LocalTransportWithSFUConfig type. Add NO_MATRIX_2 auth error and locale string, thread rtcBackendIdentity through UI props, and include related test, CSS and minor imports updates
This commit is contained in:
@@ -13,6 +13,7 @@ import {
|
||||
type Room as LivekitRoom,
|
||||
} from "livekit-client";
|
||||
import { observeParticipantEvents } from "@livekit/components-core";
|
||||
import { type CallMembership } from "matrix-js-sdk/lib/matrixrtc/CallMembership";
|
||||
|
||||
import { type ObservableScope } from "./ObservableScope.ts";
|
||||
import {
|
||||
@@ -75,6 +76,7 @@ export class UserMedia {
|
||||
this.scope,
|
||||
this.id,
|
||||
this.userId,
|
||||
this.rtcMembership,
|
||||
this.participant.value$,
|
||||
this.encryptionSystem,
|
||||
this.livekitRoom$,
|
||||
@@ -89,6 +91,7 @@ export class UserMedia {
|
||||
this.scope,
|
||||
this.id,
|
||||
this.userId,
|
||||
this.rtcMembership,
|
||||
this.participant.value$,
|
||||
this.encryptionSystem,
|
||||
this.livekitRoom$,
|
||||
@@ -140,6 +143,7 @@ export class UserMedia {
|
||||
scope,
|
||||
`${this.id}:${key}`,
|
||||
this.userId,
|
||||
this.rtcMembership,
|
||||
p,
|
||||
this.encryptionSystem,
|
||||
this.livekitRoom$,
|
||||
@@ -191,6 +195,8 @@ export class UserMedia {
|
||||
private readonly scope: ObservableScope,
|
||||
public readonly id: string,
|
||||
private readonly userId: string,
|
||||
// TODO evaluate if this should just be the rtcBackendIdentity
|
||||
private readonly rtcMembership: CallMembership,
|
||||
private readonly participant: TaggedParticipant,
|
||||
private readonly encryptionSystem: EncryptionSystem,
|
||||
private readonly livekitRoom$: Behavior<LivekitRoom | undefined>,
|
||||
|
||||
Reference in New Issue
Block a user