[Mono-list] mod_mono and swapping out web application assemblies

Jim Erwin mono@eyekahn.com
Tue, 13 Jul 2004 11:23:21 -0500


I know mod_mono is a bit behind the core release of mono in terms of
maturity, however there is an issue I've come across that I'd like to
find a way to resolve, or at least find a best practice to handle it.

If I simply want to change the assemblies in the bin folder of a web
application with IIS/Windows from a VS.NET compiled project, I can
simply copy over the old ones. At this point, JIT compilation and
caching occur as soon as the next page hit occurs without any other need
for admin intervention. The same is not true when using mod_mono.

When I simply swap out assemblies with mod_mono, I get errors that the
classes can't be found. At this point, the only thing I know to do that
works is to run "killall mono" from a root prompt. At this point, the
server processes are restarted and on the next page hit, the JIT
compilation takes place. All is well. The down side of this as I see it
is that this will kill ALL mono applications on the box. So if I'm
running multiple web applications, or other non-web mono applications on
the server, all of them get killed at this point.

A perfect resolution would be to have mod_mono treat new assemblies the
same way IIS does on Windows. I'm assuming that this may take quite a
bit of work to implement or may never be done. The next option would be
to have a utility where you can pass which application needs to be
reloaded for a web application and have all of the behavior for that
handled in the background. The question is then how to determine which
instances of "mono mod-mono-server.exe" are attached to a specific web
application.

Thoughts and ideas on how to resolve this would be greatly appreciated.

regards,

JE