[Mono-dev] DynamicModuleHelper and HttpApplication RegisterModule methods

Miguel de Icaza miguel at xamarin.com
Fri May 2 20:39:34 UTC 2014

I just did a quick review, and added a series of comments.

Among other things, it is missing tests :-)

On Thu, Apr 24, 2014 at 9:51 AM, Martin Thwaites
<monoforum at my2cents.co.uk>wrote:

> I've just found that Matthid on Github has done a far better
> implementation in pull 888 so I won't bother...
> Who needs to look at it before it's merged?
> On 23 April 2014 19:56, Martin Thwaites <monoforum at my2cents.co.uk> wrote:
>> First, I'm not asking for something to be implemented, I'm asking for
>> help implementing it as I think there will be more and I'm endeavoring to
>> implement them all if possible.
>> I'm having a play with trying to get the MVC5 boilerplate working on mono
>> and one of the libraries (Microsoft.Owin) uses the new
>> HttpApplication.RegisterModule method, which is not yet present in the
>> current master branch.
>> Looking at the descriptions on MSDN, there is very little information on
>> what it's supposed to do, but it looks like it just does the same as the
>> method DynamicModuleHelper.RegisterModule... in that it just registers a
>> module at runtime, in memory.
>> So, in light of the above, I have a few questions.
>> 1. Would a pull be accepted if it just copies the implementation from the
>> Microsoft.Web.Infrastructure class in the current mono codebase?  Given
>> that the new method is in the HttpApplication class, I would say that it's
>> a valid assumption that it's only Web modules that can be added.
>> 2. If I'm just copying the implementation into System.Web, would it be
>> advisable to edit the Microsoft.Web.Infrastructure class to just forward
>> through to System.Web?
>> 3. What, if any, tests should be created (I'm used to working in an
>> environment with interfaces that could be mocked with Moq).  I could do
>> with some information on how to do this, in terms of possibly some examples
>> that are considered good, and locations in the current codebase.
>> 4. Given that this is only available in .NET 4.5, is there some way I
>> should stop it from being accessible on .NET 4.0 (if so, how)? I'm not sure
>> there is an issue with leaving it available on .NET 4.0 other than the mono
>> version has more methods than .NET...
>> References:
>> http://msdn.microsoft.com/en-us/library/microsoft.web.infrastructure.dynamicmodulehelper.dynamicmoduleutility.registermodule%28v=vs.111%29.aspx
>> http://msdn.microsoft.com/en-us/library/system.web.httpapplication.registermodule%28v=vs.110%29.aspx
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140502/e5f5ad91/attachment.html>

More information about the Mono-devel-list mailing list