I read some articles about Application Domain.The deep reading finally resulted in whirling
confusion.So I submit the questions to subject experts.
1) As CLR takes care of creating AppDomain as and when needed,could there be a critical
need to go for manual Application Domain Creation ?
2)I heard that one application domain can not share data with other application domain (i
am not sure).What about the case of windows communication foundation ?
3) Normally the basic libraries (system.dll,mscorlib.dll) are loaded in default application domain. can i load them in custom created application domain ? if it is possible,will CLR keep a copy in Default application domain ?
like
------------------ ----------------
Default AppDomain Custom Appdomain
------------------- ----------------
mscorlib.dll mscorlib.dll
System.dll System.dll
..... .......
----------------- -----------------
4) What is the term context-agile object in application domain referes to?
Creating your own AppDomains is useful sometimes when you want isolation (e.g. sandboxing 3rd party code), or the ability to reload code which changes during execution. (You can’t unload an assembly, but you can unload an AppDomain.)
Sharing data between AppDomains involves marshalling. The data can either be marshalled by value (i.e. everything gets copied) or by reference if your object derives from
MarshalByRefObject. In the latter case, what actually gets through to the otherAppDomainis a reference to a proxy object. Anything you do on the proxy is actually done to the real object in the originalAppDomain.Not entirely sure what you mean. You can certainly use all the system assemblies in other AppDomains.
I haven’t come across this term, that I can remember.