Skip to content

refactor(akka-apps): remove dead bbb-html5 -> akka-apps messages - #27

Draft
antobinary wants to merge 2 commits into
v4.0.x-developfrom
fix-20095-remove-html5-akka-messages
Draft

refactor(akka-apps): remove dead bbb-html5 -> akka-apps messages#27
antobinary wants to merge 2 commits into
v4.0.x-developfrom
fix-20095-remove-html5-akka-messages

Conversation

@antobinary

@antobinary antobinary commented Aug 7, 2026

Copy link
Copy Markdown
Owner

What this does

Closes bigbluebutton#20095 — removes the client → akka-apps messages that no longer have a
sender, and the outbound messages they leave stranded.

The html5 client stopped publishing to redis when its calls moved to
bbb-graphql-actions, and state reads moved to GraphQL/Hasura. Anything
ReceivedJsonMsgHandlerActor still accepts but nobody sends is dead code.

44 messages removed.

Before After
Inbound messages accepted by akka-apps 208 179
Messages defined in bbb-common-message 447 406

Two commits, so the risky part is reviewable on its own:

Commit Contents Diff
0da4f75746 3 inbound (pads + waiting queue) 10 files, −124
43351d1fbb 26 inbound + 15 stranded outbound 55 files, +16 / −1163

Inbound removed (29)

Initial-state fetches (13) — the client reads this from Hasura now:
GetAllPresentationPodsReqMsg, GetChatHistoryReqMsg, GetCurrentLayoutReqMsg,
GetCurrentPollReqMsg, GetGroupChatMsgsReqMsg, GetGroupChatsReqMsg,
GetGuestPolicyReqMsg, GetGuestsWaitingApprovalReqMsg,
GetPresenterGroupReqMsg, GetScreenshareStatusReqMsg,
GetWebcamsOnlyForModeratorReqMsg, GetWhiteboardAnnotationsReqMsg,
IsMeetingMutedReqMsg

Chat (2), superseded by group chat in 2018 — SendPublicMessagePubMsg,
SendPrivateMessagePubMsg

Presenter group (2), feature removed 2018 — AddUserToPresenterGroupCmdMsg,
RemoveUserFromPresenterGroupCmdMsg

Presentation pods (4)CreateNewPresentationPodPubMsg,
RemovePresentationPodPubMsg, SlideResizedPubMsg,
PreuploadedPresentationsSysPubMsg

Pads / waiting queue (3)PadCreateReqMsg, PadUpdatePubMsg,
UpdatePositionInWaitingQueueReqMsg

Other (5)BreakoutRoomsListMsg, LockUsersInMeetingCmdMsg,
EjectUserFromMeetingSysMsg, RecordAndClearPreviousMarkersCmdMsg,
ClientToServerLatencyTracerMsg

Outbound removed (15)

These lost their only emitter when the inbound side went, so they are removed in
the same change rather than left as new dead code:

GetAllPresentationPodsRespMsg, GetChatHistoryRespMsg,
GetCurrentLayoutRespMsg, GetCurrentPollRespMsg, GetGroupChatMsgsRespMsg,
GetGroupChatsRespMsg, GetGuestPolicyRespMsg,
GetWebcamsOnlyForModeratorRespMsg, GetWhiteboardAnnotationsRespMsg,
IsMeetingMutedRespMsg, NewPresentationEvtMsg, SendPrivateMessageEvtMsg,
ServerToClientLatencyTracerMsg, PadUpdateCmdMsg,
PosInWaitingQueueUpdatedRespMsg

Plus the helpers that built them: Polls.handleGetCurrentPollReqMsg,
PresentationApp2x.processPreuploadedPresentations, the
NewPresentationMsgHdlr trait, MsgBuilder.buildPosInWaitingQueueUpdatedRespMsg,
and the GuestWaitingUP VO that only PosInWaitingQueueUpdatedRespMsg used.

Verified invariant: 25 messages in bbb-common-message have no emitter after
this PR, and all 25 were already in that state on v4.1.x-develop. No message
that had an emitter before this change is left without one.

Notes for reviewers

LayoutApp2x now declares val liveMeeting: LiveMeeting itself. It inherited
that declaration from GetCurrentLayoutReqMsgHdlr, and its sibling handler
traits resolve liveMeeting through the mixin.

Pad creation is unaffected — akka-apps drives it via
PadslHdlrHelpers.broadcastPadCreateGroupCmdMsg / broadcastPadCreateCmdMsg
from MeetingActor and PadGroupCreatedEvtMsgHdlr. PadCreateReqMsg was only
the old client-initiated entry point.

bbb-pads still has a redis handler for PadUpdateCmdMsg
(lib/redis/handler.js). Nothing has emitted that message since the client
stopped sending PadUpdatePubMsg, so the handler was already unreachable; it can
be dropped on the bbb-pads side separately.

Deliberately NOT removed

GetMediaGroupsReqMsg has no sender either, but it is not legacy. Added
2024-12 as GetAudioGroupsReqMsg, renamed 2025-10 when media groups were
extended to cameras and screenshare; its sibling graphql-actions mutations
(mediaGroupCreate/Destroy/Join/Leave/UpdateParticipant) are all live. Looks
like scaffolding for in-flight work — @prlanzarin should confirm before it goes.

UserConnectedToGlobalAudioMsg / UserDisconnectedFromGlobalAudioMsg look
dead from this repo but bbb-webrtc-sfu sends both from
lib/audio/client-audio-consumer.js.

TranscriptionProviderErrorMsg — sent by bbb-transcription-controller
(app.js:199).

CheckGraphqlMiddlewareAlivePongSysMsg, UserGraphqlConnectionEstablishedSysMsg,
UserGraphqlConnectionClosedSysMsg
— sent by bbb-graphql-middleware (Go).

How "no sender" was established

A grep of this repo is not sufficient — several of the near-misses above are sent
from other repos. Each candidate was checked against:

  • every component in this monorepo, including akka-apps constructing the message
    itself, not just handling it;
  • the components installed on a running 4.x server (bbb-webrtc-sfu, bbb-pads,
    bbb-export-annotations, bbb-graphql-actions, etherpad incl.
    ep_redis_publisher, the Ruby recording scripts, freeswitch);
  • jar/war contents via unzip -p | strings;
  • the bbb-graphql-middleware and bbb-webrtc-recorder Go binaries via strings
    (substring, not anchored — Go concatenates string literals);
  • bbb-transcription-controller v0.2.10, bbb-webhooks v3.6.1 and
    bbb-webrtc-recorder v0.14.0 at their pinned placeholder tags;
  • every publisher to to-akka-apps-redis-channel, to confirm none builds a
    message name dynamically;
  • docs/, in case any is a documented integration point;
  • git log -S per message, for senders removed recently enough to be coming back.

A second independent pass re-ran all of this adversarially, instructed to refute
rather than confirm. It is what rescued GetMediaGroupsReqMsg.

Testing

  • bbb-common-messagesbt publishM2 succeeds.
  • akka-bbb-appssbt compile succeeds; only pre-existing deprecation warnings.
  • akka-bbb-appssbt test does not compile on v4.1.x-develop, with or
    without this change: 54 identical errors in TestDataGen.scala
    (RegisteredUsers.create missing loggedOut; WebcamStream missing
    hasAudio/showAsContent/subscribers). Verified by stashing the change and
    re-running. Filed separately; not addressed here.
  • The MeetingActor diff was reviewed arm by arm: multi-line case m: X =>
    bodies are removed together with their case line. An earlier scripted attempt
    dropped only the case line and silently merged the body into the previous
    arm — it compiled and was wrong. Worth spot-checking in review.

Follow-ups

  • 25 messages in bbb-common-message have no emitter and predate this PR —
    separate issue.
  • bbb-graphql-middleware sends UserGraphqlDisconnectionForcedEvtMsg, which
    akka-apps has never had a handler for — separate issue.
  • akka-bbb-apps test suite does not compile — separate issue.

Part of bigbluebutton#20095. The html5 client no longer publishes to redis — those calls
moved to bbb-graphql-actions — so any inbound message with no remaining sender
is dead code in akka-apps.

Removed three, each marked "client -> apps" in bbb-common-message:

  PadCreateReqMsg
  PadUpdatePubMsg
  UpdatePositionInWaitingQueueReqMsg

For each: the case classes in bbb-common-message, the handler trait, its mixin,
the MeetingActor dispatch, the AnalyticsActor logging case, and the inbound
routing in ReceivedJsonMsgHandlerActor.

How these were picked. I took every message the Meteor backend ever published
(105, recovered from the deleted imports/api/**/server/methods files across
history), intersected with the 208 messages ReceivedJsonMsgHandlerActor still
accepts, then dropped everything with a surviving sender in bbb-graphql-actions,
bbb-web, bbb-common-web, akka-bbb-fsesl, bbb-shared-notes-server or the client.
That leaves 5. Two of those five are NOT removed:

  UserConnectedToGlobalAudioMsg
  UserDisconnectedFromGlobalAudioMsg

bbb-webrtc-sfu still sends both, from lib/audio/client-audio-consumer.js via
Messaging.generateUserConnectedToGlobalAudioMessage. It lives in another repo,
so a source grep here does not see it — checked against the installed component.
bbb-transcription-controller v0.2.10 was checked too (it uses no pad messages).

Pad creation is unaffected: akka-apps drives it itself now, through
PadslHdlrHelpers.broadcastPadCreateGroupCmdMsg / broadcastPadCreateCmdMsg called
from MeetingActor and PadGroupCreatedEvtMsgHdlr. PadCreateReqMsg was only the
old client-initiated entry point.

bbb-common-message and akka-bbb-apps both compile. The akka-apps test suite does
not compile on v4.1.x-develop either way — 54 pre-existing errors in
TestDataGen.scala (RegisteredUsers.create and WebcamStream signatures), identical
with and without this change.

The one added line in MeetingActor is scalariform re-aligning `=>` in the case
block the removal shortened.
Continues the previous commit. These 26 inbound messages are still accepted by
ReceivedJsonMsgHandlerActor but nothing anywhere sends them:

  Initial-state fetches, now served by GraphQL/Hasura instead of a request to
  akka-apps: GetAllPresentationPodsReqMsg, GetChatHistoryReqMsg,
  GetCurrentLayoutReqMsg, GetCurrentPollReqMsg, GetGroupChatMsgsReqMsg,
  GetGroupChatsReqMsg, GetGuestPolicyReqMsg, GetGuestsWaitingApprovalReqMsg,
  GetPresenterGroupReqMsg, GetScreenshareStatusReqMsg,
  GetWebcamsOnlyForModeratorReqMsg, GetWhiteboardAnnotationsReqMsg,
  IsMeetingMutedReqMsg

  Chat, superseded by group chat in 2018: SendPublicMessagePubMsg,
  SendPrivateMessagePubMsg

  Presenter group, feature removed in 2018: AddUserToPresenterGroupCmdMsg,
  RemoveUserFromPresenterGroupCmdMsg

  Presentation pods: CreateNewPresentationPodPubMsg, RemovePresentationPodPubMsg,
  SlideResizedPubMsg, PreuploadedPresentationsSysPubMsg

  Other: BreakoutRoomsListMsg, LockUsersInMeetingCmdMsg,
  EjectUserFromMeetingSysMsg, RecordAndClearPreviousMarkersCmdMsg,
  ClientToServerLatencyTracerMsg

For each: the case classes in bbb-common-message, the handler trait, its mixin,
the MeetingActor dispatch arm, the AnalyticsActor logging case and the inbound
routing. Handlers whose file name did not match the message
(PreuploadedPresentationsPubMsgHdlr, EjectUserFromMeetingSysMsgHdlr inside
EjectUserFromMeetingCmdMsgHdlr.scala) were removed too.

Also removes the 15 outbound messages these leave without an emitter, so the
change does not trade one kind of dead code for another:

  GetAllPresentationPodsRespMsg, GetChatHistoryRespMsg, GetCurrentLayoutRespMsg,
  GetCurrentPollRespMsg, GetGroupChatMsgsRespMsg, GetGroupChatsRespMsg,
  GetGuestPolicyRespMsg, GetWebcamsOnlyForModeratorRespMsg,
  GetWhiteboardAnnotationsRespMsg, IsMeetingMutedRespMsg, NewPresentationEvtMsg,
  SendPrivateMessageEvtMsg, ServerToClientLatencyTracerMsg, PadUpdateCmdMsg,
  PosInWaitingQueueUpdatedRespMsg

plus the helpers that built them: Polls.handleGetCurrentPollReqMsg,
PresentationApp2x.processPreuploadedPresentations, the NewPresentationMsgHdlr
trait, MsgBuilder.buildPosInWaitingQueueUpdatedRespMsg, and the GuestWaitingUP
VO that only PosInWaitingQueueUpdatedRespMsg used.

Note for bbb-pads: it still has a redis handler for PadUpdateCmdMsg
(lib/redis/handler.js). Nothing has emitted that message since the client stopped
sending PadUpdatePubMsg, so the handler was already unreachable; it can be
dropped on the bbb-pads side separately.

LayoutApp2x now declares `val liveMeeting: LiveMeeting` itself. It used to
inherit that declaration from GetCurrentLayoutReqMsgHdlr, and its sibling
handler traits resolve `liveMeeting` through the mixin.

Verification. Candidates were taken from the messages ReceivedJsonMsgHandlerActor
accepts, minus every message with a sender in this repo, in the components
installed on a running 4.x server, in the bbb-graphql-middleware and
bbb-webrtc-recorder Go binaries (via strings), or in bbb-transcription-controller
v0.2.10, bbb-webhooks v3.6.1 and bbb-webrtc-recorder v0.14.0 at their pinned
tags. A second independent pass re-checked every candidate against the Ruby
recording scripts, freeswitch, jar/war contents, dynamically-built message names
and git history for recently-removed senders.

GetMediaGroupsReqMsg also has no sender but is deliberately kept: it is not
legacy. It was added 2024-12 as GetAudioGroupsReqMsg and renamed 2025-10 when
media groups were extended to cameras and screenshare, and its sibling
graphql-actions mutations are live. Removing it should be confirmed with the
feature author first.

bbb-common-message and akka-bbb-apps compile. The akka-apps test suite does not
compile on v4.1.x-develop with or without this change (54 pre-existing errors in
TestDataGen.scala).

Inbound messages accepted by akka-apps: 205 -> 179.
Messages defined in bbb-common-message: 447 -> 406.
No message that had an emitter before this PR is left without one.
@antobinary
antobinary force-pushed the fix-20095-remove-html5-akka-messages branch from 5d4ec0b to 43351d1 Compare August 8, 2026 00:28
@antobinary

Copy link
Copy Markdown
Owner Author

Issue 1 — dead outbound messages

Remove dead outbound messages from bbb-common-message

Mirror of bigbluebutton#20095. That issue covered inbound (client → apps) messages with no
sender; this covers messages that are defined but never emitted.

Of 421 messages currently defined in bbb-common-message, 25 are referenced
nowhere outside their own definition
— not in akka-apps, akka-fsesl, bbb-web,
bbb-common-web, bbb-graphql-actions, bbb-shared-notes-server, the html5 client,
bbb-pads, or record-and-playback. Several are also absent from the components
installed on a running 4.x server and from the bbb-graphql-middleware binary.

Request/response pairs whose request side is long gone

GetLockSettingsRespMsg          LockSettingsNotInitializedRespMsg
GetPresenterGroupRespMsg        GetUsersReqMsg
LookUpUserRespMsg               UserSessionTokenRegisteredRespMsg

Group chat events, superseded

GroupChatAccessChangedEvtMsg    GroupChatUserAddedEvtMsg
GroupChatDestroyedEvtMsg        GroupChatUserRemovedEvtMsg
OpenGroupChatWindowEvtMsg

Pads

CaptureSharedNotesReqEvtMsg     PadCapturePubMsg
PadGroupCreatedRespMsg          PadTailEvtMsg

Presentation conversion progress events

PresentationConversionRequestReceivedEventMsg
PresentationPageConversionStartedEventMsg
PresentationUploadedConversionCancelledErrorEvtMsg

Other

CamStreamSubscribeSysMsg        PubSubPingSysReqMsg
TimerEndedPubMsg                PubSubPongSysRespMsg
TransferUserToMeetingEvtMsg     ServerToClientLatencyTracerMsg
UserGraphqlDisconnectionForcedEvtMsg   (see separate issue — middleware sends it)
UserGraphqlReconnectionForcedEvtMsg

Caveats for whoever picks this up

  • A repo grep is not sufficient. While working Remove all bbb-html5 -> akka-apps bbb-common-messages bigbluebutton/bigbluebutton#20095, three messages that
    looked dead here turned out to be sent from other repos: bbb-webrtc-sfu
    (UserConnectedToGlobalAudioMsg), bbb-transcription-controller
    (TranscriptionProviderErrorMsg) and bbb-graphql-middleware. Check the
    installed components, the Go binaries with strings, and the placeholder
    repos at their pinned tags before deleting anything.
  • The presentation-conversion events are the ones I'd scrutinise hardest — they
    look like progress reporting that a UI or the recording pipeline might have
    consumed.
  • Some of these have consumers even though nothing emits them (see the
    separate middleware issue). A consumer without an emitter is a dead feature,
    which may be a bug rather than something to delete.
    Issue 2 — a message sent into the void

bbb-graphql-middleware sends UserGraphqlDisconnectionForcedEvtMsg but akka-apps has no handler

bbb-graphql-middleware publishes UserGraphqlDisconnectionForcedEvtMsg to
redis — the symbol websrv.SendUserGraphqlDisconnectionForcedEvtMsg is present
in the shipped binary, confirmed with strings /usr/bin/bbb-graphql-middleware.

akka-apps never handles it. It is not in ReceivedJsonMsgHandlerActor's
dispatch, and the name appears nowhere in akka-bbb-apps at all.
git log -S UserGraphqlDisconnectionForcedEvtMsg -- akka-bbb-apps/ is empty, so
a handler has never existed on this branch.

The message is defined in bbb-common-message
(SystemMsgs.scala:208) with body
(middlewareUID: String, sessionToken: String, browserConnectionId: String).

UserGraphqlReconnectionForcedEvtMsg is defined alongside it and is likewise
unreferenced in akka-apps, though I did not find a sender for that one.

So either:

  • akka-apps is meant to react to a forced graphql disconnection and the handler
    was never wired up — in which case something is silently not happening; or
  • the message is genuinely obsolete, and the middleware should stop publishing it
    and both definitions should be removed.

Worth a maintainer deciding which, rather than assuming. Found while working
bigbluebutton#20095.
Issue 3 — the test suite doesn't build

akka-bbb-apps test suite does not compile on v4.1.x-develop

sbt test in akka-bbb-apps fails with 54 compilation errors before any test
runs. Reproduced on a clean checkout of v4.1.x-develop (13c457f).

Two model signatures drifted away from the test fixtures:

src/test/scala/org/bigbluebutton/core2/testdata/TestDataGen.scala:20

not enough arguments for method create: (..., livekitToken: Option[String])
  Unspecified value parameter loggedOut.
    val ru = RegisteredUsers.create(meetingId, userId = id, extId, name, "", "", role, ...

src/test/scala/org/bigbluebutton/core2/testdata/TestDataGen.scala:85

not enough arguments for method apply: (streamId, userId, contentType, hasAudio,
  showAsContent, subscribers) in object WebcamStream.
  Unspecified value parameters hasAudio, showAsContent, subscribers.
    WebcamStream(streamId, userId, subscribers)

Also touches AppsTestFixtures.scala, BigBlueButtonActorTestsSpec.scala and
TestKitUsageSpec.scala.

Impact: there is currently no automated test coverage for akka-apps —
sbt compile succeeds, so this does not show up unless you run the tests.

Note that sbt reformats the test sources via scalariform on compile, so a test
run leaves the working tree dirty even when it fails.

@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown

🚨 Automated tests failed

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