mirror of
https://github.com/kataras/iris.git
synced 2025-12-23 12:57:05 +00:00
remove experimental-handlers examples, users should visit github.com/iris-contrib/middleware instead, let's not have duplications
Former-commit-id: 72754683d1bcd4325b5fcd9f57c6cb87f1d7337d
This commit is contained in:
@@ -1,24 +0,0 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/kataras/iris"
|
||||
|
||||
"github.com/iris-contrib/middleware/newrelic"
|
||||
)
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
config := newrelic.Config("APP_SERVER_NAME", "NEWRELIC_LICENSE_KEY")
|
||||
config.Enabled = true
|
||||
m, err := newrelic.New(config)
|
||||
if err != nil {
|
||||
app.Logger().Fatal(err)
|
||||
}
|
||||
app.Use(m.ServeHTTP)
|
||||
|
||||
app.Get("/", func(ctx iris.Context) {
|
||||
ctx.Writef("success!\n")
|
||||
})
|
||||
|
||||
app.Run(iris.Addr(":8080"))
|
||||
}
|
||||
Reference in New Issue
Block a user