Run server requests through ServerLink, not the whole connection

ServerLink owns what lives from one connect to its teardown: the socket,
the thread ts3j dispatches events on, the threads requests run on and
the file transfer channel. It runs requests in the background and says
whether we are connected. The *Admin helpers take it, plus the model,
permissions or avatar store where they need them, instead of the whole
TeamspeakConnection; the connection's file transfer calls share its
"not connected" check instead of repeating it.

A myTeamSpeak refresh that fails because we left meanwhile is no longer
reported, as for every other request.

Also corrects 4a's commit hash in AUDIT-STRUCTURE.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-11 18:40:11 +00:00
co-authored by Claude Opus 5.5
parent 1bc7eb58c1
commit da908f77bd
11 changed files with 389 additions and 354 deletions
+2 -2
View File
@@ -12,8 +12,8 @@ Items are worked through in the order below. Status: open, done (commit), or clo
| 2 | Client properties parsed twice: `ConnectionEventHandler.onClientJoin` sets every field, `onClientChanged` the same ones again; channels already share `applyChannelProperties` | done (`e255a46`): one `applyClientProperties`. It also fixed a joining channel commander shown as none, and picks up the description a client enters with |
| 3 | What we may do is answered in five places: `ServerSession.can*`, `ServerModel.can*/permits/mayHavePower`, `TeamspeakConnection.canSendOfflineMessages/canTransferFiles`, and raw permission names in Swing dialogs and `ServerController.canCreateBans` | done (`13e3a62`): `Permissions` owns the table, the rules and one named question per capability; `ServerSession.permissions()` is `NONE` while disconnected; no permission names outside core except channel-permission editing |
| 4 | `TeamspeakConnection` (2,157 lines) still does lifecycle, mic/speaker, recording, chat logs, log/sound text, contacts, avatars, icons, file transfers, myTeamSpeak and job plumbing. The `*Admin` helpers take the whole connection, which forwards ~90 methods to them | in progress, in sub-steps: |
| 4a | … chat log and what we tell the user (log lines, sounds, links and sound variables) | done (`c28c2ce`): `ChatLog`, `Announcer` |
| 4b | … request plumbing into its own class; `*Admin` helpers on narrow dependencies instead of the whole connection | open |
| 4a | … chat log and what we tell the user (log lines, sounds, links and sound variables) | done (`1bc7eb5`): `ChatLog`, `Announcer` |
| 4b | … request plumbing into its own class; `*Admin` helpers on narrow dependencies instead of the whole connection | done (uncommitted): `ServerLink` owns the socket, event and request threads and file transfers, and runs requests; the helpers take it (plus the model, permissions or avatars where they need them) |
| 4c | … frontends reach the admin helpers directly instead of ~40 one-line forwarders | open |
| 4d | … our own state (mic, speakers, away, talk request, recording) out of the connection | open |
| 5 | Two front doors: frontends use both `ServerSession` and `session.connection()` with no rule for which | open |