473,396 Members | 1,734 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.

AppDomains

Okay, I've banged my head against a wall for over a year now. Maybe
I'm just a rock when it comes to this.

I've got a new project, a Windows Service. The "application" itself is
in a DLL that is referenced by the exe. I did this for ease of
updating, just copy my new DLL(s) into an update directory and restart
the service when convienant. when the service EXE starts, it checks
for anything in my update dir, copies them over to the working dir,
then creates a new instance of the object inside my dll. This works
nicely, but I sat up last nite and wondered if I should explore loading
my DLL(s) into an appDomain of it's own, so when the service itself
finds a new DLL(s) in the update dir, it can just close the appDomain
the DLL(s) are in, then copy the junk over, and re-create the
appDomain. Nice and pretty.

There's one drawback, I have two event the DLL generates that my main
service captures and uses for varying reasons, so how to I proxy an
event across an appDomain???

I am friggin helpless in this matter for some odd reason.

JLW

--

Nov 21 '05 #1
2 1134
about the update With .net you can just drop the new dll on top of the other
dll. That is how your update is done.

About the remote call take a look at RPC. You should have no problems doing
this over a proxy

"Jody L. Whitlock" <ti*************@hotmail.com> wrote in message
news:O2**************@TK2MSFTNGP14.phx.gbl...
Okay, I've banged my head against a wall for over a year now. Maybe
I'm just a rock when it comes to this.

I've got a new project, a Windows Service. The "application" itself is
in a DLL that is referenced by the exe. I did this for ease of
updating, just copy my new DLL(s) into an update directory and restart
the service when convienant. when the service EXE starts, it checks
for anything in my update dir, copies them over to the working dir,
then creates a new instance of the object inside my dll. This works
nicely, but I sat up last nite and wondered if I should explore loading
my DLL(s) into an appDomain of it's own, so when the service itself
finds a new DLL(s) in the update dir, it can just close the appDomain
the DLL(s) are in, then copy the junk over, and re-create the
appDomain. Nice and pretty.

There's one drawback, I have two event the DLL generates that my main
service captures and uses for varying reasons, so how to I proxy an
event across an appDomain???

I am friggin helpless in this matter for some odd reason.

JLW

--

Nov 21 '05 #2
Chris wrote:
about the update With .net you can just drop the new dll on top of
the other dll. That is how your update is done.

About the remote call take a look at RPC. You should have no problems
doing this over a proxy

"Jody L. Whitlock" <ti*************@hotmail.com> wrote in message
news:O2**************@TK2MSFTNGP14.phx.gbl...
Okay, I've banged my head against a wall for over a year now. Maybe
I'm just a rock when it comes to this.

I've got a new project, a Windows Service. The "application"
itself is in a DLL that is referenced by the exe. I did this for
ease of updating, just copy my new DLL(s) into an update directory
and restart the service when convienant. when the service EXE
starts, it checks for anything in my update dir, copies them over
to the working dir, then creates a new instance of the object
inside my dll. This works nicely, but I sat up last nite and
wondered if I should explore loading my DLL(s) into an appDomain of
it's own, so when the service itself finds a new DLL(s) in the
update dir, it can just close the appDomain the DLL(s) are in, then
copy the junk over, and re-create the appDomain. Nice and pretty.

There's one drawback, I have two event the DLL generates that my
main service captures and uses for varying reasons, so how to I
proxy an event across an appDomain???

I am friggin helpless in this matter for some odd reason.

JLW

--


Thanks for the response Chris. It seems like RPC is used more for
WebServices, which is not what I'm interested in. It seems everytime I
look inot AppDomains and Remoting, i always end up at WebServices. So,
I guess I will not be using AppDomains and just not be able to use .NET
to it's fullest potential.
I've looked through the MSDN docs on AppDomains, and those are the
worst set of docs I've ever seen come from MS! they read like a
japanese person writing a korean car manual!
And yes, I can use the ShadowCopy method of an AppDomain, but I'm still
faced with dynamic unloading and reloading of the support libraries,
either way I'm stuck shutting down and restarting this service of 120
servers. So, I guess PSEXEC is going to be my best friend in this
since I can't seem to find a straightforward method of doing this.
I was also thinking of replacing my TCP Server that I built into this
service for remote admin functionality with Remoting, but everything I
find is very vague to say the least.

thanks,
JLW

--

Nov 21 '05 #3

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

Similar topics

1
by: Daylor | last post by:
hi. i have mult thread vb.net application. it has 30 threads. each thread serves 1 phone caller. the question : is there a reason , to create appdomain for each Phone Service ? meaning 30...
4
by: Mountain Bikn' Guy | last post by:
I need some advice on this. I am working on a fairly complex calculator app (C#) with lots of functions (and these functions in turn use math functions from an unmanaged C DLL). A calculation takes...
0
by: Brian Takita | last post by:
Hello, I'm getting the following error at the end of this message when trying to run the ReportManager and the ReportServer: Assembly system.data.dll security permission grant set is...
1
by: billr | last post by:
hi there, I hope that someone will be able to shed some light on little old confused me. We are developing an application which will be deployed onto a Terminal Server machine. The application...
8
by: Fred Mertz | last post by:
I'm working towards an MCTS cert and I'm having to learn a bunch of stuff that I doubt I'd stumble across on my own. One such feature of .NET is AppDomains; programatically creating new AppDomains...
0
by: kayakyakr | last post by:
I'm working with a set of experiments in a large system that is using AppDomains for isolation and wants to make a call out to an umanaged dll. The test dll has two methods, SetNumber(int num) and...
3
by: | last post by:
If this is simple, forgive my ignorance, but I'm coming from the CompactFramework where we don't use AppDomains. I did a fair bit of archive searching and couldn't find an answer and I got no...
0
by: jeremyje | last post by:
I would like to create an application where I have many concurrent processes being managed by a monitoring process. Each process that is "managed" will be invoked from an assembly dll (think...
0
by: PRR | last post by:
Here is a code i found on "how to enumerate appdomains in a current process". The original code was posted by Thomas Scheidegger Add the following as a COM reference -...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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
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.