Umbraco now installs and can install the starter kit... not much else though ;)
This commit is contained in:
@@ -314,6 +314,15 @@ namespace Umbraco.Web
|
||||
{
|
||||
base.ConfigureCoreServices(container);
|
||||
|
||||
container.EnablePerWebRequestScope();
|
||||
|
||||
container.Register<IUmbracoContextAccessor, DefaultUmbracoContextAccessor>(new PerContainerLifetime());
|
||||
//TODO: Is this lifespan correct? Need to ask Stephen because we have contextual ones too
|
||||
container.Register<IPublishedContentCache, PublishedContentCache>(new PerContainerLifetime());
|
||||
container.Register<IPublishedMediaCache, PublishedMediaCache>(new PerContainerLifetime());
|
||||
//no need to declare as per request, currently we manage it's lifetime as the singleton
|
||||
container.Register<UmbracoContext>(factory => UmbracoContext.Current);
|
||||
|
||||
//Replace services:
|
||||
container.Register<IEventMessagesFactory, RequestLifespanMessagesFactory>();
|
||||
}
|
||||
@@ -328,18 +337,9 @@ namespace Umbraco.Web
|
||||
|
||||
//IoC setup for LightInject for mvc/webapi
|
||||
Container.EnableMvc();
|
||||
Container.RegisterMvcControllers(PluginManager);
|
||||
container.EnablePerWebRequestScope();
|
||||
Container.RegisterMvcControllers(PluginManager);
|
||||
container.EnableWebApi(GlobalConfiguration.Configuration);
|
||||
container.RegisterApiControllers(PluginManager);
|
||||
|
||||
//register other services
|
||||
container.Register<IUmbracoContextAccessor, DefaultUmbracoContextAccessor>(new PerRequestLifeTime());
|
||||
//TODO: Is this lifespan correct? Need to ask Stephen because we have contextual ones too
|
||||
container.Register<IPublishedContentCache, PublishedContentCache>(new PerContainerLifetime());
|
||||
container.Register<IPublishedMediaCache, PublishedMediaCache>(new PerContainerLifetime());
|
||||
//no need to declare as per request, currently we manage it's lifetime as the singleton
|
||||
container.Register<UmbracoContext>(factory => UmbracoContext.Current);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user