Why IIS could not release DLL which have been used in ASP page.

B

Bo

HI guys:
I use vb create a DLL compoment(SessionManger.dll) which is used in
ASP page.

in ASP page(test.asp) code:
<%@ Language=VBScript %>
<%response.buffer = true%>
<%
dim Session
set Session = server.CreateObject("SessionMgr.Session2")
Session("UserName")="gc"
......

Set Session=Nothing
%>

In IE, when launch test.asp , and after a while close it, I founld
SessionManger.dll file is still being in the memory, and have to
restart IIS.
 
P

Patrice

For the sake of scalability.

It is kept in memory likely until the application ends or after a period of
time (I believe you can configure this in COM+) so that if you need it again
in the next few seconds, you don't have to reload the DLL...

Patrice
 
P

Phill. W

Bo said:
I use vb create a DLL compoment(SessionManger.dll) .. . .
In IE, when launch test.asp, and after a while close it, I found
SessionManger.dll file is still being in the memory, and have to
restart IIS.

Yep. That's just what IIS does.

Possible solutions -

Restart IIS, but you know that one already.

Change the Virtual Directory for your application so that is runs
"Highly Isolated"; that way you can [usually] unload just the
application, without having to take the whole web server down.

When developing your DLL, start it (with full-Compile) in the VB
IDE and let it get loaded by the web page. With a /bit/ of luck, it
should stop on any breakpoints you care to put into your code
/and/ you can stop and restart the project as and when you need to.
It's only when the compiled DLL gets loaded that this trouble appears.

HTH,
Phill W.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,773
Messages
2,569,594
Members
45,123
Latest member
Layne6498
Top