MCPcopy Index your code
hub / github.com/coder/coder / sendLogs

Function sendLogs

agent/boundarylogproxy/proxy_test.go:37–47  ·  view source on GitHub ↗

sendLogs writes a BoundaryMessage envelope containing logs to the connection using TagV2.

(t *testing.T, conn net.Conn, req *agentproto.ReportBoundaryLogsRequest)

Source from the content-addressed store, hash-verified

35// sendLogs writes a BoundaryMessage envelope containing logs to the
36// connection using TagV2.
37func sendLogs(t *testing.T, conn net.Conn, req *agentproto.ReportBoundaryLogsRequest) {
38 t.Helper()
39
40 msg := &codec.BoundaryMessage{
41 Msg: &codec.BoundaryMessage_Logs{Logs: req},
42 }
43 err := codec.WriteMessage(conn, codec.TagV2, msg)
44 if err != nil {
45 t.Errorf("write logs: %s", err)
46 }
47}
48
49// sendStatus writes a BoundaryMessage envelope containing a BoundaryStatus
50// to the connection using TagV2.

Calls 3

WriteMessageFunction · 0.92
HelperMethod · 0.65
ErrorfMethod · 0.45

Tested by

no test coverage detected