João Almeida

Results 4 comments of João Almeida

Maybe the way to go would be to have both: `level` for the level number and `level_name` for the respective name, ideally by default.

Hey @stuart-mclaren, My usecase is the following: ```golang opNameFn := ginhttp.OperationNameFunc(func(r *http.Request) string { return fmt.Sprintf("%s:%s", strings.ToLower(r.Method), r.RequestURI) }) errorFn := ginhttp.MWErrorFunc(func(ctx *gin.Context) bool { return ctx.Writer.Status() >= 500 })...

How about [this](https://github.com/opentracing-contrib/go-gin/pull/4/commits/981e877abd9f559d7c17a41c46110cb7050b6de3)? Basically it doesn't set a default and only calls the error func if it was explicitly set on the project.

I see your point. Would you suggest having a more generic after-request function similar to `spanObserver` then? You also suggested implementing a separate middleware. It would have to be a...