计算机外文翻译.docx
《计算机外文翻译.docx》由会员分享,可在线阅读,更多相关《计算机外文翻译.docx(11页珍藏版)》请在淘文阁 - 分享文档赚钱的网站上搜索。
1、_毕 业 设 计(论 文) 英 文 翻 译课题名称 系 部专 业班 级学 号姓 名指导教师2017 年 4 月 14 日_Performance Comparison of PHP and JSP as Server-Side Scripting LanguagesMaterialSource: Notesin Computer Science Author: Scott Trent; Michiaki Tatsubori; Toyotaro Suzumura; Akihiko Tozawa and Tamiya Onodera1 IntroductionThe dynamic scripti
2、ng language PHP(PHP Hypertext Preprocessor) has become enormously popular for implementing lightweight web applications,and is widely used to access databases and other middleware.Apache module popularity surveys performed by Security Space in October 2007 indicate that 37% of Apache servers have PH
3、P support enabled ,making it the most popular Apache module by 10 percentage points.Businesses are quickly realizing the powerful combination of a service oriented architecture environment with dynamic scripting languages like PHP .However,we believe that there are still critical performance issues
4、involving PHP which remain to be investigated.This paper focuses on the use of dynamic scripting languages to implement web server front-end interfaces. This corresponds with the way that the industry standard web server performance benchmark SPECweb2005 utilizes PHP and JSP ( JavaServer Pages).In t
5、his case, scripts are used for the implementation of dynamic page generation, rather than the realization of complex business logic. This contrasts with the traditional uses of complex JSP-based business logic implementation.While there are numerous studies on dynamic web content, this paper complem
6、ents these studies with detailed analysis focusing on PHP. For example, following the performance study on CGI (Common Gateway Interface) based web servers for dynamic content by Yeager & McGrath back in 1995, researchers and practitioners have been examining the performance of more recent dynamic W
7、ebcontent generation technologies. These works, however, handle application scenarios where servlet front-ends implement relatively complex business logic. Although Warner and Worley discuss the importance of also using PHP with SPECweb2005, to the best of the authors knowledge, this paper is the fi
8、rst to publish a detailed analysis of SPECweb2005 experimental results using both PHP and JSP. The detailed analysis of PHP and JSP performance based on SPECweb2005 offered by this paper enables designers and implementers of web servers to understand the relative performance and through put of diffe
9、rent versions and configurations of PHP and JSP.2 Multi-tier Web Server Architecture: Lightweight Front-End Using PHP/JSP Developers typically use PHP to implement a front-end interface to dynamic Web content generators, which are combined with web server software and back-end servers to provide dyn
10、amic content. The web server directly handles requests for static content and forwards requests for dynamic content to the dynamic content generator. The dynamic content generator, supported by back-end servers, executes code which realizes the business logic of a web site and stores dynamic state.
11、Back-end servers may be implemented as a straight-forward database, or may be more complex servers handling the business logic of the web site. The front-end implementation may vary from heavy-weight business logic handlers to lightweight clients composing content received from back-end servers. Thi
12、s paper focuses on multi-tier web site development scenarios utilizing such lightweight front-ends, supported by one or more layers of heavy-weight back-ends. This assumption is reasonable when considering Service-Oriented environments where PHP scripts are used to implement a mash-up of services pr
13、ovided elsewhere, in addition to the case of simple web sites such as bulletin boards where PHP scripts are just a wrapper to a database. Within the scenarios described in this paper, the dynamic content generator provides client implementation in addition to page composition. It connects to the bac
14、k-end server through a network using either standard protocols such as HTTP or application/middleware-specific protocols.JSP technology can be considered an alternative to PHP in implementing such front-ends. While it is part of the Java Servlet framework, developers typically use JSP to implement l
15、ightweight front-ends. Both PHP and JSP allow developers to write HTML embedded code. In fact, although there are language inherent differences between PHP and Java, the use of PHP scripts and JSP files can be very similar. The objective of the experiments detailed in this paper is to measure the pe
16、rformance of lightweight front-end dynamic content generation written in PHP and JSP with popular web servers such as Apache and Lighttpd. This web server architecture scenario involves users who access a web server with pages written in plain static HTML, as well as JSP and PHP scripts which mix sc
17、ripting language with HTML code. The configuration assumed within the paper is a typical one, where web server software, such as Apache, distinguishes between pure HTML, JSP, and PHP respectively with suffixes such as .html, .jsp, and .php. HTML code is directly returned to the requesting end-users
18、web browser, where JSP and PHP pages are respectively parsed by the Tomcat script engine and the PHP runtime engine which both provide pure HTML which is forwarded to the end-user on a remote system. A common point between JSP and PHP is that implementations which perform well have a dynamically com
19、piled and cached byte code. For example, the Java runtime used by the Tomcat script engine which we used performs much better when the Just-in-Time (JIT) compiler is enabled to create efficient cached native runtime code. Similarly, the Zend PHP runtime we used also performs significantly better whe
20、n the Alternative PHP Cache (APC) is enabled, in which APC stores PHP byte codes compiled from the script source code in shared memory for future reuse.3 Language Runtime Performance Micro BenchmarkingTo understand the difference in performance characteristics between PHP and Java at the language ru
21、ntime level,we compared the following engines using a series of micro benchmark tests:- PHP 4.4.7 - PHP 5.2.3 - Java 5 with Just-In-Time (JIT) compilation (IBM J9 VM 1.5.0 Build 2.3) - Java 5 without Just-In-Time (JIT) compilation (same as above)The PHP language framework allows developers to extend
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 计算机 外文 翻译
限制150内