Skip to content
Myr

Merge pull request #575 from Saser/develop

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Fix typos and improve wording

authored by Javier Provecho Fernandez · committed by Javier Provecho Fernandez · parents dc85514, 61729ed · Browse files · 1 file+5 added−9 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+5 added−9 removed

  • other:+5 added−9 removed

1 file+5 added−9 removed

modified:README.md+5 added-9 removed
218 unmodified lines
219```220221### Another example: upload file222223Reference issue [#548](https://github.com/gin-gonic/gin/issues/548)223References issue [#548](https://github.com/gin-gonic/gin/issues/548).224225```go226func main() {227 router := gin.Default()
71 unmodified lines
299 r.GET("/benchmark", MyBenchLogger(), benchEndpoint)300301 // Authorization group302 // authorized := r.Group("/", AuthRequired())303 // exactly the same than:303 // exactly the same as:304 authorized := r.Group("/")305 // per group middleware! in this case we use the custom created306 // AuthRequired() middleware just in the "authorized" group.307 authorized.Use(AuthRequired())
336 unmodified lines
644 go func() {645 // simulate a long task with time.Sleep(). 5 seconds646 time.Sleep(5 * time.Second)647648 // note than you are using the copied context "c_cp", IMPORTANT648 // note that you are using the copied context "cCp", IMPORTANT649 log.Println("Done! in path " + cCp.Request.URL.Path)650 }()651 })652
39 unmodified lines
692693#### Graceful restart or stop694695Do you want to graceful restart or stop your web server?696There be some ways.696There are some ways this can be done.697698We can using fvbock/endless to replace the default ListenAndServe698We can use [fvbock/endless](https://github.com/fvbock/endless) to replace the default `ListenAndServe`. Refer issue [#296](https://github.com/gin-gonic/gin/issues/296) for more details.699700Refer the issue for more details:701702https://github.com/gin-gonic/gin/issues/296703700```go701router := gin.Default()702router.GET("/", handler)703// [...]
6 unmodified lines