Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Jul 3, 2021. It is now read-only.

Conversation

@damianh
Copy link
Collaborator

@damianh damianh commented Jun 10, 2019

Allows one to specify a proxy configuration via a typed handler allowing easier dependency injection scenarios.

app.UseProxy<FooTypedHandler>();

Note that dependency injection only occurs when the middleware is activated. To get a request level scope service, one still needs to go to context.RequestService.

cc @ben-foster-cko

damianh added 2 commits June 10, 2019 19:35
…sting delegate) can handle proxy requests. The main benefit is to allow authors to define a class that handles the operation that can be activated by ANC allowing services to be injected into it.
}
```

### 2.8. Typed Handlers
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ben-foster-cko Have a read through these docs and let me know what you think. Cheers.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice!

@damianh
Copy link
Collaborator Author

damianh commented Jun 10, 2019

💭 Do we want to so support request level dependency injection? That is should a typed handler be activated per request? (My currently opinion is no...)

@damianh damianh merged commit 436f370 into master Jun 15, 2019
@damianh damianh deleted the typed-handler branch June 15, 2019 15:08
@damianh damianh added this to the v2.1.0 milestone Jun 15, 2019
@damianh damianh added the enhancement New feature or request label Jun 15, 2019
@damianh damianh self-assigned this Jun 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.