1

I want to schedule a java program in weblogic that runs every night can you any one help on this ?

Ee can do this using thread but I don`t think that is efficient way.

bummi
  • 27,123
  • 14
  • 62
  • 101

2 Answers2

2

WebLogic 11g is a Java EE 5 compliant application server. So you can use the TimerService:

@Singleton
public class TimerSessionBean {
  @Resource
  TimerService timerService;

  @Schedule(minute="0", hour="1")
  public void atOneInTheNight() {
    // Do stuff
  }
}
Community
  • 1
  • 1
1

I would go for Quartz Scheduler. http://quartz-scheduler.org/

heldt
  • 4,166
  • 7
  • 39
  • 67