diff --git a/interface.go b/interface.go index 771cd50..fa0bd73 100644 --- a/interface.go +++ b/interface.go @@ -20,7 +20,7 @@ var SendRequest func(ctx context.Context, request *Request, timeout time.Duration) (res *Response, chunks <-chan []byte, chunksError *error, err error) // SendRequest2 used by router and app, sends a message to a given queue -// err is not nil -> NATS-related error occured before or during reading the first response packet. Sections and secError are nil, res must be ignored +// err is not nil -> NATS-related error occurred before or during reading the first response packet. Sections and secError are nil, res must be ignored // timeout means timeout during reading Response or ISection // sections not nil -> // - res must be ignored @@ -50,11 +50,11 @@ var SendParallelResponse func(ctx context.Context, sender interface{}, chunks <- // Result of Close var SendParallelResponse2 func(ctx context.Context, sender interface{}) (rsender IResultSenderClosable) -// Depecated: use MetricCntSerialRequest +// Deprecated: use MetricCntSerialRequest // MetricSerialRequestCnt s.e. var MetricSerialRequestCnt uint64 -// DepecatedL use MetricDurSerialRequest +// Deprecated: use MetricDurSerialRequest // MetricSerialRequestDurNs s.e. var MetricSerialRequestDurNs uint64 diff --git a/utils.go b/utils.go index a29d164..2a5fe50 100644 --- a/utils.go +++ b/utils.go @@ -14,6 +14,8 @@ func CreateResponse(code int, message string) Response { // CreateErrorResponse creates *Response with given status code, error message and ContentType "text/plain" func CreateErrorResponse(code int, err error) Response { + x := MetricSerialRequestCnt + _ = x return Response{ StatusCode: code, Data: []byte(err.Error()),