From aa16e32cbfeecd5ee0da5ce8ccae03fa8b0e386f Mon Sep 17 00:00:00 2001 From: Stephan Renatus Date: Thu, 12 Oct 2017 11:14:44 +0200 Subject: [PATCH] protoc-gen-grpc-gateway: flip request_context default to true Follow up to #473. Signed-off-by: Stephan Renatus --- .travis.yml | 2 +- protoc-gen-grpc-gateway/main.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 9ca6f5d7020..eea6dd82026 100644 --- a/.travis.yml +++ b/.travis.yml @@ -35,4 +35,4 @@ env: - "PATH=$PATH:$HOME/local/bin" matrix: - GATEWAY_PLUGIN_FLAGS= - - GATEWAY_PLUGIN_FLAGS=request_context=true + - GATEWAY_PLUGIN_FLAGS=request_context=false diff --git a/protoc-gen-grpc-gateway/main.go b/protoc-gen-grpc-gateway/main.go index cf365f249e1..917f5cf6d9b 100644 --- a/protoc-gen-grpc-gateway/main.go +++ b/protoc-gen-grpc-gateway/main.go @@ -24,7 +24,7 @@ import ( var ( importPrefix = flag.String("import_prefix", "", "prefix to be added to go package paths for imported proto files") - useRequestContext = flag.Bool("request_context", false, "determine whether to use http.Request's context or not") + useRequestContext = flag.Bool("request_context", true, "determine whether to use http.Request's context or not") allowDeleteBody = flag.Bool("allow_delete_body", false, "unless set, HTTP DELETE methods may not have a body") )