Documentation ¶
Index ¶
- Constants
- func CalculateHTTPStatusCode(err error) int
- func SetUpHealthCheck(server *gin.Engine)
- func SetUpIndexPage(server *gin.Engine)
- func SetUpPrometheus(server *gin.Engine)
- func SetUpSwagger(server *gin.Engine)
- func URLParamsToFilter(c *gin.Context, filter interface{}, fields map[string]int) (size int, page int, err error)
- type HTTPResult
Constants ¶
View Source
const ( MaxSize = 500 FirstPage = 0 SizeURLParamName = "size" PageURLParamName = "page" )
View Source
const (
HealthCheckURL = "/health"
)
Variables ¶
This section is empty.
Functions ¶
func CalculateHTTPStatusCode ¶
We should develop a custom exception on the repository layer. But we rely on kubernetes exceptions for now. TODO: implement Legion exceptions
func SetUpHealthCheck ¶
func SetUpIndexPage ¶
func SetUpPrometheus ¶
func SetUpSwagger ¶
Types ¶
type HTTPResult ¶
type HTTPResult struct { // Success of error message Message string `json:"message"` }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.