You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
433 B
25 lines
433 B
package http |
|
|
|
import ( |
|
"go-common/app/interface/main/broadcast/conf" |
|
"go-common/library/log" |
|
bm "go-common/library/net/http/blademaster" |
|
) |
|
|
|
// Init init http. |
|
func Init(c *conf.Config) { |
|
engine := bm.DefaultServer(c.HTTP) |
|
outerRouter(engine) |
|
if err := engine.Start(); err != nil { |
|
log.Error("bm.DefaultServer error(%v)", err) |
|
panic(err) |
|
} |
|
} |
|
|
|
func outerRouter(e *bm.Engine) { |
|
e.Ping(ping) |
|
} |
|
|
|
func ping(c *bm.Context) { |
|
|
|
}
|
|
|