Skip to content

Commit

Permalink
enhance: [2.5] serializes the resp body and attach some details (#39401)
Browse files Browse the repository at this point in the history
issue: #37611 
pr: #39140

Signed-off-by: lixinguo <[email protected]>
Co-authored-by: lixinguo <[email protected]>
  • Loading branch information
smellthemoon and lixinguo authored Jan 20, 2025
1 parent ff53d4f commit e4c6ef9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion internal/distributed/proxy/httpserver/timeout_middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,11 @@ import (
"github.com/gin-gonic/gin"

mhttp "github.com/milvus-io/milvus/internal/http"
"github.com/milvus-io/milvus/pkg/util/merr"
)

func defaultResponse(c *gin.Context) {
c.String(http.StatusRequestTimeout, "timeout")
c.JSON(http.StatusRequestTimeout, gin.H{HTTPReturnCode: merr.TimeoutCode, HTTPReturnMessage: "request timeout"})
}

// BufferPool represents a pool of buffers.
Expand Down

0 comments on commit e4c6ef9

Please sign in to comment.