Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce generic fluent client generator to non-sdk codegen — take 2 #496

Merged
merged 40 commits into from
Jun 11, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
b41bb4f
Implement Debug for more things
Jun 3, 2021
ac926ef
Extract out generic hyper client to smithy-hyper
Jun 3, 2021
c468458
Add generic fluent client generation
Jun 3, 2021
c85d046
Make the bounds nicer
Jun 4, 2021
5917587
Make smithy-hyper hyper dep optional
Jun 4, 2021
7a3cfa7
Rename smithy-hyper to smithy-client
Jun 4, 2021
a2181cd
Enable rustls by default
Jun 4, 2021
2f23050
Also warn on rust 2018 idioms
Jun 4, 2021
10ad30d
Add type-erased middleware
Jun 4, 2021
65427b0
Restore old DispatchLayer tracing
Jun 4, 2021
bfde222
Add connection type-erasure
Jun 4, 2021
fdeed6d
Fix rustdoc link
Jun 4, 2021
2f3d664
Split up lib.rs
Jun 4, 2021
48c9b77
Make Builder a little nicer to use
Jun 4, 2021
ccdaaf4
Make aws_hyper simply wrap smithy_client
Jun 4, 2021
ec22f48
Make it clear that bounds:: should never be implemented
Jun 4, 2021
e5b8ba6
Finish adjusting aws fluent generator
Jun 4, 2021
c8c34ba
Make clippy happy
Jun 4, 2021
499a96c
Also re-expose test_connection in aws_hyper
Jun 4, 2021
7751a24
Make ktlint happy
Jun 4, 2021
04254e1
No Builder::native_tls with default features
Jun 4, 2021
20c45dd
Work around rustdoc bug
Jun 4, 2021
186056e
Better names for type-erase methods
Jun 7, 2021
cc24f66
Add middleware_fn
Jun 7, 2021
6dcf508
Better docs for client
Jun 7, 2021
ddb6f63
Fix remaining erase_connector
Jun 7, 2021
af3d662
Better name for service in docs
Jun 7, 2021
d5397f3
Correct send+sync test name
Jun 7, 2021
f6319ee
Use crate name with _ in Rust code
Jun 7, 2021
9993ab0
Merge remote-tracking branch 'upstream/main' into generic-client
Jun 7, 2021
9c587b7
Fix up relative links
Jun 7, 2021
d6071a8
Merge remote-tracking branch 'upstream/main' into generic-client
Jun 8, 2021
d1a599a
Fix the new integration test
Jun 8, 2021
fd38332
Hide temporary Operation type aliases
Jun 9, 2021
fbffa81
Don't bound middleware_fn as it also bounds C
Jun 10, 2021
5c28c25
Don't recursive infinitely
Jun 11, 2021
7ad3790
Can only doc(inline) re-exports, not type alises
Jun 11, 2021
8f028c1
Merge branch 'main' into generic-client-v2
Jun 11, 2021
4e51f73
Can only doc(inline) re-exports, not type alises
Jun 11, 2021
f54bfa5
Merge branch 'main' into generic-client-v2
rcoh Jun 11, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
No Builder::native_tls with default features
Since the function "doesn't exist", we can't link to it. Arguably, the
docs should only be tested with all features enabled, but for now just
don't try to link to `native_tls`.
  • Loading branch information
Jon Gjengset committed Jun 4, 2021
commit 04254e1f870a090a2262b48f5988ecf5108f0d7f
4 changes: 2 additions & 2 deletions rust-runtime/smithy-client/src/hyper_impls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ where
/// For convenience, this constructor type-erases the concrete TLS connector backend used using
/// dynamic dispatch. This comes at a slight runtime performance cost. See
/// [`DynConnector`](crate::erase::DynConnector) for details. To avoid that overhead, use
/// [`Builder::rustls`] or [`Builder::native_tls`] instead.
/// [`Builder::rustls`] or `Builder::native_tls` instead.
pub fn https() -> Self {
#[cfg(feature = "rustls")]
let with_https = |b: Builder<_>| b.rustls();
Expand Down Expand Up @@ -91,7 +91,7 @@ impl<M, R> Builder<(), M, R> {
/// Connect to the service over HTTPS using Rustls.
///
/// This is exactly equivalent to [`Builder::rustls`]. If you instead wish to use `native_tls`,
/// use [`Builder::native_tls`].
/// use `Builder::native_tls`.
pub fn https(
self,
) -> Builder<HyperAdapter<hyper_rustls::HttpsConnector<hyper::client::HttpConnector>>, M, R>
Expand Down
2 changes: 1 addition & 1 deletion rust-runtime/smithy-client/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ type BoxError = Box<dyn Error + Send + Sync>;
/// With the `hyper` feature enabled, you can construct a `Client` directly from a
/// [`hyper::Client`] using [`Builder::hyper`]. You can also enable the `rustls` or `native-tls`
/// features to construct a Client against a standard HTTPS endpoint using [`Builder::rustls`] and
/// [`Builder::native_tls`] respectively.
/// `Builder::native_tls` respectively.
#[derive(Debug)]
pub struct Client<
Connector = erase::DynConnector,
Expand Down