3 Replies Latest reply on Jul 10, 2007 6:58 AM by marilenc

    Ejb 3s and scheduling with cron expression.

    paradigmza

      Hi,


      I have a "simple" problem and I was wondering if there is a easy solution...

      I have an EJB3

      @Stateless
      public class SendSettlementEmailBean implements SendSettlementEmail {
       public void sendEmail() {
       System.out.println("Running Now");
       }
      }



      Now I want this piece of code to run on the 1st day of every month? How do I go about doing that?

      I tried using quartz, but it only works with ejb 2.1, and I had a brief look at the EJB3 Timer but it looks like it can't take a cron expression?

      Is there a standard way to do this?

      Thanks Sean.