473,396 Members | 1,608 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Question on article by Scott about "Shadow copy of an assembly"

Hello All,

I just finished reading an interesting article by Scott about App Domains:
http://odetocode.com/Articles/305.aspx

Scott, I have a question about the section "Shadow Copies and Restarts". You
talked about "Drain Stopped" and "Shadow Copy" concepts in this article. I
maintain a web application which is in production. Every morning the way we
build the project is using Visual Studio's IDE to use "Build ->
Build<proj-name>" which basically builds all the files and copies the DLL
into the bin directory. Now during this build process, users are still using
our web application and sometimes they notice a weird error because of the
build process.

Now according to your article, if we simply copy the DLL into the bin
directory without building the project while users are using the machine can
we still take advantage of "Drained Stopped" behavior of AppDomains?

Why are my users noticing the weird errors if you think that App Domains use
the "Drain Stopped" phenomenon?

What are the differences between using IDE's build to build the web app
while users are using the web app VS Shadow copy?

Thanks a bunch
Feb 2 '06 #1
2 2222
Building a site using the IDE is not the same as "shadow copy". You still
need to provide the updated DLL to the website. For instance, suppose that
some bug was fixed, you still need to compile the assemblies in the IDE.
Then you would copy the DLL to the bin folder of your production website.

"Shadow copy" simply means that IIS will copy the assembly into a temp
location. Therefore the actual assembly running is not the one in the bin
folder but someone else, thereby preventing locks from happening.

I am not sure what "weird" issues your customers are having, but there are
some consequences the way I understand it to reloading the AppDomain. It is
my understanding that the sessions and other cross-post persistent
information is cleared when an AppDomain recycles. The AppDomain can
recycle in other situations as well like when the server determines that too
much memory is being used and other issues. It might recycle the AppDomain
to clear things like memory leaks.
"Diffident" <Di*******@discussions.microsoft.com> wrote in message
news:11**********************************@microsof t.com...
Hello All,

I just finished reading an interesting article by Scott about App Domains:
http://odetocode.com/Articles/305.aspx

Scott, I have a question about the section "Shadow Copies and Restarts".
You
talked about "Drain Stopped" and "Shadow Copy" concepts in this article. I
maintain a web application which is in production. Every morning the way
we
build the project is using Visual Studio's IDE to use "Build ->
Build<proj-name>" which basically builds all the files and copies the DLL
into the bin directory. Now during this build process, users are still
using
our web application and sometimes they notice a weird error because of the
build process.

Now according to your article, if we simply copy the DLL into the bin
directory without building the project while users are using the machine
can
we still take advantage of "Drained Stopped" behavior of AppDomains?

Why are my users noticing the weird errors if you think that App Domains
use
the "Drain Stopped" phenomenon?

What are the differences between using IDE's build to build the web app
while users are using the web app VS Shadow copy?

Thanks a bunch

Feb 2 '06 #2

Peter,

Thanks for your reply but I have a question. Earlier in my post when I said
"build" I was referring to the fact that I usually open the production web
app's csproj file using the "File > Open From Web" option and then build the
project while users are using it. Bin directory in my case would be the App
Base's bin directory as I am building the project on server.

So in my case does "Build" cause the AppDomain to reload?

Why would it reload the AppDomain if IIS shadow copied my old assembly?

Thanks for your clarification.

"Peter Rilling" wrote:
Building a site using the IDE is not the same as "shadow copy". You still
need to provide the updated DLL to the website. For instance, suppose that
some bug was fixed, you still need to compile the assemblies in the IDE.
Then you would copy the DLL to the bin folder of your production website.

"Shadow copy" simply means that IIS will copy the assembly into a temp
location. Therefore the actual assembly running is not the one in the bin
folder but someone else, thereby preventing locks from happening.

I am not sure what "weird" issues your customers are having, but there are
some consequences the way I understand it to reloading the AppDomain. It is
my understanding that the sessions and other cross-post persistent
information is cleared when an AppDomain recycles. The AppDomain can
recycle in other situations as well like when the server determines that too
much memory is being used and other issues. It might recycle the AppDomain
to clear things like memory leaks.
"Diffident" <Di*******@discussions.microsoft.com> wrote in message
news:11**********************************@microsof t.com...
Hello All,

I just finished reading an interesting article by Scott about App Domains:
http://odetocode.com/Articles/305.aspx

Scott, I have a question about the section "Shadow Copies and Restarts".
You
talked about "Drain Stopped" and "Shadow Copy" concepts in this article. I
maintain a web application which is in production. Every morning the way
we
build the project is using Visual Studio's IDE to use "Build ->
Build<proj-name>" which basically builds all the files and copies the DLL
into the bin directory. Now during this build process, users are still
using
our web application and sometimes they notice a weird error because of the
build process.

Now according to your article, if we simply copy the DLL into the bin
directory without building the project while users are using the machine
can
we still take advantage of "Drained Stopped" behavior of AppDomains?

Why are my users noticing the weird errors if you think that App Domains
use
the "Drain Stopped" phenomenon?

What are the differences between using IDE's build to build the web app
while users are using the web app VS Shadow copy?

Thanks a bunch


Feb 2 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Nick Jacobson | last post by:
This question is with regard to the * operator as used for sequence concatenation. There's the well-known gotcha: a = ] b = a*3 b = 4 print b
0
by: Tom Clement | last post by:
Hi folks. I have a question about "Copy Local". We have quite a few projects in our solution (35) and some of them reference the very large "Microsoft.mshtml.dll". I was wondering why leave...
27
by: Shagy | last post by:
Greetings, I've been trying to find an equivant c funtion to the c++ copy function. Description: copy(char *cstring, size_t count, size_t offset); Copies "count" characters from a C-style...
2
by: Kevin Frey | last post by:
Is it possible to get c# perform a using statement where the namespace for the using is not specified literally but instead comes from a variable, a token, a predefined value etc. We have...
0
by: Diffident | last post by:
Hello All, I am trying to do a "build" of all files of my web app on my local machine. I know that there is an "aspnet_wp.exe" running forever on my machine and to my knowledge each web app is...
2
by: Nils Magnus Englund | last post by:
Hello, In the root of a web site (C:\Inetpub\wwwroot), I have a .NET 1.1 application. I've just added a .NET 2.0 application to another directory under the web site root...
3
by: GMiller | last post by:
I have deployed a .NET 2 application on a customer's system. I'm trying to use the .NET 1.1 configuration tool to load the assembly but I always get an 'unable to load assembly" message. What is...
4
by: Waldy | last post by:
Hi there, does anyone know the cause of this problem. When I press F5 to debug a C# web application, I get an error message that begins "Cannot create/shadow copy " then various different file...
1
by: mrpetegroups | last post by:
Hi - Problem: The file below has become zero length \winnt\assembly\GAC_MSIL\system.deployment\2.0.0.0_b03f5f7f11d50a3a \system.deployment.dll Details follow ... I've been programming...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.