Merge pull request #3670 from element-hq/toger5/livekitAlias-debugging-info

Add livekitAlias debugging info
This commit is contained in:
Timo
2026-01-14 12:26:50 +01:00
committed by GitHub
5 changed files with 30 additions and 3 deletions

View File

@@ -117,6 +117,14 @@ export class Connection {
*/
public readonly remoteParticipants$: Behavior<RemoteParticipant[]>;
/**
* The alias of the LiveKit room.
*/
public get livekitAlias(): string | undefined {
return this._livekitAlias;
}
private _livekitAlias?: string;
/**
* Whether the connection has been stopped.
* @see Connection.stop
@@ -144,9 +152,10 @@ export class Connection {
this._state$.next(ConnectionState.FetchingConfig);
// We should already have this information after creating the localTransport.
// only call getSFUConfigWithOpenID for connections where we do not have a token yet. (existingJwtTokenData === undefined)
const { url, jwt } =
const { url, jwt, livekitAlias } =
this.existingSFUConfig ??
(await this.getSFUConfigForRemoteConnection());
this._livekitAlias = livekitAlias;
// If we were stopped while fetching the config, don't proceed to connect
if (this.stopped) return;