balena-io-experimental / meetbot

A Google Meet bot to make meetings frictionless
GNU Affero General Public License v3.0
32 stars 13 forks source link

[Bug] Meetbot queue should only count active meetings #76

Closed vipulgupta2048 closed 2 years ago

vipulgupta2048 commented 2 years ago

Since we are storing all bots in the BOTS map object, we reach the max limit of bots pretty fast which leads to meetbot not able to join any other meetings.

14.03.22 21:35:58 (+0530)  main  queuing: starting the recording...
14.03.22 21:35:58 (+0530)  main  Current bot queue size: 5
vipulgupta2048 commented 2 years ago

Workaround deployed: increasing the limit for now until we resolve this.

vipulgupta2048 commented 2 years ago

Context:

From https://github.com/balena-io-playground/meetbot/pull/56, we have made meetbot's meet history persistent. Now, https://bit.ly/getmeetbot shows all meetings that happened in order for it to surface transcripts better. This caused a regression where as the meet queue has become persistent. The meetbot logic to track active meetbots wasn't patch to actually track active meetbots. Rather, it's tracking both active and dead meetbots together.

This leads to an error where we hit our set limit of MAX_BOTS (Atm set to 10) and then no meetbots can be deployed. We need to fix how we calculate active number of meetbots in order for the MAX_BOTS limit to function.

Workarounds:

To prevent the bot queue from filling up we can restart the meetbot container couple of days to reset it Take MAX_BOTS limit to 100 or something

vipulgupta2048 commented 2 years ago

Closing as MAX_BOTS are now at a limit of 100