English 中文(简体)
For a simple web application, what service locator library you prefer to use?
原标题:

For a simple application that use asp.net mvc 3 and .net-4, what service locator application is preferred, with performance concern in mind?

问题回答

See these questions:

About performance, none of the main IoC containers have performance issues in a web application.

I would take a look at MEF as it s included on .NET 4.0 and there are several implementations of modularity on MVC using it.

You don t need ServiceLocator for a simple application. It just works out of the box. Like in previous versions of ASP.NET MVC.





相关问题
How to Inject Open Connections with an IoC

First, my scenario. I have a service, BillingService, has a constructor like this: BillingService(IInstallmentService, IBillingRepository) The InstallmentService has a constructor that looks like ...

Using the Ninject kernel as a Unit of Work object factory

So I m starting to use Ninject for dependency injection and I m wondering what people think of using a kernel as an object factory for Unit of Work type objects like Linq2Sql Datacontexts. I would ...

array dependency injection in spring?

is there a way to use dependency injection to inject all available implementations of a specific interface in spring? This is kind of the same thing as asked here for .NET. Though my aim is to use @...

Unity constructors

I have setup unity in my project and it is working for objects that don t have constructor injection implemented on them. The issue is now I do have an object which requires a custom object as a ...

Grails Packaging and Naming Conventions

Packaging Controllers, Services,etc. i.e. - com.company.controllers - com.company.services Is this a good practice or should be avoided by all means?? Another worth mentioning problem I encountered ...

ASP.NET MVP Injecting Service Dependency

I have an ASP.NET page that implements my view and creates the presenter in the page constuctor. Phil Haack s post providing was used as the starting point, and I ll just the examples from the post ...

Authorization and Windsor

I m trying to implement my custom authorize attribute like: public class MyCustomAuth : AuthorizeAttribute { private readonly IUserService _userService; public MyCustomAuth(IUserService ...

热门标签