Skip to content

Releases: grpc-ecosystem/grpc-gateway

v2.7.2

16 Dec 01:09
Compare
Choose a tag to compare

What's Changed

  • Log warning if HeaderMatcherFunc passes malformed HTTP headers to grpc server by @MakDon in #2455
  • Fixes #407 and #1700 - google.api.http path parameter constraints and multiple HTTP path/method endpoint support by @betmix-matt in #2461
    This fixes a long standing issue with OpenAPI spec generation in the face of complex path parameter use

New Contributors

Full Changelog: v2.7.1...v2.7.2

v2.7.1

02 Dec 03:30
432b7f7
Compare
Choose a tag to compare

What's Changed

  • Replace "github.com/ghodss/yaml" with "sigs.k8s.io/yaml" by @slntopp in #2436
  • build: upgrade go directive in go.mod to 1.17 by @Juneezee in #2443
  • Revert "support grpc.ClientConnInterface in RegisterXXXHandler (#2398)" by @shane-kerr in #2444

New Contributors

Full Changelog: v2.7.0...v2.7.1

v2.7.0

20 Nov 15:15
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v2.6.0...v2.7.0

v2.6.0

08 Sep 00:55
f60dfa5
Compare
Choose a tag to compare

Changes in this release

Major features in this release include:

  • The ability to auto-generate the x-nullable field from proto3 optional in openapiv2 contributed by Ken Brownfield (@irridia) in #2215
  • More comprehensive openapiv2 name generation options contributed by @alperengozeten and Malte Isberner (@misberner) in #2310

As well as various bug fixes, including the auto generation of the Www-Authenticate header when returning an 401 Unauthorized error (#2314), better google.protobuf.Any representation in openapiv2 files (#2292) and much more.

This is also the first release to automatically publish the Protobuf plugins to the Buf Schema Registry. See https://buf.build/grpc-ecosystem/plugins. These can be used together with the new buf generate remote plugins feature: https://docs.buf.build/configuration/v1/buf-gen-yaml#name-or-remote. An example buf.gen.yaml using these new plugins looks like this:

version: v1
plugins:
  - remote: buf.build/library/plugins/go:v1.27.1-1
    out: gen/go
    opt: paths=source_relative
  - remote: buf.build/library/plugins/go-grpc:v1.1.0-2
    out: gen/go
    opt: paths=source_relative
  - remote: buf.build/grpc-ecosystem/plugins/grpc-gateway:v2.6.0-1
    out: gen/go
    opt: paths=source_relative
  - remote: buf.build/grpc-ecosystem/plugins/openapiv2:v2.6.0-1
    out: gen/openapiv2

v2.5.0

22 Jun 01:53
f238f78
Compare
Choose a tag to compare

Changes in this release

This release adds support for extracting the HTTP path for an incoming request through the request context. Thanks to @0daryo for the contribution!

Note that this release slightly changes the behavior of the generator, so you must ensure that you are using the new version of the runtime library after updating the generator to this new version.

v2.4.0

28 Apr 00:08
74ecd1d
Compare
Choose a tag to compare

This release adds support for customizing routing error HTTP status codes. Thanks to @electrofelix for the contribution!

Other changes

New Contributors

Full Changelog: v2.3.0...v2.4.0

v2.3.0

25 Feb 18:33
Compare
Choose a tag to compare

This release migrates our internal generation strategy to using buf, and also updates the installation instructions to instruct users how to use buf to manage the googleapis dependencies in their own projects. If you are used to copying the third_party folder for your dependencies, you are now encouraged to check out the usage instructions again to see how to use buf to manage your dependencies instead.

The boilerplate repo contains an example.

v2.3.0 (2021-02-25)

Full Changelog

Implemented enhancements:

  • Support optional annotation in proto3 files in generators #1278

Fixed bugs:

  • grpc-gateway v2 misreads grpc protobuf field_mask behavior, breaks existing valid behavior #1766

Closed issues:

  • grpc-gateway service run error #1996
  • ../proto/api/proto/service.pb.gw.go:129:95: cannot use *StringMessage value as type protoreflect.ProtoMessage in return argument: *StringMessage does not implement protoreflect.ProtoMessage (missing ProtoReflect method) #1989
  • Grpc healthcheck docs are unclear #1977
  • Gateway protoc does not generate protoreflect.ProtoMessage messages #1959
  • [bazel] Got "missing strict dependencies" when use protoc-gen-grpc-gateway as bazel-gazelle grpc compiler #1941
  • Non official implementation #1940
  • Empty fields included in response. #1871

Merged pull requests:

  • fix(deps): update module google.golang.org/grpc to v1.36.0 (master) #1999 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to 063164c (master) #1998 (renovate[bot])
  • chore(deps): update dependency com_google_protobuf to v3.15.2 (master) #1995 (renovate[bot])
  • chore(deps): update bufbuild/buf docker tag to v0.37.1 (master) #1994 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to 22b48be (master) #1993 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to 3e1e516 (master) #1991 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to aa3ee6e (master) #1990 (renovate[bot])
  • chore(deps): update dependency com_google_protobuf to v3.15.1 (master) #1987 (renovate[bot])
  • fix(deps): update golang.org/x/oauth2 commit hash to 9bb9049 (master) #1986 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to d891e3c (master) #1985 (renovate[bot])
  • chore(deps): update dependency com_google_protobuf to v3.15.0 (master) #1984 (renovate[bot])
  • fix(deps): update golang.org/x/oauth2 commit hash to ba52d33 (master) #1983 (renovate[bot])
  • fix(deps): update google.golang.org/genproto commit hash to fe80b38 (master) #1982 (renovate[bot])
  • chore(deps): update google.golang.org/genproto commit hash to c185827 (master) #1979 (renovate[bot])
  • Use base64.URLEncoding for []byte parameters in query #1978 (tvoll)
  • chore(deps): update golang docker tag to v1.16.0 (master) #1976 (renovate[bot])
  • chore(deps): update golang.org/x/oauth2 commit hash to 16ff188 (master) #1974 (renovate[bot])
  • adding UnimplementedGreeterServer to server struct #1973 (nwandabridges)
  • [Bazel] Update protobuf, rules_go and gazelle #1972 (aaliddell)
  • Migrate generation, linting to buf #1971 (johanbrandhorst)
  • chore(deps): update google.golang.org/genproto commit hash to e7f2df4 (master) #1970 (renovate[bot])
  • chore(deps): update google.golang.org/genproto commit hash to 4ccc9a5 (master) #1969 (renovate[bot])
  • Bump nokogiri from 1.10.10 to 1.11.1 in /docs #1967 (dependabot[bot])
  • docs/Gemfile.lock: Fix dependabot security warning #1966 (ivucica)
  • chore(deps): update google.golang.org/genproto commit hash to 3a9a48d (master) #1965 (renovate[bot])
  • chore(deps): update golang.org/x/oauth2 commit hash to 6667018 (master) #1964 (renovate[bot])
  • Update CONTRIBUTING.md on release description #1960 (adambabik)
  • gen-grpc-gateway, gen-openapiv2: add support for proto3 optional #1951 (adambabik)
  • FAQ Adding related projects to the documentation #1946 (rodoufu)

v2.2.0

09 Feb 17:56
Compare
Choose a tag to compare

v2.2.0 (2021-02-09)

Full Changelog

Fixed bugs:

  • [protoc-gen-openapiv2] [BUG] Incorrect handling of non-wildcard google.api.http.body when using field_behaviour annotation #1937
  • Duplicate tags seen in Swagger Specification #1913
  • Poor error message when using message in path parameter #1863

Closed issues:

  • can we add HTTPStatusFromCode to mux? #1954
  • Missing types in generated gw.go file for C++ server #1942
  • What is the recommend way to bind 3rd party APIs (e.g. Health/Check to /healthzf #1931
  • Patch request with field_masks #1930
  • Working from the helloworld example but getting an error on HTTP requests: grpc: the client connection is closing. Would like to improve the docs. #1924
  • Action Required: Fix Renovate Configuration #1918
  • F #1917
  • Is any method to access the raw request body in metadata? #1908
  • Custom incoming header matcher isn't working as expected #1902
  • README.md links to https://pkg.go.dev/github.com/golang/protobuf/jsonpb which does not exist #1901
  • Is it possible to setup CORS? #1889

Merged pull requests:

v2.1.0

07 Jan 11:47
c989b80
Compare
Choose a tag to compare

v2.1.0 (2021-01-07)

Full Changelog

Implemented enhancements:

  • protoc-gen-grpc-gateway: can't generate gateway stubs for multiple packages in one go #1612
  • Addition of Prettier GitHub action to prettified the markdown files #1575
  • add support for field_behavior options on swagger plugin #1806 (ewhauser)

Fixed bugs:

  • The "Use go templates" page is missing its actual go templates #1773
  • FieldMask Generation causes a 400 when a google.protobuf.Struct field has populated values #1570
  • Support openapiv2_tag option in swagger generator #690

Closed issues:

  • Ignore some fields in HTTP Response and OpenAPI #1886
  • Using runtime.WithMarshalerOption() breaks swagger docs #1882
  • Data is Getting Encoded while returning response as HTML #1880
  • jsonPB is not supporting in grpc gateway v2 migration #1878
  • Move generator and descriptor packages into the public API #1877
  • Add -module flag to protoc-gen-openapiv2 plugin #1876
  • Load Balancing with multiple instances of a grpc-server. #1875
  • Building with Bazel not compatible when using Gazelle and disable_global #1847
  • Unexpected response on /v2/example/errorwithdetails #1842
  • openapi_configuration option in protoc_gen_openapiv2 Bazel rule fails. #1838
  • Link to v2 migration guide broken #1836
  • add header in http.Handler,but not take effect #1835
  • protoc-gen-openapiv2 rule should expose all of the relevant flags available #1831
  • if there a flag set the metadata first letter not change to uppower #1830
  • Clarification about return Access-Control-Allow-Origin header #1827
  • generate\_unbound\_methods option and FieldMask fields don't work together. #1816
  • openapiv2: panic when SecurityRequirement is missing a value #1811
  • Cannot resolve import 'google/api/http.proto' #1809
  • add version information at compile-time #1803
  • 🚀 protoc\_gen\_openapiv2 should allow to pass generate\_unbound\_methods option #1792
  • Can't generate python client #1785
  • Issue with converting to the bytes data type #1781
  • Possible way to access request header key,value #1780
  • Run demo failed! #1777
  • protoc-gen-swagger: Implement Response Header(s) object, Implement Field Enum,Example&Format attributes #1729

Merged pull requests:

Read more

v1.16.0

28 Oct 10:30
094a6fe
Compare
Choose a tag to compare

The grpc-gateway v1 is in maintenance mode, you are encouraged to migrate to v2. Check out our v2 migration guide.

v1.16.0 (2020-10-28)

Full Changelog

Merged pull requests:

  • feat: protoc-gen-swagger: Implement Response Header(s) object, Implem… #1730 (elijah-roberts)