Single DLL vs. Multiple DLLs

T

thejeffross

When building a website in ASP.Net, are there any advantages to
compiling everything into multiple DLLs (one per .aspx, .ascx, etc) in
the website project model vs. the single DLL generated by a web
application project?

I can see the benefit of having multiple DLLs in that you can replace
the DLL corresponding to one codebehind file and not worry about
deploying unwanted code somewhere else on the site, but are there any
other advantages?

My testing showed that with either model, dropping a DLL into the bin
folder results in the application restarting, so all classes in the
application have to be reloaded with either approach when a change is
made.
 
P

Patrice

Hello,
When building a website in ASP.Net, are there any advantages to
compiling everything into multiple DLLs (one per .aspx, .ascx, etc) in
the website project model vs. the single DLL generated by a web
application project?

I saw a paper mentionning less work to load those multiple DLLs...
I can see the benefit of having multiple DLLs in that you can replace
the DLL corresponding to one codebehind file and not worry about
deploying unwanted code somewhere else on the site, but are there any
other advantages?

Compilation time as some code is moved in a DLL and doesn't need to be
compiled if you don't touch this particular project...

IMHO always favor what makes senses from an architectural point of view
(i.e. likely by layers as a start). It will fit unless you are at extremes
(such as a mega site in a single DLL or a site made of hundreds of DLLs) and
micro-optimization are irrelevant against having a manageable architecturen,
readable code, etc...
 

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

Top