NewAgentCoordinationController creates a CoordinationController for Coder Agents, which never create tunnels and always send ReadyToHandshake acknowledgements.
( logger slog.Logger, coordinatee Coordinatee, )
| 545 | // NewAgentCoordinationController creates a CoordinationController for Coder Agents, which never |
| 546 | // create tunnels and always send ReadyToHandshake acknowledgements. |
| 547 | func NewAgentCoordinationController( |
| 548 | logger slog.Logger, coordinatee Coordinatee, |
| 549 | ) CoordinationController { |
| 550 | return &BasicCoordinationController{ |
| 551 | Logger: logger, |
| 552 | Coordinatee: coordinatee, |
| 553 | SendAcks: true, |
| 554 | Initiator: codersdk.DisconnectInitiatorAgent, |
| 555 | Direction: codersdk.ConnectionDirectionServerToAgent, |
| 556 | } |
| 557 | } |
| 558 | |
| 559 | type inMemoryCoordClient struct { |
| 560 | sync.Mutex |
no outgoing calls