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

feat: enable non-'static where possible #765

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

Daniel-Aaron-Bloom
Copy link

Motivation

Currently, many tower service wrappers and layers are limited to working with 'static types, which limits its usefulness when working with non-statically borrowed things to and from scoped tasks (e.g. async-scoped).

Solution

Remove the 'static restrictions where possible, mostly by introducing lifetime parameters.

This change excludes Buffer and BufferLayer which are more difficult to make non-'static.

This PR replaces #732

@tobz tobz added C-enhancement Category: A PR with an enhancement or a proposed on in an issue. A-buffer Area: The tower "buffer" middleware A-util Area: The tower "util" module I-needs-decision Issues in need of decision. labels Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-buffer Area: The tower "buffer" middleware A-util Area: The tower "util" module C-enhancement Category: A PR with an enhancement or a proposed on in an issue. I-needs-decision Issues in need of decision.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants