diff --git a/README.md b/README.md index 5e613ef..4f20407 100644 --- a/README.md +++ b/README.md @@ -224,8 +224,6 @@ When deploying to DigitalOcean, you will need to configure the following environ | `SMTP_USERNAME` | `Secret` | No | The username for your SMTP server. | | `SMTP_PASSWORD` | `Secret` | No | The password for your SMTP server. | | `SMTP_FROM_EMAIL` | `String` | No | The email address to send emails from. | -| `NEW_RELIC_KEY` | `Secret` | No | Your New Relic license key for application monitoring. | -| `NEW_RELIC_NAME` | `String` | No | The name of your application in New Relic. | | `SENTRY_URL` | `Secret` | No | The DSN for Sentry error tracking. | --- diff --git a/config.go b/config.go index ad15ea5..eb1dd9d 100644 --- a/config.go +++ b/config.go @@ -22,12 +22,6 @@ func init() { api.ENV = v deps.ENV = v } - if v, exists := os.LookupEnv("NEW_RELIC_KEY"); exists { - api.NewRelicKey = v - } - if v, exists := os.LookupEnv("NEW_RELIC_NAME"); exists { - api.NewRelicName = v - } if v, exists := os.LookupEnv("MONGO_URL"); exists { deps.MongoURL = v } diff --git a/go.mod b/go.mod index dabba0e..b45a09b 100644 --- a/go.mod +++ b/go.mod @@ -27,7 +27,6 @@ require ( github.com/markbates/goth v1.53.0 github.com/matcornic/hermes/v2 v2.0.2 github.com/mikespook/gorbac v2.1.0+incompatible - github.com/newrelic/go-agent v2.11.0+incompatible github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 github.com/olebedev/config v0.0.0-20190528211619-364964f3a8e4 github.com/op/go-logging v0.0.0-20160315200505-970db520ece7 diff --git a/go.sum b/go.sum index ab1c202..757dbf1 100644 --- a/go.sum +++ b/go.sum @@ -203,8 +203,6 @@ github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjY github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe h1:iruDEfMl2E6fbMZ9s0scYfZQ84/6SPL6zC8ACM2oIL0= github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= github.com/mrjones/oauth v0.0.0-20180629183705-f4e24b6d100c/go.mod h1:skjdDftzkFALcuGzYSklqYd8gvat6F1gZJ4YPVbkZpM= -github.com/newrelic/go-agent v2.11.0+incompatible h1:LTIMkaiTqAE9HoWiBZt4TPI0AYA+GmjqYTO9cEHQios= -github.com/newrelic/go-agent v2.11.0+incompatible/go.mod h1:a8Fv1b/fYhFSReoTU6HDkTYIMZeSVNffmoS726Y0LzQ= github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 h1:zYyBkD/k9seD2A7fsi6Oo2LfFZAehjjQMERAvZLEDnQ= github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= diff --git a/modules/api/init.go b/modules/api/init.go index 2d22638..d136598 100644 --- a/modules/api/init.go +++ b/modules/api/init.go @@ -10,8 +10,6 @@ import ( "github.com/facebookgo/inject" "github.com/gin-gonic/contrib/sessions" "github.com/gin-gonic/gin" - newrelic "github.com/newrelic/go-agent" - "github.com/newrelic/go-agent/_integrations/nrgin/v1" "github.com/op/go-logging" handle "github.com/tryanzu/core/board/legacy" "github.com/tryanzu/core/board/realtime" @@ -27,8 +25,6 @@ var ( DEBUG bool = true ENV string = "dev" TemplatesGlob string = "./static/templates/**/*" - NewRelicKey string - NewRelicName string = "anzu" log = logging.MustGetLogger("http-api") ) @@ -58,16 +54,6 @@ func (module *Module) Run(bindTo string) { router.Use(gin.Recovery()) router.LoadHTMLGlob(TemplatesGlob) - if len(NewRelicKey) > 0 { - cfg := newrelic.NewConfig(NewRelicName, NewRelicKey) - cfg.Logger = newrelic.NewLogger(os.Stdout) - app, err := newrelic.NewApplication(cfg) - if err != nil { - log.Errorf("error while initializing new relic err=%v", err) - } else { - router.Use(nrgin.Middleware(app)) - } - } // Middlewares setup router.Use(sessions.Sessions("session", store))