I am using Ninject 2.2.1.0 with Ninject.Web 2.2.0.0 in a webforms application.
I am getting daily error reports of the following…
System.InvalidOperationException: Collection was modified; enumerationoperation may not execute.
at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource
resource)
at System.Collections.Generic.List1.Enumerator.MoveNextRare()1.Enumerator.MoveNext()
at System.Collections.Generic.List
at System.Linq.Enumerable.WhereSelectListIterator2.MoveNext()1
at Ninject.Infrastructure.Language.ExtensionsForIEnumerableOfT.Map[T](IEnumerable
series, Action`1 action) in
c:\Projects\Ninject\ninject\src\Ninject\Infrastructure\Language\ExtensionsForIEnumerableOfT.cs:line
22
at Ninject.OnePerRequestModule.DeactivateInstancesForCurrentHttpRequest()
in
c:\Projects\Ninject\ninject\src\Ninject\OnePerRequestModule.cs:line
63
at Ninject.OnePerRequestModule.b__0(Object
o, EventArgs e) in
c:\Projects\Ninject\ninject\src\Ninject\OnePerRequestModule.cs:line
36
at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep
step, Boolean& completedSynchronously)
Seems to be occuring at peak times. Is there a stable release with this patched yet?
Creation of kernel instances is not thread safe at the moment. This will probably be changed with 2.4