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

RFC: Service Builder Improvements #1620

Merged
merged 28 commits into from
Aug 30, 2022
Merged
Changes from 1 commit
Commits
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
Background tweaks
Harry Barber committed Aug 4, 2022
commit f470d7067fb0e21c80de03dc8724ccae48b4cf44
10 changes: 7 additions & 3 deletions design/src/rfcs/rfc0020_service_builder.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# RFC: Better Service Builders
# RFC: Service Builder Improvements

> Status: RFC

@@ -16,7 +16,7 @@ This RFC proposes a new builder, deprecating the existing one, which addresses A

## Background

Before engaging with the proposal, a survey of the current state of affairs is required.
To provide context for the proposal we perform a survey of the current state of affairs.

The following is a reference model we will use throughout the RFC:

@@ -43,7 +43,7 @@ We have purposely omitted details from the model that are unimportant to describ

### Handlers

Before we progress onto a more general look at the current service builder, we should familiarize ourselves with the specifics of the `Handler` trait:
An core concept in the current service builder is the `Handler` trait:
hlbarber marked this conversation as resolved.
Show resolved Hide resolved

```rust
pub trait Handler<T, Input> {
@@ -280,3 +280,7 @@ let new_routes = old_routes
// Collect the iterator back into a collection (`Vec` or `TinyMap`)
.collect();
```

### Comparison to Axum

Historically, `smithy-rs` has borrowed from [axum](https://github.com/tokio-rs/axum). Despite various divergences the code bases still have much in common.