PerWebRequest Lifestyle Missing in Castle Windsor 3.2

I used PerWebRequest Lifestyle from Castle Windsor (version 3.0.0.4001). I wanted to update it to the latest version (3.2). In the latest version, he says

does not contain a definition for 'PerWebRequest' and no extension method 'PerWebRequest' accepting a first argument of type 'Castle.MicroKernel.Registration.Lifestyle.LifestyleGroup<....

The following describes how I registered the component, but with the latest version it throws an error:

container.Register(Component.For<IUserRepository>().ImplementedBy<UserRepository>().LifeStyle.PerWebRequest);

Do I need to add any links? Or someone might suggest which type of Castle Windsor Lifestyle is recommended for a web application (where users use it for daily activities, such as (customer service)).

+1
source share

All Articles