Automate service restart

Closed
Aron2roy - May 20, 2011 at 12:03 PM
rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 - May 24, 2011 at 10:34 AM
Hello,
I need assistance figuring out the best way to restart a service based on upon the date modifed of files in a directory. I would like to have the service restart if the date modified of the files are older than 15 minutes. Not sure if I should schedule a batch to run and do this every 14 minutes or if there is a better solution. If using that method, I would also need assistance on how to write the batch. Thank you in advance...
Related:

1 response

rizvisa1 Posts 4478 Registration date Thursday January 28, 2010 Status Contributor Last seen May 5, 2022 766
May 24, 2011 at 10:34 AM
I think you would need a batch job to check for the modified file. depending on how frequently file changes and what is the time frame you are looking for you may end up with 14 mins interval or longer. Since you have a service, why not add on to that service to see if the file has been modified till the acceptable range, if not then exit out of processing else continue to process. all depends on load etc i would think
0