Questions tagged [dependency-injection]

Anything related to the use of Dependency Injection (DI)/IoC containers on a Sitecore solution. This also includes the baked-in Microsoft Dependency Resolver included natively in Sitecore versions 8.2 and above.

Filter by
Sorted by
Tagged with
4
votes
1answer
539 views

Can I use automatic dependency injection with computed search fields in Sitecore 8.1?

I am creating a custom computed content search field that has one dependency: ISearchSettings. I'd like it to be injected via constructor: public class CustomField : AbstractComputedIndexField { ...
5
votes
2answers
445 views

Helix and Computed Index Fields with DI

In my solution, I have some Computed Index Fields that I need to add that combine the values of fields from templates that belong to multiple Project-layer modules. I am using DI for initializing my ...
12
votes
2answers
977 views

Injecting dependencies into a custom WFFM save action

We have a client that is on 8.1u1 and is using WFFM. They want to integrate the data collected on the form into Dynamics CRM, however the OOTB save actions for creating entities in the CRM aren't ...
12
votes
3answers
564 views

Dependency Injection migration path to 8.2

With native support for Dependency Injection in Sitecore 8.2, what is the easiest path for upgrading from previous versions in solutions utilizing a third party DI framework (Castle Windsor, ...
39
votes
5answers
6k views

Best approach for Dependency Injection in Sitecore 8.2

I see a fair few approaches in blog posts for using DI with 8.2, particularly around the registration. Is there an approach which would be recommended - particularly with a Helix compatible ...
16
votes
1answer
1k views

SimpleInjector as default DI in Sitecore 8.2

I read this post today about replacing Sitecores 8.2 default DI (https://medium.com/@structuredcode/replacing-the-default-di-container-in-sitecore-8-2-4e65d4956c99), but the example is for Autofac. We ...
8
votes
1answer
679 views

Should I reference Microsoft.Extensions.DependencyInjection in modules I create for Sitecore 8.2+?

So I'm in the process of upgrading various modules to Sitecore 8.2. Among other things this involves getting rid of IoC container project references and getting on board with the Sitecore one. And ...
7
votes
2answers
985 views

How to override/replace the default Sitecore Authentication Controller

I upgraded my site from 7.5 to 8.1 and when I try to click on Sitecore logout link I have the following error: Multiple types were found that match the controller named 'Authentication'. ...
5
votes
2answers
448 views

Where can I find the instructions for setting up SOLR without using IOC?

I'm trying to setup an instance of Sitecore 8.2 so I can see what it's going to take to upgrade my site from Sitecore 8.1 to it. I've heard that Sitecore 8.2 can run SOLR natively (without using IOC), ...

1
2