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

[2.0] Make Dependency Injection more magical #752

Open
cilerler opened this issue Dec 7, 2023 · 1 comment
Open

[2.0] Make Dependency Injection more magical #752

cilerler opened this issue Dec 7, 2023 · 1 comment
Milestone

Comments

@cilerler
Copy link
Contributor

cilerler commented Dec 7, 2023

As a user, I want Restier to integrate with ASP.NET Core's default Dependency Injection (DI) container, so that I can streamline project setup.

@robertmclaws
Copy link
Collaborator

Given that Restier is pretty dependent on OData's .NET implementation, which requires a DI container per route, this is not likely going to be possible in the current iteration.

If I had my way, I would redesign OData AspNetCore 9.0 to use the KeyedServices in .NET 8 to keep all of the services fully-accessible in the root DI container. Then I would build Restier 2.0 on top of that.

We'll see if I can convince Microsoft to do that. Until then, we might be able to make just Restier 2.0 work that way... we'll just have to see what happens.

@robertmclaws robertmclaws added this to the 2.0 milestone Dec 7, 2023
@robertmclaws robertmclaws changed the title Integrate Restier with ASP.NET Core's Default DI Container [2.0] Make Dependency Injection magical Dec 8, 2023
@robertmclaws robertmclaws changed the title [2.0] Make Dependency Injection magical [2.0] Make Dependency Injection more magical Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

2 participants