Commit Graph

646 Commits

Author SHA1 Message Date
tottoto 2dd09c02bd chore: Fix clippy lint (#1181) 2022-12-13 11:29:29 -05:00
Rafael Lemos 3076e8251e feat(types): add support for DebugInfo error message type (#1179) 2022-12-12 14:11:09 -05:00
tottoto d00fd0838b chore: Update cargo-deny config (#1169) 2022-12-06 14:40:24 -05:00
tottoto df8dd896da chore(examples): Remove dummy echo implementation (#1178) 2022-12-05 12:08:41 -05:00
Lucio Franco 1efabf0003 chore: Fix CI msrv workflow (#1176) 2022-12-01 12:22:22 -05:00
Rafael Lemos 6cdb3d4685 feat(types): Add gRPC Richer Error Model support (RetryInfo) (#1095)
Add the code related to richer error model support to a new
`richer_error` module. This improves readability and hopefully will
make it easier to add new features to `tonic-types` in the future.
2022-12-01 11:48:06 -05:00
tottoto f7499c8a6a chore: Bump msrv to 1.60 (#1171) 2022-12-01 11:41:31 -05:00
bouzuya 95e8c8bdbb chore: Internal refactor to remove repeitition (#1144) 2022-11-30 14:32:49 -05:00
tottoto 5c8a5d709c chore(examples): Fix blocking-server (#1173) 2022-11-30 13:38:39 -05:00
Lucio Franco d6f0567818 chore: Prepare 0.8.4 (#1170) 2022-11-29 14:22:54 -05:00
Alex Pearson c7476fff42 fix(build): Fix CodeGen8uilder typo (#1165) (#1166) 2022-11-29 14:01:27 -05:00
tottoto 076a81ce6e chore(examples): Update to listenfd 1.0 (#1168) 2022-11-29 14:00:20 -05:00
tottoto 8318e756d4 chore(interop): Update to console 0.15 (#1167) 2022-11-29 14:00:10 -05:00
Lucio Franco dc079c12bf chore: Prepare v0.8.3 release (#1164) 2022-11-28 13:35:48 -05:00
Joan Antoni RE b53b387ced Fix some struct references on transport channel doc (#1152) 2022-11-28 12:27:50 -05:00
Lucio Franco c4525ba6ad feat(build): Add CodeGenBuilder (#1154)
This commit adds a new `CodeGenBuilder` that replaces the
client/server generate fn with a builder stlye that allows
adding config items in an non-breaking way. This also deprecates
both of the client/server generate fn in favor of the builder ones.
2022-11-28 12:10:44 -05:00
David Pedersen 542c5b37dc chore: update to axum 0.6.0 (#1155) 2022-11-28 10:40:46 -05:00
tottoto b65b52baf0 chore(interop): Update clap to 4.0.26 (#1162) 2022-11-28 10:39:34 -05:00
Artem Vorotnikov 933f560735 reflection: commit generated code (#1151) 2022-11-16 16:13:59 -05:00
Marco Neumann 33e22bbc5e fix: do not panic while encoding oversized bodies (#1142)
Fixes #1141.
2022-11-10 11:07:35 -05:00
Gian Marco Gherardi 3a542709a7 chore: Added protoc installation instruction for Windows (#1103) 2022-11-09 15:39:23 -05:00
bouzuya e188521149 feat(build): Add disable_comments option (#1127) 2022-11-08 11:08:19 -05:00
LIU JIE c9cadd4b23 chore: remove patch caused cargo error (#1140) 2022-11-08 10:17:54 -05:00
Aleksander 7153289b51 fix(reflection, health): Remove transport feature (#1112) 2022-11-07 12:00:17 -05:00
f82488c499 chore: Fix type in routeguide (#1136) 2022-11-07 10:58:11 -05:00
Lucio Franco 1f5bc9b9d5 feat(build): Add build_transport builder option (#1130) 2022-11-04 11:04:23 -04:00
Lucio Franco 6667ace032 Update minimal version of pin-project (#1132) 2022-11-01 12:53:18 -04:00
Francesco Guardiani a98d719fb4 feat(web): Removed Cors impl and replaced with tower-http's CorsLayer (#1123)
Fix #1122, see the issue for more details.

Signed-off-by: slinkydeveloper <francescoguard@gmail.com>
2022-10-31 13:56:36 -04:00
Francesco Guardiani 40536dc134 feat(web): Implement tower::Layer for tonic_web::Config (#1119)
Signed-off-by: slinkydeveloper <francescoguard@gmail.com>
2022-10-28 13:59:01 -04:00
Francesco Guardiani b409ddd478 feat: Expose Request#into_parts and Request#from_parts (#1118)
Signed-off-by: slinkydeveloper <francescoguard@gmail.com>
2022-10-19 10:25:21 -04:00
Nicolas Guiard 64e29c621b test(tonic-web): fix grpc_web_content_types() test not covering all cases (#1113) 2022-10-18 13:25:24 -04:00
Will-Low be1fe02e6e chore: bumping dependency axum to version 0.5.16 (#1110) 2022-10-15 10:18:19 -04:00
John Howard 675b3b2e75 Create SECURITY.md (#1106)
* Create SECURITY.md

Fixes https://github.com/hyperium/tonic/issues/1100

* Update SECURITY.md
2022-10-11 10:57:19 -04:00
walter 0b03b30ccc feat(transport): add from_listener for TcpIncoming (#1093) 2022-10-03 07:08:43 -04:00
CaliViking 3663faf32d Update README.md (#1090)
I believe that the reference to Rust Analyzer build script setting is incorrect. Please verify before accepting.
2022-09-28 15:47:32 -04:00
Lucio Franco a7e29c9213 chore: Prepare 0.8.2 release (#1089) 2022-09-28 10:56:22 -04:00
Lucio Franco cddd992666 fix(transport): Bump axum for CVE-2022-3212 (#1088) 2022-09-28 10:27:58 -04:00
Marek Kuskowski c1b08dffac feat(build): add cleanup-markdown feature flag (#1086) 2022-09-28 10:00:25 -04:00
Stephen Sampson 56ff45d9a3 feat: add Result<T> type alias for std::result::Result<T, tonic::Status> (#1085)
* add `Result<T>` type alias for `std::result::Result<T, tonic::Status>`

* Allow user to override the error type

Co-authored-by: David Pedersen <david.pdrsn@gmail.com>

* add rustdoc for `tonic::Result`

* cargo fmt

Co-authored-by: David Pedersen <david.pdrsn@gmail.com>
2022-09-26 12:24:33 -04:00
Rafael Lemos 3e40d819cf feat(types): Add gRPC Richer Error Model support (BadRequest) (#1068)
* types: add tonic as dependency, add error_details.proto

* types: add BadRequest support from flemosr/tonic-richer-error

* types: adjust code following suggestions

Adjustments following suggestions by @LucioFranco in https://github.com/hyperium/tonic/pull/1068.

Adjust style, remove unecessary prints, avoid glob imports, apply
`non_exhaustive` to `ErrorDetails` and `ErrorDetail`, avoid pub
fields in `ErrorDetails`, adjust
`WithErrorDetails::with_error_details_vec` args, add
`gen_details_bytes`.

* types: add generated protobuf code

As suggested by @LucioFranco in https://github.com/hyperium/tonic/pull/1068#discussion_r956117520.

This avoids the need for consumers to have `protoc` in their path.
Implemented following changes in https://github.com/hyperium/tonic/pull/1065.

* types: add custom metadata support

This allows consumers to provide custom metadata when creating a
`Status` with error details.

* types: adjust code following suggestions

Adjustments following suggestions by @LucioFranco in https://github.com/hyperium/tonic/pull/1068.

Move `error_details_vec` mod into `error_details` mod, adjust doc
comments, rename `WithErrorDetails` trait to `StatusExt`.
2022-09-21 15:12:45 -04:00
David Pedersen ee3d0dfe75 feat(tonic): impl Clone for Status using Arc (#1076) 2022-09-12 11:31:30 -04:00
Lucio Franco 5723681777 chore: Prepare 0.8.1 release (#1072) 2022-09-07 10:33:19 -04:00
Adam Chalmers 919d28b2b9 feat(transport): Expose hyper's H2 adaptive window on server (#1071)
Co-authored-by: Adam Chalmers <adamschalmers@gmail.com>
2022-09-06 14:37:20 -04:00
Joe Dahlquist 2a83f8ba1a expose Extensions::into_http and Status::from_error (#1067) 2022-08-24 16:04:26 -04:00
Markus Westerlind 523a55044f chore: Reduce how much code gets monomorphized (#1032) 2022-08-23 14:29:15 -04:00
Ben Sully 0a2a2f3ac5 tonic-health: commit generated code (#1065)
* tonic-health: commit generated code rather than generating at build time

This saves users from needing protoc available on their path if they're not
generating other tonic code at build time, either.

The generated modules can be regenerated by enabling the `gen-proto`
feature, which will trigger the relevant part of the build script.

* Check generated code for tonic-health matches in CI

* Use bootstrap test to generate/check validity of generated code

As suggested by @LucioFranco in https://github.com/hyperium/tonic/pull/1065\#discussion_r951580189.
This avoids the need for a feature which would show
up in docs.rs, and achieves the same goals via CI.
2022-08-23 10:31:37 -04:00
Masakazu Muraoka 2d66a0aa30 Update helloworld-tutorial.md (#1057)
grpcurl command have been run successfully with modifieded like above.
2022-08-15 10:33:01 -04:00
Lucio Franco 433c4ebd80 chore: Add missing changelog entry (#1055) 2022-08-09 11:29:32 -07:00
Opisthoteuthis agassizii fb840583d3 chore(docs): Update docs to mention new protoc requirements in tonic >= 0.8.0 (#1050) 2022-08-09 09:31:03 -07:00
Nick Ashley 9be4e2479d chore: Update docs to reflect changes to compression feature (#1046)
Co-authored-by: Lucio Franco <luciofranco14@gmail.com>
2022-08-02 09:38:08 -07:00