Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ProtectedRouter ¶
type ProtectedRouter struct { Echo *echo.Echo Name string ServiceComponent *services.ServiceComponent }
ProtectedRouter manages the public API router and its dependencies.
func InitProtectedAPIRouter ¶
func InitProtectedAPIRouter(env *config.SEnv, services *services.ServiceComponent) *ProtectedRouter
func (*ProtectedRouter) Init ¶
func (r *ProtectedRouter) Init()
Init initializes the Echo instance for the router.
func (*ProtectedRouter) Start ¶
func (r *ProtectedRouter) Start(host string, port string)
Start the Echo server
type PublicRouter ¶
type PublicRouter struct { Echo *echo.Echo Name string ServiceComponent *services.ServiceComponent RouteTableMapping map[string]string }
PublicRouter manages the public API router and its dependencies.
func NewPublicRouter ¶
func NewPublicRouter(env *config.SEnv, services *services.ServiceComponent) *PublicRouter
NewPublicRouter creates and initializes a new PublicRouter instance.
func (*PublicRouter) Start ¶
func (r *PublicRouter) Start(host, port string)
Start runs the Echo server and handles graceful shutdown.
type Router ¶
type Router struct { Echo *echo.Echo Name string }
Router echo
func (*Router) RegisterMiddleware ¶
func (r *Router) RegisterMiddleware(middleware echo.MiddlewareFunc)
RegisterMiddleware registers midlleware
func (*Router) RegisterPreMiddleware ¶
func (r *Router) RegisterPreMiddleware(middleware echo.MiddlewareFunc)
RegisterPreMiddleware registers pre middleware
Click to show internal directories.
Click to hide internal directories.