An Adaptive Middleware for Supporting Time-Critical Event Response in Distributed Environments Qian Zhu Gagan Agrawal Department of Computer Science and Engineering Ohio State University Columbus, OH, 43210 {zhuq,agrawal}@cse.ohio-state.edu 1 Introduction There are many applications where a timely response to an important event is needed. Often such response can require a significant computation and possibly communication, and it can be very challenging to complete it within the time-frame the response is needed. The resources available for the pro- cessing may only be detected when the event occurs, and may not be known in advance. At the same time, there could be application-specific flexibility in the computation that may be desired. For example, models can be run at different spatial and temporal granularities, or running all models may not be equally important. There could be a user provided benefit func- tion, which captures what is most desirable to compute. There is a need for a middleware that can complete compu- tation within the pre-specified time frame, while attempting to maximize the pre-specified benefit function, in view of the re- sources available at runtime. We have recently initiated work on such a middleware. The main contributions of our work are as follows. • We have designed and implemented an autonomic mid- dleware for handling time-critical events. Our design is based on the Service-Oriented Architecture(SOA). Fur- thermore, we have developed AutoServiceWrapper to en- able the autonomic properties of service components. • We have given a formulated model for the adaptation pro- cess in our framework based on the optimal control the- ory. The model is further deployed to guide an effective adaptation. • We have proposed an autonomic adaptation algorithm that optimize the performance within the time constraints by adapting service parameters. Furthermore, the algo- rithm detects global patterns based on local adaptation to improve the efficiency. Both a volume rendering application and a Great Lake fore- casting application have been used to carefully evaluate our middleware and algorithm. The main observations from our experiments were as follows: • When handling a time-critical event, we were able to opti- mize the benefit function within the pre-defined time con- straints by service parameter adaptation. Furthermore, the parameters converged fast to their ideal values. • The overhead of adaptation caused by the proposed algo- rithm in time-critical event handling is below 14% com- paring to the optimal execution that started with ideal pa- rameter values. • The overhead of the proposed algorithm in the learning phase is only 5% for the volume rendering application and is around 10% for the Great Lake forecasting appli- cation, for adapting 3 service parameters. The rest of the paper is organized as follows. We motivate our work by two real-life applications in Section 2. The de- sign of the adaptive middleware is described in Section 3. In Section 4, we propose the system model and our autonomic adaptation algorithm. Results from experimental evaluation are reported in Section 5. We compare our work with related research efforts in Section 6 and conclude in Section 7. 2 Motivating Applications This section describes two applications we are currently tar- geting. Both the applications require time-critical response to certain events. Volume Rendering involves interactively creates a 2D projec- tion of a large time-varying 3D data set (volume data) [12]. This volume data can be streaming in nature, e.g., it may be generated by a long running simulation, or captured contin- uously by an instrument. An example of the application is rendering tissue volumes obtained from clinical instruments in real-time to aid a surgery. Under normal circumstances, the system invokes services for processing and outputs images to the user at a certain frame-rate. In cases where a notable event is detected in a particular portion of the image, the user may want to obtain detailed information on that area as soon as pos- sible. For example, if an abnormality emerges in a part of the rendered tissue image, the doctor will like to do a detailed di- agnosis in a timely fashion. Time may be of essence, because of the need for altering pa- rameters of the simulation or the positioning of the instrument. In obtaining the detailed information, there is flexibility with respect to parameters such as the error tolerance, the image size and also the number of angles at which the new projec- tions are done. Now, let us suppose that we can formally define a benefit function, which needs to be maximized in the given amount of time and with given resources. Let the set of all possible view directions be denoted as Δ. Let N b be the total num- ber of data blocks in the dataset. For any given data blocks