Performance Evaluation of J2EE(2)

Similar documents
Performance evaluation of J2EE

Developing Applications with Java EE 6 on WebLogic Server 12c

Java Training Center, Noida - Java Expert Program

Java EE 6: Develop Web Applications with JSF

Learn Well Technocraft

Introduction to Web Application Development Using JEE, Frameworks, Web Services and AJAX

SUN Sun Certified Enterprise Architect for J2EE 5. Download Full Version :

THIS IS ONLY SAMPLE RESUME - DO NOT COPY AND PASTE INTO YOUR RESUME. WE ARE NOT RESPONSIBLE Name: xxxxxx

This course is intended for Java programmers who wish to write programs using many of the advanced Java features.

Oracle - Developing Applications for the Java EE 7 Platform Ed 1 (Training On Demand)

Oracle Fusion Middleware 11g: Build Applications with ADF I

Oracle Fusion Middleware 11g: Build Applications with ADF I

Oracle Application Development Framework Overview

Shale and the Java Persistence Architecture. Craig McClanahan Gary Van Matre. ApacheCon US 2006 Austin, TX

A Quick Introduction to Struts

Enterprise Software Architecture & Design

20486-Developing ASP.NET MVC 4 Web Applications

Migrating traditional Java EE applications to mobile

Web Application Development Using Spring, Hibernate and JPA

Introduction to JSP and Servlets Training 5-days

Enterprise Web based Software Architecture & Design

TABLE OF CONTENTS CHAPTER TITLE PAGE

"Web Age Speaks!" Webinar Series

Web Applilicati tion S i ecur t ity SIRT Se u c i r ty ity T a r i aining April 9th, 2009

COURSE DETAILS: CORE AND ADVANCE JAVA Core Java

Java EE 5 Development for WebSphere Application Server V7

Cloud Computing Platform as a Service

Full Stack Java Developer Course

Developing ASP.NET MVC 4 Web Applications

Type of Classes Nested Classes Inner Classes Local and Anonymous Inner Classes

open source community experience distilled

Component-Based Software Engineering. ECE493-Topic 5 Winter Lecture 26 Java Enterprise (Part D)

Open Source Library Developer & IT Pro

WSO2 Platform Offerings for Developers

Oracle Developer Day

Eclipse Java Ejb 3.0 Tutorial For Beginners With Examples Pdf

Courses For Event Java Advanced Summer Training 2018

Hackveda Appsec Labs Java Programming Course and Internship Program Description:

JSF: Introduction, Installation, and Setup

Java EE Application Assembly & Deployment Packaging Applications, Java EE modules. Model View Controller (MVC)2 Architecture & Packaging EJB Module

Module 3 Web Component

2310C VB - Developing Web Applications Using Microsoft Visual Studio 2008 Course Number: 2310C Course Length: 5 Days

Contents at a Glance

Not just an App. Server

Schema Management In Hibernate Interview. Questions >>>CLICK HERE<<<

Contents. 1. JSF overview. 2. JSF example

Web Application Development Using Spring, Hibernate and JPA

1Z Oracle. Java Enterprise Edition 5 Enterprise Architect Certified Master

Introduction. This course Software Architecture with Java will discuss the following topics:

JAVA SYLLABUS FOR 6 MONTHS

Developing ASP.Net MVC 4 Web Application

Java- EE Web Application Development with Enterprise JavaBeans and Web Services

SSC - Web applications and development Introduction and Java Servlet (I)

Webservices In Java Tutorial For Beginners Using Netbeans Pdf

Improve and Expand JavaServer Faces Technology with JBoss Seam

10267A CS: Developing Web Applications Using Microsoft Visual Studio 2010

COURSE 20486B: DEVELOPING ASP.NET MVC 4 WEB APPLICATIONS

20486: Developing ASP.NET MVC 4 Web Applications

20486: Developing ASP.NET MVC 4 Web Applications (5 Days)

Software Design Document

Research and Application of Mobile Geographic Information Service Technology Based on JSP Chengtong GUO1, a, Yan YAO1,b

Java SE7 Fundamentals

LTBP INDUSTRIAL TRAINING INSTITUTE

Deccansoft Software Services. J2EE Syllabus

Web Application Development Using Spring, Hibernate and JPA

Etanova Enterprise Solutions

Lesson 12: JavaScript and AJAX

Specialized - Mastering JEE 7 Web Application Development

Full Stack Developer (FSD) JAVA

Development of web applications using Google Technology

ive JAVA EE C u r r i c u l u m

Author: Chen, Nan Date: Feb 18, 2010

IBM Rational Application Developer for WebSphere Software, Version 7.0

(p t y) lt d. 1995/04149/07. Course List 2018

Review. Fundamentals of Website Development. Web Extensions Server side & Where is your JOB? The Department of Computer Science 11/30/2015

Course 20486B: Developing ASP.NET MVC 4 Web Applications

Developing ASP.NET MVC 4 Web Applications

Java SE 8 Fundamentals

JVA-563. Developing RESTful Services in Java

Introduction to Web Development with Microsoft Visual Studio 2010

Developing ASP.NET MVC 5 Web Applications

Course Outline: Course 10267A: Introduction to Web Development with Microsoft Visual Studio 2010 Learning Method: Instructor-led Classroom Learning

J2EE Development. Course Detail: Audience. Duration. Course Abstract. Course Objectives. Course Topics. Class Format.

ECLIPSE TUTORIAL HOW TO WRITE JAVA PROGRAM IN ECLIPSE STEP BY STEP ECLIPSE TUTORIAL FOR BEGINNERS JAVA

Fast Track to Java EE

Developing ASP.NET MVC 5 Web Applications

Developing ASP.NET MVC 5 Web Applications. Course Outline

ASP.NET MVC Training

Outline. Project Goal. Overview of J2EE. J2EE Architecture. J2EE Container. San H. Aung 26 September, 2003

"Charting the Course... MOC A Introduction to Web Development with Microsoft Visual Studio Course Summary

Rich Internet Application with TIBCO General Interface By Nitin Goswami

com Spring + Spring-MVC + Spring-Boot + Design Pattern + XML + JMS Hibernate + Struts + Web Services = 8000/-

JAVA COURSES. Empowering Innovation. DN InfoTech Pvt. Ltd. H-151, Sector 63, Noida, UP

JAVA SYLLABUS FOR 6 WEEKS

Week 2 Unit 3: Creating a JDBC Application. January, 2015

ASP.NET Using C# (VS2017)

Java Advance Frameworks

Session 8. Introduction to Servlets. Semester Project

JPA and CDI JPA and EJB

JavaServer Faces Programming By Budi Kurniawan READ ONLINE

Transcription:

ECE750 Topic 11 Component-Based Software Systems Instructor: Ladan Tahvildari Performance Evaluation of J2EE(2) Presented by: Henry Xu (20198718) Huahao Zhang (20256751) July 26, 2007

Outline Introduction Problems, motivations and approach Environment, methods and architecture Performance evaluation Web performance evaluation Java performance evaluation Summary Achieved results Contributions 2

Problems and Motivations Problems Does J2EE5 improve application performance? What are the performance bottlenecks in J2EE5? Motivations Performance evaluation Try to find out bottlenecks 3

Our Approach 1. Setup J2EE5 and deploy PetStore2.0 2. Analyze the MVC and other patterns 3. Study the new Web2.0 techniques Step 2 & 3 have been done by tracing the source code manually 4. Set up load testing environment 5. Create test script and run load test 6. Evaluate the performance and find out the bottlenecks in J2EE5 Step 5 & 6 have been done by using the LoadRunner and Java Profiler 4

Testing Environments Hardware CPU Memory Hard Drive Network Client Centrino II 1.4G 1G 40G, 5400RPM 100M LAN Server AMD Athlon 64 3200+ 2G 250G, 7200RPM 100M LAN Software OS Testing tools Client WIN XP + SP2 LoadRunner 8.1 Server WIN XP + SP2 NetBeans Java Profiler 5.5 SUN J2EE App Server 9.0 NetBeans 5.5 IDE+JDK 1.6 5

Testing Methods Client Black box testing Testers know nothing about source code Focusing on web performance Server White box testing Tester know the source code well Focusing on Java class and method level performance J2EE performance evaluation Based on both web performance and Java performance 6

Testing Architecture (Ctrl. Flow) 7

Testing Architecture (Data Flow) Client Side Server Side Tester Input Virtual User Generator Greate scripts LoadRunner Controller Web performance results LoadRunner Analyser Output Generate HTTP requests and receive HTTP responses PetStore 2.0 SUN App Server NetBean IDE 5.5 Java Performance Results Netbean Profiler 5.5 Output Attach Web Performance Reports Java Performance Reports 8

Web Performance Comparison Compare the performance of Ajax web pages to non-ajax web pages Create a new JSP file that implements the same autocomplete feature using synchronous (non-ajax) architecture: Copy the FileUpload.jsp to FileUpload_noajax.jsp and then add the following code to FileUpload_noajax.jsp <%@page import="com.sun.javaee.blueprints.petstore.controller.*"%> <% //Call the methods directly to simulate synchronous calls AutocompleteBean clsautocompletebean = new AutocompleteBean(); //Search cities from Java database where the first character is w String decodedstr = clsautocompletebean.initcities("w", 10); out.println( Debug: decodedstr="+ decodedstr); %> 9

Web Performance Comp. (Packet Size) Non-Ajax (first time): web_url("fileupload_noajax.jsp"), 14,146 header bytes, 647,602 body bytes, Non-Ajax (caching): web_url("fileupload_noajax.jsp") 3,138 header bytes, 220,853 body bytes, Ajax: web_url("fileupload.jsp"), 324 header bytes, 340 body bytes, 16000 14000 12000 10000 8000 6000 4000 2000 Non- Aj ax Non- Aj ax with caching Aj ax 700000 600000 500000 400000 300000 200000 100000 Non- Aj ax Non- Aj ax with caching Aj ax 0 Ht t p Response header si ze 0 Http Response body si ze 10

Web Performance Comp. (Http Response) Scale Measurement Min Ave Max Non Ajax 1 HTTP_200 20.5 38.6 50.3 Ajax 1 HTTP_200 24 45.4 54.5 Reasons Very difficult to fully convert the Ajax applications to non-ajax version The autocomplete feature is IO-bound 46 44 42 40 38 36 Non Aj ax Aj ax 34 Ht t p r esponses per second 11

Java Profiling Results The results include the percentage of CPU execution time, execution time and the number of invocations of each method Call Tree: showing the top-down method call chain 12

Hot Spots What are hot spots? The methods that consume the most of CPU time. TOP 5 hot spots The first 5 methods in the hot spots list which consume around 60% of CPU execution time in our load test 13

Top1 Hot Spot Analysis Top 1 hot spot Track back previous callers in the call tree. The first caller is CatalogFacade:GetTagsInChunk() 14

Top1 Hot Spot Analysis (Cont.) Source Code public List<Tag> gettagsinchunk(int start, int chunksize) { 1. EntityManager em = emf.createentitymanager(); 2. Query query = em.createquery("select t FROM Tag t ORDER BY t.refcount DESC, t.tag"); 3. List<Tag> tags = query.setfirstresult(start).setmaxresults(chunksize).getresultlist(); 4. em.close(); 5. return tags; } Reason analysis 1. The purpose of this function is to select all tag records from Java database. 2. Database operation ( SQL execution + network communication) 3. Since the EntityManager class belongs to the JPA component, we believe the bottleneck is caused by the lack of support for caching in the JPA component Solutions 1. Cache the tag records after they have been selected from the Java database 2. By our estimation, performance is expected to be improved by 25% 15

Top2-Top5 Hot Spots Analysis Top2 to Top5 hot spots are located under the same call tree The first caller is EntityFilter::doFitler() 16

Top2-Top5 Hot Spots Analysis (Cont.) Source code public void dofilter(servletrequest request, ServletResponse response, FilterChain chain) { chain.dofilter(request, response); //This line is the bottle neck } Reason analysis 1. com.sun.javaee.blueprints.petstore.controller.entryfilter.dofilter() is provided by the J2EE5 framework based on the apache core library( org.apache.catalina.core.applicationfilterchain ) 2. The Controller in the M-V-C model Suggestion 1. Use other MVC frameworks (Spring, Struts) instead of the one provided by SUN and Apache 17

Conclusions Performance evaluation of J2EE 5 Performance is acceptable but not very impressive Provides re-usable components that simplify the development of web applications JPA( Java Persistence API) Advantage Simplifies the development of database interfaces Disadvantage The bottleneck(40% execution time) in the system due to lack of support for data caching Solution Caching JSF (Java Server Faces) and AJAX (Asynchronous JavaScript and XML) Advantage Simplify the development of Ajax-Enabled components. Reduce network traffic significantly (depends on web page size) Improve performance by 20% in our testing Disadvantage Project length is extended Suggestion Evaluate the application type before we make the decision. If the application is IO-bound, Ajax should be used. If it is CPU-bound, Ajax won t offer much performance benefit 18

Contributions Our report will be useful for the following people 1. Java programmers who are interested in developing and deploying Java EE 5 applications on the Sun Application Server 9. 2. Web developers who want to quickly develop and deploy Ajax-enabled JSF applications 3. Architects who evaluate different types of frameworks before deciding which framework to be used in their systems 19

Q&A Thank you! 20