Upload
aras-tarhan
View
224
Download
0
Embed Size (px)
Citation preview
8/3/2019 Homework Lab9 Aras Umit
1/17
Fall 2011Homework Lab 9Faik Aras TarhanUmit Cavus Buyuksahin
8/3/2019 Homework Lab9 Aras Umit
2/17
OVERVIEW
To characterize Multi-tier enterprise software systems, it
is important to:
understand the peak capabilities of the system
locate and quantify performance bottlenecks (such asCPU/disk/network)
ensure the validity of the measured data
These goals can be achieved by a systematic
methodology which provides a basis for performance
comparison of different e-business middleware
8/3/2019 Homework Lab9 Aras Umit
3/17
Which Approach and Why ?
Two approaches for systematic methodology
Stochastic Analysis
Queuing Operational Analysis
Second one was chosen by the paper since;
simple to measure for an N-tier system
allows to make use of operational laws, which have been
well understood for more than 30 years
application of these fundamental equations can provide
sanity- checks
8/3/2019 Homework Lab9 Aras Umit
4/17
Queuing Model of a 3-Tier
System
consists of
a web server ( a script (e.g. ASP or JSP) or Java Servlet runs )
an application server (a business object (e.g. COM+, EJB))and a database server ( SQL,Oracle etc. )
also a client to generate the workload (e.g. HTTP request)
8/3/2019 Homework Lab9 Aras Umit
5/17
Key Metrics and Basic
EquationsMetrics:
the throughput in requests per second (X), a measure of
work done by the system in terms of completed request
the response time in seconds (R), the average latency of arequest
the number of concurrent requests in the system (N)
Equations:
Utilization law: Ui = X * Di
Littles Law:N = X * R
8/3/2019 Homework Lab9 Aras Umit
6/17
Experiment Tools and Setup
A stress test tool, called Web Application Stress tool(WAS), from Microsoft is used.
composes the number of concurrent threads that willmake requests
runs the script for some amount of time
measures:
performance data (e.g. CPU utilization, disk utilization )
throughput for the test (X)
(TTLB) response time for the test( If TTLB is big enough, client delay can be so negligible thatRand TTLB are considered as equal )
8/3/2019 Homework Lab9 Aras Umit
7/17
General Calculation
ProcedureService demands for CPU, Disk, Network by the
Utilization Law
The average of the measured service demands for eachresource is calculated
The service demand values were inspected to find and
evaluate the performance bottlenecks
Littles Law is used to help sanity-check
8/3/2019 Homework Lab9 Aras Umit
8/17
Experiment on Servlet A
Cpu is the
bottleneck
The service
demand is ~24 ms
Derived X matches
closely the
measured
throughput from
WAS
8/3/2019 Homework Lab9 Aras Umit
9/17
Experiment on
Servlet AThe measurement is valid, as
verified by the equations.
The equations are applicable toreal world setups.
We have a way of comparing
workloads in terms of resource
usage.
8/3/2019 Homework Lab9 Aras Umit
10/17
Experiment on Servlet BThe deviation of the two curvesindicates that there is indeed a
problem with the measurement
Running a large number of
threads on such a system meansthat the client system CPUs are
spending too much time in
context switching between
threads, rather than generatingrequests to the server
it is worthwhile to use Littles Law to validate measurements
8/3/2019 Homework Lab9 Aras Umit
11/17
IIS Web Server Experiment (
with 20 KB HTML File)
the 100Mb/s network is the bottleneck resource
Xmax= 1/1.54 = 647 req/sec which is within 5% of
the measured peak throughput
8/3/2019 Homework Lab9 Aras Umit
12/17
IIS Web Server Experiment (
with 500 B HTML File)
the CPU is the bottleneck
Even with three clients, CPU does not load up to 90%
Xmax= 1/Dmax while Dmax= 0.21ms Xmax= 4821req/sec
The measured peak throughput is 4289 req/sec which is a
discrepancy of about 11%
8/3/2019 Homework Lab9 Aras Umit
13/17
Conclusion on IIS Web Server
ExperimentIn second experiment the stress clients were unable tosaturate the web server
Adding more client machines would reduce or eliminate
this discrepancy or
a larger file size would allow us to saturate the server,without adding more client systems
To sum up;
if we get a wider discrepancy between measurements andcalculated or expected data, we definitely need to dig deeperinto the causes for the discrepancy
8/3/2019 Homework Lab9 Aras Umit
14/17
3-tier System Middleware
Comparisonare commonly used to separate business logic from thepresentation layer at the front end, and enterprise dataaccess at the back end
the CPU was the performance bottleneck for this test, thedata for the disk and network is not shown.
Observe in the next slide that the overall throughput X is alot higher for Middleware II compared to Middleware I (352req/sec vs. 100 req/sec)
It could be concluded that Middleware II is 3.5 times fasterthan Middleware I unless we dig deeper as concluded in theprevious slide
8/3/2019 Homework Lab9 Aras Umit
15/17
3-tier System Middleware
Comparison
8/3/2019 Homework Lab9 Aras Umit
16/17
3-tier System Middleware
Comparison ConclusionThe max throughput for Middleware is given by: Xmax
= 1/Dmax= 1/9.6 = 104 req/sec so the measurements
seem valid within a reasonable margin of error
the service demand for the application server is nearly
the same for both Middleware I and Middleware II
both technologies are actually equivalent in their
business logic performance!
Middleware II has the advantage is in the performance
of the web server compared to Middleware I
8/3/2019 Homework Lab9 Aras Umit
17/17
Discussion
Measurements must be validated against expectations byusing Littles Law
If the measured and calculated values diverge significantly,further analysis is required
The client delay which is also called think time for a 3-tiersystem affects the slope of the throughput curve
As the delay is increased, the throughput curve shifts to theright
The maximum throughput of the system is still the same:Xmax= 1 / Dmax