blindsidenetworks / scalelite

Scalable load balancer for BigBlueButton.
GNU Affero General Public License v3.0
469 stars 247 forks source link

move the session to another BBB server manually #970

Open mahdidev70 opened 1 year ago

mahdidev70 commented 1 year ago

Is there any way to move the session to another BBB server? sometimes people have problems with specific BBB server because of network problems or resources. I think the problem can be solved if there is an API that ends the session on the current BBB server and start it on another one. consider network problems may happen between the user and BBB server and probably scalelite can't detect it.

farhatahmad commented 1 year ago

If you make an end API call, the meeting can be ended on a specific server. You can then disable the server causing issues and they can re-create the meeting on a different server

You can also panic a server that is causing issues causing all meetings to end and no new meetings to be created on that server

mahdidev70 commented 1 year ago

thank you @farhatahmad but I think it's not a good solution. let me be clear. we have 2 BBB servers in different locations. user A is closer to server 1, but when starting the session the meeting runs on server 2. if user A feels slow data transfer speed the solution is to end the class on the server and start it on a closer server. but it seems there isn't any API to start the session on a different server to find a better network situation.

ffdixon commented 1 year ago

There isn't any way in BigBlueButton (using ScaleLite or not) to move a live meeting from one server to another.

Looking ahead, we (the core BigBlueButton developers) do plan to have the ability to capture the state of a meeting -- the shared notes, chat, and whiteboard -- to load in subsequent meetings, and once this is in place, it may be possible to capture the state of a meeting, create a new meeting, restore the state, and once the new meeting is running, invite users to join the new meeting.

There is no time frame for this, but that's the long-term goal.

mahdidev70 commented 1 year ago

@ffdixon thank you Fred

what you mentioned about the future vision is very good. maybe a better way is to work on clustering and hosting a session on multiple servers simultaneously to increase the quality of the session and increase the session member number. but I think the problem that I described before can be solved with a simple and easy trick. only end the session with a flag which means don't start a session next time on the same BBB server.

ffdixon commented 1 year ago

but I think the problem that I described before can be solved with a simple and easy trick. only end the session with a flag which means don't start a session next time on the same BBB server.

Paraphrasing back, assuming there might be an issue with the server itself, add the ability for ScaleLite (either through parameter or configuration) to automatically assign a subsequent create API call for the same meeting, say received within a X minute period after the end, to a different BigBlueButton server in the pool.

This would be invisible to the users, but would ensure such meetings are put onto different servers. If the underlying BigBlueButton server is experiencing problems, a better solution would be, as @farhatahmad suggested is to move the server out of the pool before the meeting ends. A subsequent ending and restart of the meeting will automatically put it onto a new server (as the original server is no longer in the pool).

You would need external logic to detect a server was having troubles and call ScaleLite to move it out of the pool, but that would be better as you control the logic for detecting/moving as opposed to looking at incoming API calls.

Wladimir-N commented 6 months ago

I'm experiencing similar problems. We have teachers and students from different regions and countries. And our pool consists of BBBs located in different data centers and even countries. Using the server part of the speedtest, we allow teachers and students to test the quality of communication with different BBBs. I would like students and teachers to have the opportunity to turn off those servers with which they have a poor connection from balancing for them.

That is, the teacher/student identifies those bbbs with which he has problems and marks them in our interface. And when requesting the creation of a conference, we indicate a certain distribution coefficient in the request to the API. Example

bbb1 - poor connection between teacher and 2 students bbb2 - poor connection for 1 student bbb3 - poor connection for 5 students bbb4 - no complaints

Based on this, we throw coefficients in the request to the API bbb1=3&bbb2=1&bbb3=5

And based on the coefficients, a bbb is selected on which the meeting will be created

This approach will allow you to better select the appropriate bbb based on the quality of communication with it for all meeting participants

ffdixon commented 6 months ago

See this pull request on tagging servers https://github.com/blindsidenetworks/scalelite/pull/1049. If ScaleLite support tags for each group of servers in each region, then you could request on the create call which group of servers (regions) you would like to start the meeting on.

This isn't a per-server selection, but a per-group selection could be a step closer to what you are looking to achieve.

Wladimir-N commented 3 months ago

See this pull request on tagging servers #1049. If ScaleLite support tags for each group of servers in each region, then you could request on the create call which group of servers (regions) you would like to start the meeting on.

This isn't a per-server selection, but a per-group selection could be a step closer to what you are looking to achieve.

Looks like what we need. But I don’t yet understand how to pre-test this. I see that it has already been thrown into the master, but it is not in the releases yet. Are the release dates known?

ffdixon commented 3 months ago

1049 was merged into master a few weeks ago. If you pull scalelite from master, you can test it there and give feedback.

Wladimir-N commented 3 months ago

1049 was merged into master a few weeks ago. If you pull scalelite from master, you can test it there and give feedback.

But I don’t understand how to test it in the master. After all, now I just take ready-made Docker images, but there are no such images for the master. Now I will try to find and figure out how to collect them. Or maybe there is an understanding of when they will be released?, at least a beta release...