I have a requirement, that a mail should be send to a particular person, if certain condition is met in a database. this program needs to run periodically. say for example, daily.
Is their any Facility in J2EE through which we can do this kind of sheduling. Suppose for example, if my programme needs to run every morning. is there any facility in J2EE which makes this possible.
I am Using Weblogic 5.1.
To my knowledge there are no scheduling facility in the J2EE platform (I've been missing this myself at times), but if you're willing to use platform specific functions you can probably achieve what you want by using the Weblogic Time API (http://www.weblogic.com/docs51/classdocs/API_time.html) where you can schedule events.
Checkout Flux 3.0, it does what you you're looking for there is an article about this on TheServerSide.com at https://www.theserverside.com/resources/article.jsp?l=Job-Scheduling-In-J2EE-Applications
I had a scheduling assignment for my project and was able to solve it by using the Timer and TimerTask classes in the JDK 1.3 in the java.util package.
Yes, you could probably solve it by using those classes, but when you create a Timer instance you also create a new Thread which is in violation of the EJB specification.