This commit is contained in:
2026-06-13 19:53:27 +03:00
parent 5778782737
commit 1d1fdb1f0b
19 changed files with 1508 additions and 858 deletions

View File

@@ -54,6 +54,7 @@ func (s *Connection) mustSuccess(reader *bufreader.BufferedReader) (err error) {
}
switch code {
case proto.RespSuccess:
fmt.Println("SUCCESS")
return nil // ok
case proto.RespError:
return s.onError()
@@ -70,6 +71,7 @@ func (s *Connection) AddMetric(req proto.AddMetricReq) (err error) {
req.FracDigits,
}
bin.PutUint32(arr[1:], req.MetricID)
fmt.Println("arr", arr)
// req
if _, err = s.conn.Write(arr); err != nil {
return