2017-08-19 05:06:05 +02:00
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
2019-10-25 00:27:02 +02:00
|
|
|
"github.com/kataras/iris/v12/_benchmarks/iris-mvc/controllers"
|
2017-12-16 05:38:28 +01:00
|
|
|
|
2019-10-25 00:27:02 +02:00
|
|
|
"github.com/kataras/iris/v12"
|
|
|
|
"github.com/kataras/iris/v12/mvc"
|
2017-08-19 05:06:05 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
func main() {
|
|
|
|
app := iris.New()
|
2017-12-19 22:40:42 +01:00
|
|
|
mvc.New(app.Party("/api/values/{id}")).
|
2017-12-27 03:15:41 +01:00
|
|
|
Handle(new(controllers.ValuesController))
|
2017-12-19 22:40:42 +01:00
|
|
|
|
2020-02-29 13:18:15 +01:00
|
|
|
app.Listen(":5000")
|
2017-08-19 05:06:05 +02:00
|
|
|
}
|
2017-12-16 16:57:20 +01:00
|
|
|
|
|
|
|
// +2MB/s faster than the previous implementation, 0.4MB/s difference from the raw handlers.
|