Try our conversational search powered by Generative AI!

ProjectMessageNotifier error in CMS 9.5

Vote:
 

After upgrading to EPiServer CMS 9.5 I get the following error:

EPiServer.ServiceLocation.ActivationException: Activation error occurred while trying to get instance of type ProjectMessageNotifier, key "" ---> StructureMap.Building.StructureMapBuildException: Failure while building 'Lambda: Invoke(value(EPiServer.ServiceLocation.Internal.StructureMapConfiguredType+<>c__DisplayClass6_0).p, value(EPiServer.ServiceLocation.Internal.StructureMapConfiguredType)._serviceLocator)', check the inner exception for details
1.) Lambda: Invoke(value(EPiServer.ServiceLocation.Internal.StructureMapConfiguredType+<>c__DisplayClass6_0).p, value(EPiServer.ServiceLocation.Internal.StructureMapConfiguredType)._serviceLocator)
2.) Instance of EPiServer.Notification.IQueryableNotificationUsers (System.Object)
3.) new NotificationUserRepositoryImpl(*Default of IQueryableNotificationUsers*, Enumerable of EPiServer.Notification.INotificationProvider with all registered instances, Enumerable of EPiServer.Notification.IQueryablePreference with all registered instances)
4.) EPiServer.Notification.NotificationUserRepositoryImpl
5.) Instance of EPiServer.Notification.INotificationUserRepository (EPiServer.Notification.NotificationUserRepositoryImpl)
6.) new DefaultNotifier(*Default of INotificationUserRepository*, *Default of INotificationRepository*, Enumerable of EPiServer.Notification.INotificationFormatter with all registered instances, *Default of QueryableNotificationUserService*)
7.) EPiServer.Notification.DefaultNotifier
8.) Instance of EPiServer.Notification.INotifier (EPiServer.Notification.DefaultNotifier)
9.) new ProjectMessageNotifier(*Default of INotifier*, *Default of ProjectActivityFeed*, *Default of ActivityCommentRepository*, *Default of IObjectSerializerFactory*, *Default of MentionParser*, *Default of ProjectService*, *Default of ISubscriptionService*)
10.) EPiServer.Cms.Shell.UI.Notifications.ProjectMessageNotifier
11.) Instance of EPiServer.Cms.Shell.UI.Notifications.ProjectMessageNotifier
12.) Container.GetInstance(EPiServer.Cms.Shell.UI.Notifications.ProjectMessageNotifier)
---> System.Configuration.Provider.ProviderException: En standardprovider för medlemskap måste anges.
vid System.Web.Security.Membership.InitializeDefaultProvider(Boolean initializeDefaultProvider, MembershipSection settings)
vid System.Web.Security.Membership.Initialize()
vid System.Web.Security.Membership.get_Provider()
vid EPiServer.Initialization.MembershipSecurityEntityProviderInitialization.<>c.b__0_1(IServiceLocator s)
vid lambda_method(Closure , IBuildSession , IContext )
--- Slut på stackspårning för interna undantag ---
vid lambda_method(Closure , IBuildSession , IContext )
vid StructureMap.Building.BuildPlan.Build(IBuildSession session, IContext context) i c:\BuildAgent\work\a395dbde6b793293\src\StructureMap\Building\BuildPlan.cs:rad 151
vid StructureMap.Pipeline.LifecycleObjectCache.Get(Type pluginType, Instance instance, IBuildSession session) i c:\BuildAgent\work\a395dbde6b793293\src\StructureMap\Pipeline\LifecycleObjectCache.cs:rad 71
vid StructureMap.SessionCache.GetObject(Type pluginType, Instance instance, ILifecycle lifecycle) i c:\BuildAgent\work\a395dbde6b793293\src\StructureMap\SessionCache.cs:rad 93
vid StructureMap.SessionCache.GetDefault(Type pluginType, IPipelineGraph pipelineGraph) i c:\BuildAgent\work\a395dbde6b793293\src\StructureMap\SessionCache.cs:rad 68
vid StructureMap.Container.GetInstance(Type pluginType) i c:\BuildAgent\work\a395dbde6b793293\src\StructureMap\Container.cs:rad 337
vid EPiServer.ServiceLocation.ServiceLocatorImplBase.GetInstance(Type serviceType, String key)
--- Slut på stackspårning för interna undantag ---
vid EPiServer.ServiceLocation.ServiceLocatorImplBase.GetInstance(Type serviceType, String key)
vid EPiServer.ServiceLocation.ServiceLocatorImplBase.GetInstance[TService]()
vid EPiServer.Cms.Shell.InitializableModule.Initialize(InitializationEngine context)
vid EPiServer.Framework.Initialization.ModuleNode.Execute(Action a, String key)
vid EPiServer.Framework.Initialization.InitializationEngine.InitializeModules()

I'm using Federated Security (Owin) so the no Membership i specified in Web.config





(This also causes error when trying to use the GoogleAnalytics add-on but I have removed that one for now.)

Does someone know how to solve this or is it a bug?

Regards

Erik

#142651
Dec 17, 2015 14:20
Vote:
 

Hi,

Most probably its a bug, what settings you have for profile in your web.config? Is It?

<profile enabled="false">
      <properties>
        <clear />
      properties>
      <providers>
        <clear />
      providers>
    profile>

Regards
/K

#142656
Dec 17, 2015 16:28
Vote:
 

Hi K,

I had the following Profile config:
(This is a former 7.1 -> now 7.5 site I'm upgrading to EpiServer 9)

<profile defaultProvider="DefaultProfileProvider">
<properties>
<add name="Address" type="System.String" />
<add name="ZipCode" type="System.String" />
<add name="Locality" type="System.String" />
<add name="Email" type="System.String" />
<add name="FirstName" type="System.String" />
<add name="LastName" type="System.String" />
<add name="Language" type="System.String" />
<add name="Country" type="System.String" />
<add name="Company" type="System.String" />
<add name="Title" type="System.String" />
<add name="CustomExplorerTreePanel" type="System.String" />
<add name="FileManagerFavourites" type="System.Collections.Generic.List`1[System.String]" />
<add name="EditTreeSettings" type="EPiServer.Personalization.GuiSettings, EPiServer" />
<add name="ClientToolsActivationKey" type="System.String" />
<add name="FrameworkName" type="System.String" />
</properties>
<providers>
<add name="DefaultProfileProvider" type="System.Web.Providers.DefaultProfileProvider, System.Web.Providers, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="EPiServerDB" applicationName="/" />
</providers>
</profile>

But I also tried with your profile settings with the same result.

/E

#142657
Edited, Dec 17, 2015 16:49
Vote:
 
<p>Hi,</p> <p>Can We get some EPiServer's Suport team help here? In result of upgrade, I have came with this question from another source also.</p> <p>Regards<br />/K</p>
#142661
Dec 17, 2015 17:32
Vote:
 

I reported a bug on this (CMS-2428), looks like we introduced this in 9.5.0 due to some changes in the IoC container, we will look at it ASAP.

I think you can workaround it with this code, I have not had a chance to verify that the workaround works yet but feel free to test it out and let me know.

 [ModuleDependency(typeof(EPiServer.Web.InitializationModule))]
    public class FixQueryableNotificationUsersInitialization : IConfigurableModule
    {
        public void ConfigureContainer(ServiceConfigurationContext context)
        {
            context.Services.RemoveAll<IQueryableNotificationUsers>();
            context.Services.AddTransient<IQueryableNotificationUsers>((s) => s.GetInstance<SynchronizingUserService>());
        }

        public void Initialize(InitializationEngine context)
        {
        }

        public void Uninitialize(InitializationEngine context)
        {
        }
    }
#142688
Dec 18, 2015 10:55
Vote:
 

I can verify that the site starts when the workaround is included. I have not made any more tests.

Regards
Peter

#142689
Dec 18, 2015 11:25
Vote:
 

The workaround made the site start. 
Thanks for the help!

The Google Analytics add-on still has problems. That is a smaller issue.

This is what I get in the errorlog:

2015-12-18 14:57:11,471 [109] ERROR EPiServer.Global: 1.2.5 Unhandled exception in ASP.NET
System.Configuration.Provider.ProviderException: The Role Manager feature has not been enabled.
at System.Web.Security.Roles.EnsureEnabled()
at System.Web.Security.Roles.get_Provider()
at EPiServer.GoogleAnalytics.Controllers.AdministrationController.GetViewModel(GlobalAnalyticsSettings settings)
at EPiServer.GoogleAnalytics.Controllers.AdministrationController.Index()
at lambda_method(Closure , ControllerBase , Object[] )
at System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters)
at System.Web.Mvc.ControllerActionInvoker.<>c__DisplayClass15.<InvokeActionMethodWithFilters>b__12()
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation)
at System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName)
at System.Web.Mvc.Controller.ExecuteCore()
at System.Web.Mvc.ControllerBase.Execute(RequestContext requestContext)
at EPiServer.Shell.Web.Mvc.ModuleMvcHandler.ProcessController(IController controller)
at EPiServer.Shell.Web.Mvc.ModuleMvcHandler.BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, Object state)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
System.Configuration.Provider.ProviderException: The Role Manager feature has not been enabled.
at System.Web.Security.Roles.EnsureEnabled()
at System.Web.Security.Roles.get_Provider()
at EPiServer.GoogleAnalytics.Controllers.AdministrationController.GetViewModel(GlobalAnalyticsSettings settings)
at EPiServer.GoogleAnalytics.Controllers.AdministrationController.Index()
at lambda_method(Closure , ControllerBase , Object[] )
at System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters)
at System.Web.Mvc.ControllerActionInvoker.<>c__DisplayClass15.<InvokeActionMethodWithFilters>b__12()
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation)
at System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName)
at System.Web.Mvc.Controller.ExecuteCore()
at System.Web.Mvc.ControllerBase.Execute(RequestContext requestContext)
at EPiServer.Shell.Web.Mvc.ModuleMvcHandler.ProcessController(IController controller)
at EPiServer.Shell.Web.Mvc.ModuleMvcHandler.BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, Object state)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

#142698
Edited, Dec 18, 2015 14:29
Vote:
 
<p>You sure this is related to the upgrade? Seems like another problem that someone accesses a page without access rights.</p>
#142700
Dec 18, 2015 15:02
Vote:
 

Hi Per,

I just edited my post.
Was your last comment related to the previous content of my post?

/Erik

#142701
Dec 18, 2015 15:04
Vote:
 

Yes, I see now, thanks.

#142702
Dec 18, 2015 16:06
Vote:
 

Per,

The workaround provided worked for the EPiServer CMS-related pages, but we are still getting the same error when attempting to use the EPiServer Service API. Do you happen to know any workarounds for this?

Chris

#148540
Edited, May 17, 2016 0:23
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.