Documentation
¶
Index ¶
- Constants
- func GenerateMessageCode(width int) string
- func GetFreePort() (int, error)
- func GetUUID() string
- func GracefulExit()
- func HandleGrpcError(c *gin.Context, err error)
- func HandleValidatorError(c *gin.Context, err error)
- func Marshal(data any) []byte
- func NewRestyClient(ctx context.Context, reqHeaders map[string]string, reqBody []byte) *resty.Request
- func Paginate(page, pageSize int) func(db *gorm.DB) *gorm.DB
- type JWT
Constants ¶
View Source
const (
SIGNING_KEY = "EHNo3Cwyph*XbYlFJS^WL@&0#r#D1B%W"
)
Variables ¶
This section is empty.
Functions ¶
func GenerateMessageCode ¶
func GetFreePort ¶
获取一个空闲端口,范围在49152-65535 熟知端口号:0-1023;已登记端口号:1024-49151;临时端口号:49152-65535
func HandleValidatorError ¶
HandleValidatorError 处理验证器的error
func NewRestyClient ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.