-
Notifications
You must be signed in to change notification settings - Fork 26
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
Transient or Scoped dependency support #65
Comments
@sparky2708 I think it can be done, my only concern is that I don't think I will be able to find time to work on it. The way I use kink in my professional work differs slightly, and since I don't need this feature, its development might not be prioritized from my side. However, I'm happy to collaborate with you on it and provide my feedback. |
For process-scope I have figured out how to achieve it:
|
Ideally I’d like to see it like the following - will try to work on it when I have some free time and create a PR:
|
Is there a way to implement transient or scoped dependency? I am thinking of a way to create services that would only exist for the life of the api request in FastApi. E.g. let’s say you get a message with 2 different sections:
When I receive this message I want to use a TreeProvider and DogProvider that source their data from the above message and can be injected just for processing that request and not for other requests.
This is similar to a C# scoped or transient registration.
The text was updated successfully, but these errors were encountered: