Skip to content

Commit

Permalink
fixed READMEs, removed unused error types and removed duplicated func…
Browse files Browse the repository at this point in the history
…tion in server
  • Loading branch information
DavidSubiros committed May 11, 2020
1 parent 2459199 commit 04a7f64
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 35 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func main() {

### Server

The Serer extends the default golang HTTP Server by adding a requestID and logger middleware. By default it handles the OSSignals, and it has a default shutdown timeout of 10 seconds.
The Server extends the default golang HTTP Server by adding a requestID and logger middleware. By default it handles the OSSignals, and it has a default shutdown timeout of 10 seconds.

This Server is intended to be used by all ONS digital publishing services that require to serve HTTP. The following example shows how to use the Server:

Expand Down
2 changes: 1 addition & 1 deletion handlers/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The mapping is done using enumeration of possible header and cookie keys, and th

## Usage

- Read a header from a request and add its value to the output request context:
- Read a header from a request and add its value to the underlying request context:

```go
// Access token
Expand Down
28 changes: 0 additions & 28 deletions http/errors.go

This file was deleted.

5 changes: 0 additions & 5 deletions http/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,6 @@ func (s *Server) Shutdown(ctx context.Context) error {
return s.Server.Shutdown(ctx)
}

// Close is simply a wrapper around Shutdown that enables Server to be treated as a Closable
func (s *Server) Close(ctx context.Context) error {
return s.Shutdown(ctx)
}

func (s *Server) listenAndServe() error {

s.prep()
Expand Down

0 comments on commit 04a7f64

Please sign in to comment.