pre-bed notes

This commit is contained in:
Sacha Ligthert 2025-02-04 01:44:19 +01:00
parent 6d76a88c9c
commit 5d534221a4

View File

@ -71,9 +71,10 @@ Solver
flags := flags.Flags{Controller: &controller}
solver := solver.Solver{Controller: &controller, Outp: &outp}
```
### Manager & Client channel setup
#### Client
#### Manager
### Manager & Agent channel setup
Both the manager and the agent will have similar setups:
* `*websocket.Conn` is stored in _types.go_.
* Any go routine can write to the socket.
* All reads go to a `readProcessor()` which in turn parses the message, and in turn does the appropriate logic (read, calling go routine/functions)
This does however presents me with a problem. Since all communication is reactive, state-less, and all over the same connection; so tracking things is a bit hard. And this is something for maybe the next phase. So for now, reactive content only. This said, I need figure out how on earth I can prevent an agent from taking two jobs at the same time. I guess I will need to build in some agent state tracking for this.