Пример #1
0
func init() {
	var err error

	internalError, err = bencode.EncodeString(&errorResponse{
		MinimumInterval: 60,
		Interval:        300,
		Reason:          "Internal error. Please try again later.",
	})
	if err != nil {
		panic("Error setting up internalError: " + err.Error())
	}

	app.Get("/announce", app.CreateHandler(run))
}
Пример #2
0
func init() {
	app.Get("/_ah/warmup", app.CreateHandler(warmup))
}
Пример #3
0
func init() {
	app.Start()
	app.Get("/index", index)
	app.Post("/request", request)
	app.Get("/request", index)
}
Пример #4
0
func init() {
	app.Get("/_cron/expire", app.CreateHandler(expire))
}