Ninject 2.2.1.0 and Ninject.MVC3 2.2.1.0 released

I just released Ninject 2.2.1.0 and Ninject.MVC3 2.2.1.0. Both are bugfix releases. In this Blogpost I’ll explain if you have to update and what changes you need to do in case you are using th NuGet version of Ninject.MVC3.Ninject 2.2.1.0
This version fixes a bug for the .NET 4.0 and SL 4.0 versions of Ninject. The .NET framework still seems to have a bug when you request the attributes of an indexer property that is overridden in a derived class. For more information see the bug report at Microsoft. For 2.2.1.0 I switched back to our custom implementation that we already used in 3.5 for retrieving attributes of properties to workaround this problem.

This means you have to update to 2.2.1.0 only if you are using one of the .NET 4.0 or Silverlight 4.0 releases. This release changes absolutely nothing for the .NET 3.5 versions of Ninject.

Ninject.MVC3 2.2.1.0
This release fixes two bugs. The first one applies to everyone. The second only for NuGet package users.

Websites with heavy load will start to crash with an circular reference exception after some time.

The NuGet package version disposes the kernel unintended.

Furthermore, I changed the NuGet package to use the new Naming Convention of the WebActivator and switched to WebActivator 1.4. This change requires that you move the CreateKernel and RegisterServices methods from NinjectHttpApplicationModule to AppStart/Ninject.MVC3 and that you delete the NinjectHttpApplicationModule afterwards.

Other Extensions
You may ask yourself where you find the other extensios for 2.2.1.0. The answer is, there are no new ones. The old ones are still valid for Ninject 2.2.1.0 as we changed the build system to leave the assembly version at 2.2.0.0 as long as there is no interface change that requires an update of the extensions.

Hi, would you please update the package and rename/fix the AppStart folder in the current Ninject package to App_Start. The convention all the other packages and David Ebbo uses is *App_Start*. Thanks!

Please explain which Nuget package to install as MVC3 RTM installed on top of vs 2010 allows the package manager to work just fine. Most downloads work just fine. However, I know that if I contribute software, I make sure it works on more than 1 computer, and when someone has a question I am not going to give a reply that shouts “It works for me, re-install …” ughhh

Microsoft.Web.Infrastructure does not exist, please try as provide a better reply than “NuGet and PowerShell is properly installed”
Thanks.

It is this sort of attitude which kills open source projects. Remo Gloor is spending countless hours in maintaining and improving Ninject and the extensions. Our company spends time and money to keep the product maintained and accurate.

Nobody keeps you from forking the source and investigating yourself into the problem. When you detected the issue send a pull request to us. That’s the nature of open source. We and especially Remo have a life outside of ninject, imagine that

By the way. If you claim yourself a good package developer and software contributor: Why don’t you spend some of your testing resources to the ninject project? I’m sure we would find some way to automatically deploy the packages to one of your remote computers and then you could “ensure that it works on more than 1 computer”. And only after you have given us green light we would provide the packages on Nuget and the website. Think about that…

You may are a good package developer. But you are defenately not good at keeping your tools up to date and following the solution you were told.

MVC3 RTM does not contain the latest NuGet which is 1.1 at the moment. And believe me, the package is testes on far more than just one system. But as the package uses 1.1 features, I won’t test on a 1.0 system as I know that it doesn’t work.

So, as a user of a open source project, I would rather do as I was told and update my system before I write a rude comment that the proposed solution does not work!

HI,
i just installed the package in my MVC3 app.
When I set up NinjectMVC3.cs, I try to call the ninject in global.asax like this in Application_Start method
NinjectMVC3.Start();
I allways get error:
This method can only be called during the application’s pre-start initialization stage
Can you please help me

Hey there, Remo. I’m a big fan of Ninject, and I think it’s one of the best products I’ve used next to Fluent nHibernate itself – though this newest release has me exceptionally confused.

I’m not trying to critisize or complain, really – but I really don’t get the point of this “NinjectMVC3.cs” file in this newly created “App_Start” directory. Out of the box, it doesn’t even run, and adding the right references to make it run seems a bit counter-intuitive to the ‘simplicity’ aspect of Ninject.

I’m working onNinject.Extensions.Wcf 3.0.0.0.
In developing environment NinjectWebCommon work ok,
but when i deploy on server, it seen this class doesn’t run.

Here is error, could you please help me verify it?

Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

[ServiceActivationException: The service ‘/Server/DomainAdministrationService.svc’ cannot be activated due to an exception during compilation. The exception message is: Object reference not set to an instance of an object..]
System.Runtime.AsyncResult.End(IAsyncResult result) +901424
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult result) +178702
System.Web.AsyncEventExecutionStep.OnAsyncEventCompletion(IAsyncResult ar) +107