Writing an app to monitor a Windows service
Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance
I am writing a Windows Service that reads and processes files on a set
schedule. I want to create a second app that can monitor the Windows
service. The Windows service will write trace messages at certain
points while executing. The monitoring app I want to write will be
very simple, just picking up these traces and displaying them to show
progress of the service.
My question is what is the best method of communication between the
apps? The monitoring app may be run on the same machine or on the same
network as the service, but not, for example, over the internet.
Should I use named pipes? TCP client/server? Ideally, the service
would somehow be able to detect if there were any "listeners" and only
write the trace messages if any listeners were present.
I was wondering what others have done in this regard and can you
suggest some code or topics I should look at? What would be the best
way to accomplish this?
Thanks
.
Relevant Pages
- Re: Windows service interaction with WinForms app?
... | That's the question raised in a previous post [Make a Windows Service ... | and the schedule of the service), then a privileged user thread should be ... A single app ... | communication between the UI and the service occurs when the user requests ... (microsoft.public.dotnet.languages.csharp) - Windows service interaction with WinForms app?
... That's the question raised in a previous post [Make a Windows Service start a windows program]. ... It was suggested that if the service needs to interact with a WinForms app, then a privileged user thread should be used in the UI - no service required. ... The only other communication between the UI and the service occurs when the user requests the "time remaining until next project runtime" from the UI. ... (microsoft.public.dotnet.languages.csharp) - RE: Unable to copy file. ... Access to the path ... is denied.
... not used by any other app. ... references are put in by VS2005 I do not use the resx files. ... ** it the service app used(configured in windows Service manager) when you ... Microsoft MSDN Online Support Lead ... (microsoft.public.vsnet.general) - Re: linux, named pipes (mkfifo) and a hanging application
... creates two named pipes using mkfifo. ... My problem arises when the main app is hanging or stuck at 98-100% CPU ... reproduce), the monitoring client hangs. ... - Dennis Ritchie when asked about the hero worship coming from c.l.c ... (comp.lang.c) - Re: linux, named pipes (mkfifo) and a hanging application
... creates two named pipes using mkfifo. ... My problem arises when the main app is hanging or stuck at 98-100% CPU ... reproduce), the monitoring client hangs. ... - Dennis Ritchie when asked about the hero worship coming from c.l.c ... (comp.lang.c) |
|