Skip to content

build(livekit): livekit/[email protected], [email protected], bypass guest lobby for dial-ins when using LK audio - #23535

Merged
prlanzarin merged 3 commits into
bigbluebutton:v3.0.x-releasefrom
prlanzarin:u30/fix/lk-dial-tu1
Jul 15, 2025
Merged

prlanzarin merged 3 commits into
bigbluebutton:v3.0.x-releasefrom
prlanzarin:u30/fix/lk-dial-tu1

Conversation

@prlanzarin

Copy link
Copy Markdown
Member

What does this PR do?

Closes Issue(s)

None

The LK integration currently does not supported guest lobbies for
dial-in/SIP endpoints. It'll be fixed somehow in the future, but right
now it's problematic.

Always bypass guest lobby for dial-in/SIP endpoints when LiveKit is the
meeting's audio bridge.
v2.19.0-beta.4
---
* fix(livekit): don't create RTC clients for non-BBB meetings
* fix(livekit): incorrect metadata override for external participants
@prlanzarin prlanzarin added this to the Release 3.0 milestone Jul 14, 2025
@coderabbitai

coderabbitai Bot commented Jul 14, 2025 •

Copy link
Copy Markdown
Contributor

Walkthrough

The changes introduce a new helper method, isUsingLiveKitAudio, to encapsulate the logic for determining if a meeting uses LiveKit for audio. The trait UserJoinedVoiceConfEvtMsgHdlr now extends HandlerHelpers and uses this new method to refine guest policy enforcement: dial-in users joining via LiveKit audio will not have the guest lobby enforced, while the original behavior is preserved for other dial-in users. Additionally, build scripts were updated to use newer versions of dependencies and repositories, specifically updating the SIP component version and the branch for a cloned repository.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant VoiceConfHandler as UserJoinedVoiceConfEvtMsgHdlr
    participant HandlerHelpers
    participant LiveMeeting

    User->>VoiceConfHandler: Join via dial-in
    VoiceConfHandler->>HandlerHelpers: isUsingLiveKitAudio(liveMeeting)
    HandlerHelpers-->>VoiceConfHandler: Boolean (is LiveKit audio?)
    VoiceConfHandler->>VoiceConfHandler: Set enforceGuestPolicy based on dialInEnforceGuestPolicy and isUsingLiveKitAudio
    alt enforceGuestPolicy is true
        VoiceConfHandler->>VoiceConfHandler: Enforce guest lobby
    else enforceGuestPolicy is false
        VoiceConfHandler->>VoiceConfHandler: Skip guest lobby enforcement
    end
Loading
✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@sonarqubecloud

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0ca152d and 9fb4f20.

📒 Files selected for processing (4)
  • akka-bbb-apps/src/main/scala/org/bigbluebutton/core/apps/voice/UserJoinedVoiceConfEvtMsgHdlr.scala (2 hunks)
  • akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/HandlerHelpers.scala (1 hunks)
  • bbb-webrtc-sfu.placeholder.sh (1 hunks)
  • build/packages-template/bbb-livekit/build.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: jaapjansma
PR: bigbluebutton/bigbluebutton#21204
File: bbb-common-web/src/main/scala/org/bigbluebutton/api2/meeting/MeetingsManagerActor.scala:21-21
Timestamp: 2024-10-10T12:15:03.265Z
Learning: When reviewing code changes in BigBlueButton, particularly in case classes like `RegisterUser` in `MeetingsManagerActor.scala`, ensure to accurately distinguish between added parameters and replaced parameters to avoid incorrect assessments.
bbb-webrtc-sfu.placeholder.sh (1)
Learnt from: prlanzarin
PR: bigbluebutton/bigbluebutton#21891
File: bbb-webrtc-sfu.placeholder.sh:1-1
Timestamp: 2024-12-12T17:57:29.161Z
Learning: In the `bbb-webrtc-sfu.placeholder.sh` script, adding a shebang and error handling is not necessary.
akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/HandlerHelpers.scala (1)
Learnt from: jaapjansma
PR: bigbluebutton/bigbluebutton#21204
File: bbb-common-web/src/main/scala/org/bigbluebutton/api2/meeting/MeetingsManagerActor.scala:21-21
Timestamp: 2024-10-10T12:15:03.265Z
Learning: When reviewing code changes in BigBlueButton, particularly in case classes like `RegisterUser` in `MeetingsManagerActor.scala`, ensure to accurately distinguish between added parameters and replaced parameters to avoid incorrect assessments.
akka-bbb-apps/src/main/scala/org/bigbluebutton/core/apps/voice/UserJoinedVoiceConfEvtMsgHdlr.scala (1)
Learnt from: jaapjansma
PR: bigbluebutton/bigbluebutton#21204
File: bbb-common-web/src/main/scala/org/bigbluebutton/api2/meeting/MeetingsManagerActor.scala:21-21
Timestamp: 2024-10-10T12:15:03.265Z
Learning: When reviewing code changes in BigBlueButton, particularly in case classes like `RegisterUser` in `MeetingsManagerActor.scala`, ensure to accurately distinguish between added parameters and replaced parameters to avoid incorrect assessments.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: build-package (bbb-graphql-server)
  • GitHub Check: build-package (others)
  • GitHub Check: build-package (bbb-webrtc)
  • GitHub Check: build-package (bbb-html5)
  • GitHub Check: build-package (bbb-apps-akka)
  • GitHub Check: build-package (bbb-playback-record)
🔇 Additional comments (6)
akka-bbb-apps/src/main/scala/org/bigbluebutton/core/running/HandlerHelpers.scala (2)

350-353: LGTM! Clean refactoring improves code modularity.

The extraction of the audio bridge check into a separate method improves code reusability and makes the intent clearer.


355-358: LGTM! Well-designed helper method.

The new isUsingLiveKitAudio method follows the same pattern as the existing isUsingLiveKit method and encapsulates the audio bridge check logic appropriately.

akka-bbb-apps/src/main/scala/org/bigbluebutton/core/apps/voice/UserJoinedVoiceConfEvtMsgHdlr.scala (3)

6-6: LGTM! Proper import addition.

Adding HandlerHelpers to the import statement enables access to the newly created helper method.


12-12: LGTM! Trait extension correctly implemented.

Extending HandlerHelpers provides access to the isUsingLiveKitAudio method needed for the guest lobby bypass logic.


140-147: LGTM! Correctly implements guest lobby bypass for LiveKit audio.

The logic correctly combines the existing dialInEnforceGuestPolicy flag with the LiveKit audio check. This ensures guest lobby enforcement is bypassed specifically for dial-in users joining via LiveKit audio, which aligns with the PR objectives since LiveKit doesn't fully support guest lobbies for dial-in/SIP endpoints yet.

build/packages-template/bbb-livekit/build.sh (1)

7-7: Please confirm that SIP version v1.1.1 is an official, stable release

We found the git tag “v1.1.1” in the livekit/sip repo, but no GitHub release object (draft/prerelease) returned. Before merging:

  • Verify in the GitHub UI or via the CLI that v1.1.1 is published as a stable release (not draft or prerelease).
  • Ensure this tag is intended for production use; if not, update to the correct version or wait for the official release.

build/packages-template/bbb-livekit/build.sh: line 7
SIP_VERSION=v1.1.1

#!/bin/bash

git clone --branch v2.19.0-beta.3 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu
git clone --branch v2.19.0-beta.4 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Verify the branch exists and is appropriate.

The version bump to v2.19.0-beta.4 aligns with the PR objectives. Please verify that this branch exists and contains the expected fixes mentioned in the PR summary.


🏁 Script executed:

#!/bin/bash
# Check if the branch v2.19.0-beta.4 exists on GitHub
curl -s "https://api.github.com/repos/bigbluebutton/bbb-webrtc-sfu/branches/v2.19.0-beta.4" | jq '.name'

Length of output: 107


Branch v2.19.0-beta.4 not found on GitHub

The clone command in bbb-webrtc-sfu.placeholder.sh still references a branch that doesn’t exist in the bigbluebutton/bbb-webrtc-sfu repo. Please confirm the correct branch name or push the v2.19.0-beta.4 branch before merging.

Locations to update:

  • File: bbb-webrtc-sfu.placeholder.sh
    Line 3

Suggested fix (example):

- git clone --branch v2.19.0-beta.4 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu
+ git clone --branch v2.19.0-beta.3 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu

—or— push the v2.19.0-beta.4 branch so it can be checked out.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
git clone --branch v2.19.0-beta.4 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu
git clone --branch v2.19.0-beta.3 --depth 1 https://github.com/bigbluebutton/bbb-webrtc-sfu bbb-webrtc-sfu
🤖 Prompt for AI Agents
In bbb-webrtc-sfu.placeholder.sh at line 3, the git clone command references a
non-existent branch v2.19.0-beta.4. Verify the correct branch name available in
the bigbluebutton/bbb-webrtc-sfu repository and update the clone command to use
that branch. Alternatively, if the v2.19.0-beta.4 branch is intended, ensure it
is pushed to the remote repository before merging.

@github-actions

Copy link
Copy Markdown

Automated tests Summary

✅ All the CI tests have passed!

@prlanzarin
prlanzarin merged commit f98d909 into bigbluebutton:v3.0.x-release Jul 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant