pgCoord is a postgres-backed coordinator ┌────────────┐ ┌────────────► handshaker ├────────┐ │ └────────────┘ │ │ ┌──────────┐ │ ├────────────► tunneler ├──────────┤ │ └──────────┘ │ │
| 97 | // and a *proto.Node. It uses the term "mapping" to mean the act of determining the nodes that the connection |
| 98 | // needs to receive (i.e. the nodes of all peers it shares a tunnel with). |
| 99 | type pgCoord struct { |
| 100 | ctx context.Context |
| 101 | logger slog.Logger |
| 102 | pubsub pubsub.Pubsub |
| 103 | store database.Store |
| 104 | |
| 105 | bindings chan binding |
| 106 | newConnections chan *connIO |
| 107 | closeConnections chan *connIO |
| 108 | tunnelerCh chan tunnel |
| 109 | handshakerCh chan readyForHandshake |
| 110 | id uuid.UUID |
| 111 | |
| 112 | cancel context.CancelFunc |
| 113 | closeOnce sync.Once |
| 114 | closed chan struct{} |
| 115 | |
| 116 | binder *binder |
| 117 | tunneler *tunneler |
| 118 | handshaker *handshaker |
| 119 | querier *querier |
| 120 | } |
| 121 | |
| 122 | var pgCoordSubject = rbac.Subject{ |
| 123 | ID: uuid.Nil.String(), |
nothing calls this directly
no outgoing calls
no test coverage detected