Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
alphaWorks : Method Scheduler for Java : Overview
[go: Go Back, main page]

IBM®
Skip to main content
    United States change      Terms of use
 
 
      
     Home      Products      Services & solutions      Support & downloads      My account     
alphaWorks  >  Java technology  >  

Method Scheduler for Java

A robust scheduler component that allows developers to execute methods on Java objects asynchronously and/or repeatedly.


Date Posted: May 28, 2004
OverviewRequirements Download FAQs Forum Reviews

What is Method Scheduler for Java?

Method Scheduler for JavaTM (MS4J) is a robust scheduler component that allows developers to execute methods on Java objects asynchronously and/or repeatedly. It is easy to learn and simple to use.

Asynchronous data flows have not been emphasized in J2EE. Servlets and Java Server Pages (JSPs) are usually multithreaded, but they remain fundamentally synchronous. The same is true for most Java data adapters; they are frequently multithreaded, yet synchronous.

At the same time, as the general complexity of a Web application increases, asynchronous facilities become a necessity. They are necessary, for example, for keeping memory caches fresh, for scheduling repetitive method invocations in general, or for increasing page response times by performing certain input/output (I/O) operations (such as database updates) asynchronously, in parallel with or after page delivery to the client.

Method Scheduler for Java is designed to partially fill these gaps. It does not require modification of the classes and methods to be invoked. This feature helps when there is a lot of code that is already written. Method Scheduler for Java also uses configurable thread pools, which can prevent system slowdowns during periods of high loads.

How does it work?

Method Scheduler for Java helps developers schedule asynchronous tasks. The user must download the JAR file and place it in the classpath of the virtual machine. Included is a sample application that illustrates how the code can be invoked. Before any tasks are scheduled, the MS4J Manager must be started. It initializes all internal threads and ensures that they are ready to process tasks. The invoking application must identify the method that needs to be executed, the object instance on which the method is to be called, the arguments (if any), the expected return code, the time of the execution, whether or not the method is to be called repeatedly, and how many times the invocation is to be re-tried if it fails. The system relies on the Java reflection mechanism in order to gain access to methods of a given object.

About the technology author(s):
Dima Rekesh is an architect with the Emerging Technologies group in the office of CIO. Some of his areas of interest include social networks, their visualization, and the impact of "blogging" on the enterprise. In the past, Dr. Rekesh led several large Web projects, including the IBM Intranet Portal.

download Download now
Request license Request a license

Related technologies

For platform(s):
Java

For topics:
scheduler, asynchronous, J2EE, IO


Related resources

Press Articles

 

    About IBM Privacy Contact