Reputation: 3455
I would like to create an ASP.NET MVC web application which has extensible logic that does not require a re-build. I was thinking of creating a filter which had an instance of the IronPython engine. What I would like to know is: how much overhead is there in creating a new engine during each web request, and would it be a better idea to keep a static engine around? However, if I were to keep a single static engine around, what are the issues I might run into as far as locking and script scope? Is it possible to have multiple scopes in the same IropPython engine so I don't get variable collision and security issues between web requests?
Upvotes: 2
Views: 351
Reputation: 29479
I've just started using IronPython as extensibility point in my ASP.NET MVC aplication. I have one ipy engine (in static property) and for each request I create new scope and execute the script in that scope.
Each scope should be independent on other scopes, no locking is needed.
If I run into issues, I'll post it here. However, I don't expect any ;)
Upvotes: 3