19 lines
342 B
Go
19 lines
342 B
Go
|
|
// Code generated by hertz generator.
|
||
|
|
|
||
|
|
package handler
|
||
|
|
|
||
|
|
import (
|
||
|
|
"context"
|
||
|
|
|
||
|
|
"github.com/cloudwego/hertz/pkg/app"
|
||
|
|
"github.com/cloudwego/hertz/pkg/common/utils"
|
||
|
|
"github.com/cloudwego/hertz/pkg/protocol/consts"
|
||
|
|
)
|
||
|
|
|
||
|
|
// Ping .
|
||
|
|
func Ping(ctx context.Context, c *app.RequestContext) {
|
||
|
|
c.JSON(consts.StatusOK, utils.H{
|
||
|
|
"message": "pong",
|
||
|
|
})
|
||
|
|
}
|