Diff. Windows Services

H

Hardip Wadhwa

Hi,

Thought.

What is the difference between Windows services and Scheduled tasks.?

I can run an application and attach it to Scheduled tasks.
It can do everything Start/STOP/schedule/User passwords.

What's the best benefit using Services?

Hardip
 
E

Eric Marvets

Services start when the machine starts and end when the system shuts down
(potentially).

Look at whats on the system implemented as services. Most of them are
'listeners' or 'watchers'. For example, IIS 'listens' to a TCP/IP port for
a user request and then acts upon it. Another example of a 'watcher' is a
custom service that uses the FileSystemWatcher class to monitor an FTP
directory for a file to show up and begin processing it.

If you just have something that needs to be done at a particular interval,
then a scheduled task works better. That way you are not slowing down the
system 24/7 with an extra process. Even if the process is mostly idle, is
still is appropriated memory space and access to the CPU.

--
Eric Marvets
Principal Consultant

the bang project

<shameless self promotion>

Email (e-mail address removed) for Information on Our Architecture and
Mentoring Services

</shameless self promotion>
 
H

Hardip Wadhwa

Hi Eric,

Thanks for the reply, But, why can't i start the 'listeners' or 'watchers'
in Scheduled tasks, when computer starts?

Potentially theses tasks will end when system shut down and restart when
system starts.

As services do take up memory and CPU process, the task is also very
similar.

So again why services is a different concept than tasks?

Hardip
 
E

Eric Marvets

You are right, you could do that.

Its just what they were designed for. Services can be started, stopped,
paused, etc. A task merely runs at a particular interval. Generally you
have a task run for a period of time and then shut down, while a service is
intended to run constantly.

--
Eric Marvets
Principal Consultant

the bang project

<shameless self promotion>

Email (e-mail address removed) for Information on Our Architecture and
Mentoring Services

</shameless self promotion>
 

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

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top