The Azure platform does not like the "LazyInitializer.EnsureInitialized" method :)

Oct 12, 2013 at 7:11 PM
Hello,

The Azure platform (hosting of a web site in shared environment, the FREE one) does not like the "LazyInitializer.EnsureInitialized(ref _initializer, ref _isInitialized, ref _initializerLock) method fired within the ProjectNamespace.Filters.InitializeSimpleMembershipAttribute.OnActionExecuting method when a "membership" collection already exists (I have not tested if collection does not exist).

With commenting that part of the code , the membership works.

Link to the stack trace information: http://ubuntuone.com/6XtxCIqDqqk4BfWPKwKHiD. Please let me know if you cannot access the page on the link.

Best Regards,
Velin
Oct 12, 2013 at 8:33 PM
Hello Velin,

As stated on homepage of membership "Remove datacontext and "InitializeSimpleMembershipAttribute.cs" as current membership dont require them (From Standard template mvc4 project)". This filter was used for Sql Server version, but no need for mongo as it is schmaless and dont need pre-created db for work.

Regards,
Dmitriy
Oct 12, 2013 at 9:15 PM
Uhh sorry I have missed that. Thanks for yor replay!