Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Improve error message on meeting or session invalid #16060

Conversation

gustavotrott
Copy link
Collaborator

@gustavotrott gustavotrott commented Nov 24, 2022

This PR introduces a new prop messageKey to the return of API /enter requests. It will allow the client (html5) handle the error messages and show the properly error.

{
    "response": {
        "returncode": "FAILED",
        "message": "Invalid session token",
        "messageKey": "sessionMissing",
        "logoutURL": "https://bbb26.bbbvm.imdt.com.br"
    }
}

Before

Since #12693 the API was always returning guestDeny error even when the meeting doesn't exist.
And once the client-html5 doesn't know the correct error it use to show a generic error for example when returning from disconnection:
image

access_danied.mp4

After

This PR will follow an order to check if error exists and return to the client something more meaningful.
Using the same example as above now it shows the error "Meeting has ended" which is much more useful.
image

meeting_ended.mp4

Possibly closes: #16036 and #16037
It can still be improved in the API version 2. The current one doesn't know the error because once the meeting is ended, the API removes all informations about that including the users sessions. So it is impossible to know if the problem is related with the sessionToken or if the meeting ended.

@MaximKhlobystov MaximKhlobystov added this to the Release 2.6 milestone Nov 24, 2022
@sonarcloud
Copy link

sonarcloud bot commented Nov 25, 2022

SonarCloud Quality Gate failed.    Quality Gate failed

Bug C 1 Bug
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
1.6% 1.6% Duplication

@ffdixon
Copy link
Member

ffdixon commented Nov 26, 2022

Nice!

Copy link
Member

@Tainan404 Tainan404 left a comment

Choose a reason for hiding this comment

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

LGTM!

@antobinary
Copy link
Member

Is this PR improving in any way #16119 ?

@antobinary antobinary merged commit d7da9f7 into bigbluebutton:v2.6.x-release Jan 23, 2023
@gustavotrott gustavotrott deleted the api-enter-meeting-ended-error branch March 11, 2024 16:42
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.

None yet

5 participants