Commit Graph
47 Commits
Author SHA1 Message Date
37f6733f85 feat(transport): Add Router::into_service (#419)
Co-authored-by: Danny Hua <[email protected]>
2020-08-20 15:11:31 -04:00
Lucio FrancoandGitHub 73938e1e0a chore: Fix typo in uds example (#417)
Closes #350
2020-07-27 15:38:47 -04:00
Lucio FrancoandGitHub 62b8ab0b51 chore: Prepare 0.3.0 release (#399)
* chore: Prepare 0.3.0 release

* update changelog

* fix builds

* Update breaking changes
2020-07-13 13:00:54 -04:00
Harry BarberandGitHub 2b997b0c5f feat(transport): Add optional service methods (#275) 2020-07-10 12:39:52 -04:00
034c850254 examples: update to tracing 0.1.16, use #[instrument] (#354)
* examples: update to `tracing` 0.1.14, use `#[instrument]`

Now that `tracing-attributes`'s `#[instrument]` macro plays nicely with
`async-trait`, we can update the tracing example to use `instrument`.
This lets us simplify the events emitted in the example.

Signed-off-by: Eliza Weisman <[email protected]>

* feat(transport): Dynamic load balancing (#341)

* Fix typo (#356)

Co-authored-by: Dawid Nowak <[email protected]>
Co-authored-by: Paulo Duarte <[email protected]>
2020-07-10 11:59:18 -04:00
Lucio FrancoandGitHub c9b3c7f11c Fix hyper_warp example warnings (#390) 2020-07-10 11:28:13 -04:00
Tunahan KarlıbaşandGitHub 9c954e0908 Make the cast in Bidirectional stream smaller (#387)
Since we already define the type we can just use it instead of writing it again
2020-07-06 11:58:07 -04:00
Johan AnderssonandGitHub 3b9d6a6262 fix(transport): Propagate errors in tls_config instead of unwrap/panic (#385)
* Propagate errors in tls_config instead of unwrap

Ran into `tls_connector` failing and causing our app to panic and shutdown as it seems there wasn't any way to avoid panicking in `tls_config`.

So after talking to @LucioFranco briefly `tls_config` now returns a `Result` instead and propagates errors to the caller, where they can be handled.

* Fix compile warning when tls feature is disabled
2020-07-06 09:18:10 -04:00
Kaleb ElwertandGitHub 80e90e3b5d Add tower server example (#375)
Note that this also adds `impl From<Status> for http::Response<BoxBody>`
in order to make writing middleware which can return an error much
easier.
2020-06-22 12:04:02 -04:00
Taiki EndoandGitHub 5bda615632 fix: Remove uses of pin_project::project attribute (#367)
pin-project will deprecate the project attribute due to some unfixable
limitations.

Refs: https://github.com/taiki-e/pin-project/issues/225
2020-06-09 13:09:35 -04:00
Nick LawandGitHub 4f839107b9 chore(docs): fix incorrect proto path in helloworld tutorial (#368)
This change reverts #366. The `proto/` directory, as described in the guide,
is created under the root of the crate. Not under `src/`.

I've also included a fix to the `grpcurl` endpoint.
2020-06-09 13:08:39 -04:00
Paul-Sebastian ManoleandGitHub 02499fdfd3 chore: wrong path for call to compile_protos (#366)
Fixed wrong path "proto/helloworld.proto" for `compile_protos` first argument. `build.rs` being in the project root, means the correct path should be "src/proto/helloworld.proto".
2020-06-03 12:10:07 -04:00
Paulo DuarteandGitHub 253984f204 Fix typo (#356) 2020-05-18 17:09:46 -04:00
Dawid NowakandGitHub 85ae0a4733 feat(transport): Dynamic load balancing (#341) 2020-05-15 15:03:28 -04:00
thisKaiandGitHub f6ecaff0de chore(example): Autoreloading server example (#316)
* Create an example of an autoreloading server

* Document the autoreloading server example

* Format autoreloading server example

* Add note about cargo-watch in the examples readme
2020-04-09 17:55:53 -04:00
Lucio FrancoandGitHub 6f378e2bd0 chore: Prepare 0.2 release (#321)
Signed-off-by: Lucio Franco <[email protected]>
2020-04-01 14:34:51 -04:00
Spencer JudgeandGitHub b7860cc734 chore: Update blocking example drop order (#313) 2020-04-01 14:01:38 -04:00
Lucio FrancoandGitHub 3cba9f5f6f chore: Fix feature flags and build docs (#311)
Signed-off-by: Lucio Franco <[email protected]>
2020-03-30 12:02:10 -04:00
James NugentandGitHub da92dbf8aa feat(health): Add tonic-health server impl
This commit adds a new crate `tonic-health` which implements the
[standard GRPC Health Checking][checking] protocol.

Currently there is only a server implementation, though others have
alluded in the discussion in #135 that client implementations exist
which could also be imported as necessary.

A example server has also been added - once the client work is done a
client for this should be added also.

[checking]: https://github.com/grpc/grpc/blob/master/doc/health-checking.md

Fixes #135.
2020-03-30 09:33:02 -05:00
Lucio FrancoandGitHub 2e082f8b3e chore(build): Refactor codegen traits (#302)
Signed-off-by: Lucio Franco <[email protected]>
2020-03-29 12:57:11 -04:00
9e7d35a2d3 chore: Add blocknig server example (#277)
Co-authored-by: Lucio Franco <[email protected]>
2020-03-06 11:30:10 -05:00
Gyusun YeomandGitHub f65cda1ea0 feat(build): Decouple codgen from prost (#170) 2020-03-01 13:52:31 -05:00
Lucio FrancoandGitHub e2bff8f13e chore(docs): Add warp + tonic example (#268)
Signed-off-by: Lucio Franco <[email protected]>
2020-02-16 15:13:22 -05:00
Lucio FrancoandGitHub b49ad9bb47 chore(docs): Add hyper example (#267)
Signed-off-by: Lucio Franco <[email protected]>
2020-02-16 12:46:55 -05:00
DizansandGitHub 34865a9fb5 chore(docs): Remove unecessary pinning (#263) 2020-02-13 11:34:34 -05:00
Lucio FrancoandGitHub 66ac4c4049 chore: Prepare 0.1.1 release (#246)
* chore: Prepare 0.1.1 release

* add missing pr
2020-01-20 11:53:45 -05:00
Fuyang LiuandLucio Franco bd0f5edddf chore: Add grpcurl example in helloworld readme (#236) 2020-01-14 10:55:59 -05:00
Lucio FrancoandGitHub f4ecf47428 chore: Prepare 0.1.0 release (#234) 2020-01-14 09:36:19 -05:00
Lucio FrancoandGitHub eba7ec7b32 feat: Add gRPC interceptors (#232)
This change introduces proper gRPC interceptors that are avilable
regardless of the transport used. Each codegen service now produces an
additional method called `with_interceptor` that accepts a
`Interceptor`.

All examples have been updated to use this new style and interop has a
custom `tower::Service` middleware to echo the headers. There is also a
new `interceptor` example that shows basic usage.

BREAKING CHANGE: removed `interceptor_fn` and `intercep_headers_fn` from `transport` in favor of using `tonic::Interceptor`.
2020-01-13 21:26:08 -05:00
Juan AlvarezandLucio Franco a41f55ab9d fix(build): Remove default impl for Server traits (#229)
BREAKING CHANGE: remove default implementations for server traits.
2020-01-13 09:42:14 -05:00
MarcelandLucio Franco dadc8186c2 chore: Upgrade to prost, prost-build and prost-derive 0.6 (#230) (#231) 2020-01-13 09:40:57 -05:00
Lucio FrancoandGitHub af807c3ccd feat(transport): Add server side peer cert support (#228)
* feat(transport): Add server side peer cert support
2020-01-11 14:17:19 -08:00
Johan AnderssonandLucio Franco 3be8bc1668 Run CI checks & tests on Windows and Mac (#206)
* Run CI checks & tests on Windows and Mac

* Fix uds windows compile

Co-authored-by: Lucio Franco <[email protected]>
2020-01-11 14:16:54 -08:00
Lucio FrancoandGitHub 6673f91f1f chore: Remove required bytes dep and clean up deny (#227)
* chore: Remove required bytes dep and clean up deny

* Fix interop test cli args
2020-01-11 12:48:24 -08:00
Adam JacobandLucio Franco 8997f47b6d chore: Upgrade to prost master and bytes 0.5 (#224)
This upgrades tonic to prost's master branch, and moves everything to
bytes 0.5.
2020-01-11 11:05:08 -08:00
Juan AlvarezandLucio Franco faa26ac152 chore(example) Fix routeguide errors (#218)
* chore(example) Fix routeguide errors

* remove redundant line
2020-01-07 16:53:30 -05:00
Thomas MayandLucio Franco 59d008db7e chore(docs): Fix examples link (#202)
* url is just examples, not tonic-examples

* Change root directory from tonic-examples to examples.  Matches current directory structure.
2019-12-20 22:39:39 -05:00
Lucio FrancoandGitHub 8efdbb4631 chore: Use released version of tower (#199)
* chore: Use released version of tower

* Update the rest
2019-12-19 18:31:40 -05:00
Juan AlvarezandLucio Franco 4e5c6c8f23 chore(example): update guides to 0.1-beta.1 (#198)
* update routeguide

* update helloworld

* depend on tonic beta.1

* Apply suggestions from code review

Co-Authored-By: Lucio Franco <[email protected]>

Co-authored-by: Lucio Franco <[email protected]>
2019-12-19 18:23:25 -05:00
Fletcher NicholandLucio Franco 6566b237a1 chore(docs): Fix routeguide tutorial source links (#195)
Signed-off-by: Fletcher Nichol <[email protected]>
2019-12-17 16:21:13 -05:00
Juan AlvarezandLucio Franco 3a5c66d5f2 fix(build): snake_case service names (#190) 2019-12-14 15:08:28 -05:00
Lucio FrancoandGitHub 82facb6283 chore: Apply clippy (#189) 2019-12-13 23:55:49 -05:00
Lucio FrancoandGitHub 502491a590 fix(transport): Remove with_rustls for tls config (#188) 2019-12-13 20:31:22 -05:00
Lucio FrancoandGitHub 3eb76abf9f feat(transport): Add remote_addr to Request on the server si… (#186) 2019-12-13 20:25:00 -05:00
Lucio FrancoandGitHub b90c340800 feat(transport): Allow custom IO and UDS example (#184)
Closes #136
2019-12-13 17:14:49 -05:00
Artem VorotnikovandLucio Franco 7077d8dfd0 chore(docs): Fix routeguide tutorial link (#183) 2019-12-13 13:10:43 -05:00
Lucio FrancoandGitHub d9a481baef chore: Reorganize examples and interop crates (#180)
* chore: Reorganize examples and interop crates

* fix interop tests
2019-12-12 11:53:15 -05:00