<div>The best is to host the scriptingruntime in global.asax</div><div><br></div><div>A script scope is something that you can think of as a unit of runnable script (1 or more files) so in a web scenario I&#39;d say that a scriptscope is scoped to a request.</div>

<div><br></div><div>For IronRubyMVC it works like this:</div><div>Global.asax initializes the ruby engine and stores it in a static var</div><div>The ruby engine initializes the runtime and scriptengine</div><div><br></div>

<div><a href="http://github.com/casualjim/ironrubymvc/blob/master/IronRubyMvc/Core/RubyMvcApplication.cs">http://github.com/casualjim/ironrubymvc/blob/master/IronRubyMvc/Core/RubyMvcApplication.cs</a></div><div><a href="http://github.com/casualjim/ironrubymvc/blob/master/IronRubyMvc/Core/RubyEngine.cs#L389">http://github.com/casualjim/ironrubymvc/blob/master/IronRubyMvc/Core/RubyEngine.cs#L389</a></div>

<div><br></div><div>hope this helps otherwise give us some more specific questions </div><div>---<br>Met vriendelijke groeten - Best regards - Salutations<br>Ivan Porto Carrero<br>Blog: <a href="http://flanders.co.nz">http://flanders.co.nz</a><br>

Twitter: <a href="http://twitter.com/casualjim">http://twitter.com/casualjim</a><br>Author of IronRuby in Action (<a href="http://manning.com/carrero">http://manning.com/carrero</a>)<br><br>
<br><br><div class="gmail_quote">On Tue, Feb 2, 2010 at 2:08 PM, Marco Parenzan <span dir="ltr">&lt;<a href="mailto:marco.parenzan@libero.it">marco.parenzan@libero.it</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">Dear All,<br>
<br>
are there any advices about hosting DLR under <a href="http://ASP.NET" target="_blank">ASP.NET</a> for scripting? (not<br>
for views!)?<br>
Where hosting ScriptingRuntime, ScriptingEngine?<br>
As static variables in Global.asax? In Application?<br>
Where hosting ScriptingScope? In Session? Destroy and reistantiate at each<br>
call?<br>
<br>
I have to develop an <a href="http://ASP.NET" target="_blank">ASP.NET</a> MVC application, with no serious performance<br>
issues, but I don&#39;t want to abuse...<br>
<br>
Thanks in advance<br>
<br>
        Marco Parenzan<br>
<br>
_______________________________________________<br>
</div>Ironruby-core mailing list<br>
<a href="mailto:Ironruby-core@rubyforge.org">Ironruby-core@rubyforge.org</a><br>
<a href="http://rubyforge.org/mailman/listinfo/ironruby-core" target="_blank">http://rubyforge.org/mailman/listinfo/ironruby-core</a><br>
</blockquote></div><br></div>