blindsidenetworks / scalelite

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

`rake status` might crash under some circumstances #997

Closed debuglevel closed 3 months ago

debuglevel commented 11 months ago

Unfortunately I do not really know how I managed to get into this state :)

$ sudo docker exec -t scalelite_scalelite-api bundle exec rake status
rake aborted!
ArgumentError: comparison of String with nil failed
/srv/scalelite/lib/tasks/status.rake:24:in `sort_by'
/srv/scalelite/lib/tasks/status.rake:24:in `block (2 levels) in <main>'
/srv/scalelite/lib/tasks/status.rake:12:in `each'
/srv/scalelite/lib/tasks/status.rake:12:in `block in <main>'
/srv/scalelite/vendor/bundle/ruby/3.1.0/gems/rake-13.0.6/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:25:in `load'
/usr/local/bin/bundle:25:in `<main>'
Tasks: TOP => status
(See full trace by running task with --trace)
debuglevel commented 11 months ago

Might be caused by #996 where servers:add allows to add invalid URIs (e.g. www.google.com); but status assumes a URI:

https://github.com/blindsidenetworks/scalelite/blob/1ae48324d9dfe3df5fe2bb55f6e5dbcb53bc608b/lib/tasks/status.rake#L17

ffdixon commented 11 months ago

Thanks Marc for digging into this!

Ithanil commented 3 months ago

@debuglevel Can you confirm that the status task does not anymore crash under the given circumstances?

debuglevel commented 3 months ago

Unfortunately I don't know how to get into these circumstances. But I did not encountered it anymore :)

ffdixon commented 3 months ago

We'll take that as fixed :-).