Servlet which executes itself after a certain time

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • plsHelpMe
    New Member
    • Jan 2008
    • 58

    #1

    Servlet which executes itself after a certain time

    Hi All,

    I want to a servlet which will execute after every 24 hours to do some processing. Can anybody suggest me any best solution. I am using struts framework v 1.1

    TIA
  • JosAH
    Recognized Expert MVP
    • Mar 2007
    • 11453

    #2
    Why do you want a Servlet to execute periodically? What Servlet specific method
    do you want to execute and what should the parameter values be? Why not fire
    up an POJO (Plain Old Java Object) periodically using a simple Timer and a
    TimerTask?

    kind regards,

    Jos

    Comment

    • plsHelpMe
      New Member
      • Jan 2008
      • 58

      #3
      Thanks buddy,

      Actually i am having an application built in Struts. I want that a mail is shoot to a person (Who is on support that day) every morning. Now please tell me how i should go for it. Earlier i was planning to code a servlet whose service method would be called every day automatically.. ..but i am not sure how to go for it.

      Comment

      • itsraghz
        New Member
        • Mar 2007
        • 124

        #4
        That's nice. Why not considering "Quartz" which helps you do the same task?

        Try looking at the URL here http://www.opensymphon y.com/quartz/

        Comment

        • plsHelpMe
          New Member
          • Jan 2008
          • 58

          #5
          Thanks,
          I will try to check it

          Comment

          Working...