Wrox Programmer Forums
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 18th, 2005, 05:31 AM
Authorized User
 
Join Date: Mar 2004
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to mistry_bhavin
Default Dll Locking

I was comparing classic asp and asp.net.
on Many web sites i found that classic asp has a problem called
DLL Locking. Can any body explain me what is that?


Thank U

 
Old April 18th, 2005, 08:45 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

When a COM reference is made to a COM DLL (like calling it from ASP), a file lock is placed on the COM DLL until the process is finished. In the case of ASP, the web server's process (either inetinfo.exe or sometimes dllhost.exe) establishes the lock. This process normally doesn't end for a long time. You either have to cycle IIS (cmd: iisreset) or reboot. Then the DLL is unlocked.

.NET assemblies on the other hand do not have this problem because it is not referenced by COM. Even when running in ASP.NET. The reason for this is the way .NET works. The .NET assembly contains intermediate code (MSIL: MicroSoft Intermediate Language). MSIL is 'generic' .NET code. When an assembly is needed, .NET pulls in the .DLL file, and compiles the MSIL code to machine code and caches the result. It then turns on a file watch on that DLL file and releases the file. If it sees the file change (you recompile or in another way update the DLL) it drops the cached machine code and recompiles it from the updated DLL.

-Peter





Similar Threads
Thread Thread Starter Forum Replies Last Post
Install problems - VS 6.0 on XP SCRRUN.DLL PDM.DLL jeff4444 Visual C++ 0 December 6th, 2006 08:48 PM
How to convert .NET dll to COM dll used by VB 6.0 gvprashanth .NET Framework 1.x 0 December 4th, 2006 05:05 AM
The database dll crdb_oracle.dll could not be load Yeliz Crystal Reports 0 October 18th, 2006 08:12 AM
DLL & Excel - keep having to reset DLL reference! James Diamond Pro VB 6 2 May 25th, 2004 03:37 AM
Locking Peter Riley SQL Server ASP 3 June 5th, 2003 07:24 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.