1、个人博客网站设计外文文献及翻译及感应式ID卡办公门禁考勤一卡通管理系统方案计划书外文文献资料收集: 应用技术学院 计算机科学与技术(外文文件名: JSP Splitting for Improving Execution Performance)AbstractSplitting a JSP (Java Server Pages) page into fragments can improve the execution performance of JSP pages when the Web application server can separately cache the Web p
2、age fragments obtained by executing the JSP fragments. If a JSP page is split into fragments according to the update frequency of each portion of the Web page obtained by executing the JSP page, all of the split JSP fragments do not need to be executed again when only a single cached part of a Web p
3、age expires. In addition, the fragments of a JSP page can be reused by other JSP pages. In both cases, the execution results of all of the JSP fragments split from the JSP page must be the same as from the JSP page before it was split. In this paper, we propose JSP splitting, which is a method of sp
4、litting a JSP page into fragments maintaining the data and control dependences existing in the original JSP page. JSP splitting automatically detects the portions needed to maintain the data and control dependences of a JSP page for the portions that developers want to split from the JSP page. We im
5、plemented JSP splitting with a GUI tool, and confirmed that the split JSP fragments were executed in the same as the way as the JSP page before the split. Experimental results show that the response time to access a Web page can be reduced by splitting a JSP page into fragments and setting different
6、 caching periods for the Web page fragments obtained by executing the JSP fragments.1. IntroductionSplitting a JSP (Java Server Pages) page into fragments can improve the execution performance of some JSP pages when the Web application server can separately cache the Web page fragments obtained by e
7、xecuting the fragments of the JSP page. The period of caching dynamic Web pages generated by a JSP engine is limited due to the dynamic nature of the content. When the cached content of a Web page generated by a JSP engine is updated, the entire JSP page must be executed again on the application ser
8、ver, even though the change of the Web page might be small. Since frequent updates of cached Web pages increase the load on an application server, it is reasonable to split a JSP page into fragments and set different caching periods for the Web page fragments obtained by executing the JSP fragments.
9、 Of course, the Web page fragments must be merged into a final Web page correctly. The Dynacache technology of IBM WebSphere Application Server allows Web page fragments to have different caching periods. Cache tag libraries provided by the Apache Jakarta Project also support different caching perio
10、ds for the JSP fragments. In addition, ESI (Edge Side Includes) technology provides a mechanism to cache Web page fragments with different caching periods, and to merge them into a final Web page on an edge server.The application offload technology of IBM WebSphere Edge Server is another approach to
11、 improve the execution performance of JSP pages. This technology allows one or more JSP fragments to be cached and executed on edge servers. The remaining JSP fragments are deployed on the application server and are called by the JSP fragments executed on the edge server. Thus, some of the execution
12、 of a JSP page is offloaded to the edge server. Splitting a JSP page facilitates the reuse of JSP fragments. When a Web application consists of many JSP pages, the same portions tend to exist in many JSP pages. Examples are the frames, the banners, the headers, and etc. When a JSP page is split into
13、 fragments, the total execution result of all of the fragments must be the same as the JSP page before it was split. In addition, when the fragments of a JSP page are executed in different servers, each fragment needs to be executed without the other fragments. In order to satisfy these conditions,
14、we propose JSP splitting, which is the method of splitting a JSP page into fragments described in this paper. Since it is very difficult to automatically find the best way to split a JSP page into fragments for some particular purpose, we assume that the developers will select the portions that they
15、 want to split into fragments. In order to execute all of the divided JSP pages correctly, JSP splitting automatically detects any portions that must be moved or copied into a fragment with the selected portions. The detection is done based on the analysis of the data and control dependences existin
16、g in a JSP page. JSP splitting is similar to the program slicing technique that slices a program based on the data and the control dependences. However, the program slicing technique does not take into account that the sliced programs are executed independently and that the total execution result of
17、 the sliced programs must be the same as the program before the division. In addition, since data is passed to the JSP engine during the execution of JSP pages, the source program of the JSP engine, such as Apache Tomcat, is required in order to analyze the data dependences correctly. This is imprac
18、tical, because the source program of the JSP engine is very large and complex. JSP splitting avoids the analysis of the JSP engine by utilizing the characteristics of JSP. The rest of the paper is organized as follows. Section 2 explains the difficulty of splitting a JSP page into fragments. Section
19、 3 gives details of the algorithmto split a JSP page. Section 4 describes the JSP splitting tool that is an implementation of JSP splitting and demonstrates how a sample JSP page is split by the tool. Section 5 shows the experimental results obtained by executing the split JSP fragments with differe
20、nt caching periods on the IBM WebSphere Application Server. Section 6 discusses previous work in relation to our contributions. Our conclusions form the final section.2. Difficulty of Splitting a JSP PageIn this paper, splitting a JSP page means that some portions of the JSP page are cut from the JS
21、P page and saved as new JSP pages. Such newly created JSP pages are included in the original JSP page by using some mechanism such as the jsp: include tag. We call the included JSP page the JSP fragment, and call the JSP page that invokes the JSP fragments the master JSP page. A master JSP page invo
22、kes JSP fragments and receives Web page fragments obtained by executing them. Then the master JSP page merges its own Web page fragment with the Web page fragments received from the JSP fragments, and creates a final Web page. JSP fragments are not always executed in the same server or at the same t
23、ime. The application offload technology allows a master JSP page and JSP fragments to be executed in different servers. When the ESI mechanism is used, esi: include tags are put into a Web page fragment obtained by executing a master JSP page and interpreted in an edge server that supports the ESI m
24、echanism. In this case, the edge server checks whether or not the Web page fragments specified by esi:include tags exist in its cache. If the contents of Web page fragments are not cached or have expired, the JSP fragments are invoked from the edge server, and executed in one or more application ser
25、vers. If different caching periods can be given to the Web page fragments obtained by executing the JSP fragments, each JSP fragment is executed only when the cached content has expired. The Dynacache technology, the ESI mechanism, and the cache tag libraries can support different caching periods fo
26、r Web page fragments. When a JSP page is split into fragments, the following two conditions must be satisfied even if the master JSP page and the JSP fragments are not executed in the same server or at the same time. Cond. 1 - 1 The total execution result of a master JSP page and the JSP fragments i
27、s the same as the JSP page before it was split.Cond. 1 - 2 Each JSP page, which is either a master JSP page or a JSP fragment, may be executed without other JSP pages. These conditions are satisfied by maintaining the data and control dependences existing in a JSP page after the JSP page has been sp
28、lit into fragments. However, it is hard work for developers to detect data and control dependent portions in a JSP page, because the data and control flow of a JSP page can be divided among the JSP page, the JSP engine that executes the JSP page, any Java beans used in the JSP page, and etc. Thus, a
29、 natural solution calls for automatically detecting data-dependent and control-dependent portions linked to the portions that developers want to split. The program slicing technique detects a set of program statements that affect a program statement S by analyzing the data and control dependences ex
30、isting in the program. One program slice consists of the detected set of program statements and the statement S. This technique is useful when debugging or maintaining large programs. Since JSP pages are compiled into servlet programs by using a JSP compiler such as the Apache Jasper compiler 4, JSP
31、 slices can be obtained by applying program slicing technique to a servlet program compiled from a JSP page. However, the program slicing technique is not sufficient to split a JSP page into fragments, because the technique does not take into account that program slices are executed independently.Fi
32、gure 1 shows a part of a sample JSP page and a sample servlet program compiled from the JSP page. Figure 2 (a) shows the data dependence graph obtained from the servlet program. In a program, when a statement S1 assigns a value to a variable and a statement S2 following S1 uses that value, a true da
33、ta dependence exists between S1 and S2. Such a data dependence is denoted as S1 S2. In Figure 2 (a), due to the data dependences, the program slice for the statement S10 consists of S1, S9, and S10. If the program slice is cut from the servlet program, the remaining program statements have errors because the data dependences S1 S2, S11, and S12 and S9
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1