Taritsyn / JavaScriptEngineSwitcher

JavaScript Engine Switcher determines unified interface for access to the basic features of popular JavaScript engines. This library allows you to quickly and easily switch to using of another JavaScript engine.
Apache License 2.0
447 stars 49 forks source link

Issue on deployment #15

Closed PaulInglis closed 8 years ago

PaulInglis commented 8 years ago

Hi, I have an issue when I'm deploying the files. I always get an "access denied" when trying to delete the ClearScript.V8/ClearScriptV8-32.dll file. What does this file do and why is IIS still holding on to it when I'm trying to deploy files?

Taritsyn commented 8 years ago

Hello, Paul!

ClearScriptV8-32.dll file contains a native .NET wrapper around the 32-bit version of V8 JS engine (v8-ia32.dll file). In general, without this file the JavaScriptEngineSwitcher.V8 will not work.

To remove this file you need to stop website.

momadthenomad commented 6 years ago

@Taritsyn am I correct in assuming that the latest 2.X release of JavaScriptEngineSwitcher.V8 will not have the same file locking issue?

Taritsyn commented 6 years ago

Hello, Mohamed!

This problem is more general and typical not only for the JavaScript Engine Switcher. Since a days of Classic ASP there is a simple rule: “Do not update the native assemblies, when web application is running.”. In .NET Framework for updating of native assemblies always require an restart of IIS or application pool.

.NET Core doesn't have this problem, because it uses a different approach to working with the native assemblies (mechanism based on the runtimes directories and RIDs).