Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

Commit

Permalink
issue #113: review server layer
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilsk committed Oct 16, 2018
1 parent ad598ab commit 0c2069c
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 425 deletions.
4 changes: 2 additions & 2 deletions pkg/server/contract.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ type Service interface {
// HandleGetV1 handles an input request.
// Deprecated: TODO issue#version3.0 use SchemaEditor and gRPC gateway instead
HandleGetV1(context.Context, v1.GetRequest) v1.GetResponse
// HandlePostV1 handles an input request.
HandlePostV1(context.Context, v1.PostRequest) v1.PostResponse
// HandleInput handles an input request.
HandleInput(context.Context, v1.PostRequest) v1.PostResponse
}
167 changes: 0 additions & 167 deletions pkg/server/grpc/mock_storage_test.go

This file was deleted.

48 changes: 0 additions & 48 deletions pkg/server/internal_test.go

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func (s *Server) Input(rw http.ResponseWriter, req *http.Request) {
return
}
output := bytes.NewBuffer(make([]byte, 0, 1024))
resp := s.service.HandlePostV1(req.Context(), v1.PostRequest{
resp := s.service.HandleInput(req.Context(), v1.PostRequest{
Context: domain.InputContext{
Cookies: domain.FromCookies(req.Cookies()),
Headers: domain.FromHeaders(req.Header),
Expand Down
Loading

0 comments on commit 0c2069c

Please sign in to comment.