Skip to content

owenthereal/negroni-gorelic

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

negroni-gorelic

New Relic middleware for the negroni framework.

Usage

package main

import (
	"fmt"
	"net/http"

	"github.com/codegangsta/negroni"
	"github.com/jingweno/negroni-gorelic"
)

func main() {
	r := http.NewServeMux()
	r.HandleFunc(`/`, func(w http.ResponseWriter, r *http.Request) {
		w.WriteHeader(http.StatusOK)
		fmt.Fprintf(w, "success!\n")
	})

	n := negroni.New()
	n.Use(negronigorelic.New("NEW_RELIC_LICENSE_KEY", "example-app", true))
	n.UseHandler(r)

	n.Run(":3000")
}

See a running example.

Credits

A shout out to @yvasiyarov for his awesome work of gorelic.

License

negroni-gorelic is released under the MIT license. See LICENSE.md.

About

negroni_gorelic is NewRelic middleware for negroni framework.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages