Modelling System Performance Using Fundamental Laws – Response Time Theory

Introduction: It’s quite understandable why Performance Modelling has traditionally been considered a black art. The combination of modelling techniques, the perception of lack of robustness of the forecasts provided, the nature of assumptions that one has to make, etc. are just some of the reasons why Performance Modelling is generally never considered as a feasible approach to understand system behavior. Most professionals on projects in our experience wait until they get to Integrated Performance Testing to understand the system performance and identify potential bottlenecks that would impact the ability of the system to scale.

However there’s another way to look at things and with a little bit of help we might just be able to change the way you look at the black art of Performance Modelling. Armed with a good understanding of the performance fundamentals (which you can obtain by reading through the content here at Practical Performance Analyst), a good understanding of your system architecture, a strong understanding of the various modelling techniques (based on the information provided here at Practical Performance Analyst) and access to automated modelling solution you should be on your way to “Modelling Nirvana”. Hopefully at the end of this article we have convinced you that Performance Modelling isn’t a black art any more.

Modelling Nirvana, tell me more: So what is this “Modelling Nirvana and how might you get yourself into a state of Modelling Nirvana. Here’s some simple steps involved in getting yourself into Modelling Nirvana.

  • Start reading up on the basics of Performance Engineering – SPE 101
  • Understand the basics of various Performance Modelling techniques – Modelling 101
  • Get access to the a Performance Modelling solution – VisualizeIT
  • Read up on the examples and tutorials on Performance Modelling at VisualizeIT and familiarize yourself with the modelling approaches at hand

As you have seen above Modelling Nirvana is not impossible to attain. Yes, it involves some amount of reading up (on the basics of Systems Performance Engineering) and possibly lots of cups of caffeine (to keep you awake i.e.) to make sure you are able to get through to it all. Modelling Nirvana is now within everyone’s reach, all that’s required is the will to obtain it.

Response Time Theory Fundamentals: Response Time Theory uses a set of fundamental equations to help understand system behavior and performance. The fundamentals laws of performance are used often to understand:

  • Change in reponse times
  • Change in queue length
  • Change in queuing times
  • Change in system utilization

for a given change in system configuration, workload profile (mix of users, transactions, etc.) and the change in user behavior i.e. think times, etc. To be able to use the Response Time Theory equations you would need to know two of the three variables mentioned below:

  • Uavg – Average System Utilization
  • X – System Throughput
  • St – Service Time

M is always assumed to be known since it’s the number of CPU’s (also called Servers when referring to performance models) within the system. This is a design assumption and is assumed to be a known quantity.

  • M – Number of Servers

Here’s a look at all of the equations that will be considered when modelling system performance using Response Time Theory:

  • Uavg = [ X * St ] / M ……………..  [ Uavg = Average Utilization,  X = Throughput, St = Service Time, M = Number of Servers ]
  • Rt = St / [ 1 –  Uavg * M ]………..  [ Rt = CPU Response Time, Uavg = Average Utilization,  St = Service Time, M = Number of Servers ]
  • Rt = Qt + St ………………………..  [ S(t) = Service Time, Rt = Response Time, Qt = Queuing Time ]
  • Qt = Rt – St………………………  [ Rt = CPU Response Time, Qt = Queuing Time, St = Service Time ]
  • Q = X * Qt …………………………..  [ Q = Queue Length, Qt = Queuing Time, St = Service Time ]

Analytical Modelling Solution: For purposes of this tutorial we will be using VisualizeIT.  VisualizeIT offers access to a bunch of Analytical Models, Statistical Models and Simcropped-visualize_it_logo__transparent_090415.pngulation Models. Access to all the Analytical (Mathematical) models is free. Go grab an account at VisualizeIT for FREE and get started with modelling system performance. Attaining Modelling Nirvana has never been this easy.

  • Once you’ve registered at VisualizeIT and have signed up to a Bronze (Free) plan you will have access to all of the modelling techniques at VisualizeIT.
  • On logging into the VisualizeIT dashboard click any image on the “Dashboard” to take you to the modelling section
  • The Left Hand Side menu now has a list of different modelling techniques that you could use. Response Time Theory is one of the first modelling links on the LHS menu.

Response Time Theory is based on the fundamental laws of Performance. Use Response Time theory to get a quick sense of direction with regards to where you are headed when designing a system. You should considering using Response Time Theory to obtain a quick sense check on the approach you are taking or have considered taking. Avoid using Response Time Theory to make fundamental design RT_Formdecisions. That’s where some of the more complex models come in. For purposes of this tutorial we will focus on the Response Time Theory models within VisualizeIT.

Let’s Look At An Example : Let’s go through the capability as part of the Response Time Theory models within VisualizeIT and review the results for the Response Time Theory model using the below inputs.

  • Throughput or X (TPS) = 8
  • Service Time (S) in Seconds = 0.1
  • Number of CPU’s (M) = 6

Enter the input values provided above and hit the “Execute Model” button. The resulting plots for this model provided are:

  • Utilization (%) v/s Throughput (TPS)
  • Queue Length (Q) v/s Throughput (TPS)
  • Response Time (Sec) v/s Throughput (TPS)

Along with the modelling results i.e. presented as downloadable graphs you also have access to the computed values presented in a neat table format.

Interpreting Results : The Response Time Theory models part of the modellingRTT_utilization_vs_throughput capability at VisualizeIT  make use of the fundamental equations above to compute the behavior of the system for a given set of conditions. The model also takes it a bit further and computes the behavior of the system for an assumed gradual increase in Throughput (X). These resulting values are then plot on the graphs presented to you along with all the computed values in a neat little table.

Utilization (%) v/s Throughput (TPS) – The resulting graph very clearly tells us that at 59 TPS you’ll be at 97% utilization. In any sphere of life when dealing with systems i.e. a bank with tellers as processors and customers lining up for services or  a fast food store with counters as processors and customers lining up for service, you avoid getting into the Zone of Non Linear Performance. Technically speaking the Zone of Non Linear Performance (ZNLP) is typically the entire region past 75% utilization. You’ll note from the graphs below that once a system has entered the Zone of Non Linear Performance the “Request Queues” begin to increase in size RTT_queue_length_vs_throughputand the Transaction Response times increase.

Queue Length (Q) v/s Throughput (TPS) – The resulting graph tells us that at 59TPS you are at a queue length of 5.8. As we’ve mentioned before, the Zone of Non Linear Performance (ZNLP) is typically the entire region past 75% utilization. As a system moves through the Zone of Non Linear Performance the “Request Queues” begin to increase in size and the Transaction Response times increases gradually. You can see very clearly the system performance starting to grow exponentially.

Response Time (Sec) v/s Throughput (TPS)  – The resulting graph tells us that at 59 TPS you will see a response time of ~0.2 seconds. As we’ve mentioned before, the Zone of Non Linear Performance (ZNLP) is typically the entire region past 75% utilization. As a system moves through the Zone of Non Linear Performance the “Request Queues” begin to increase in size and the Transaction Response times increases gradually. When a system enters the Zone Of Non Linear Performance (ZNLP) the requests are arriving at a rate faster than the systemsRTT_response_time_vs_throughput ability to service them as a result we start noticing an increase in response times. It’s also worth noting that when a system has high utilization levels and is within the ZNLP the service times haven’t really changed. It’s the exponential increase in Queue Time (Qt) or Waiting Time (Wt) which is responsible for the exponential increase in overall Response Times.

Focus On Fundamentals: For those folks who want to learn more about the basics of SPE (Systems Performance Engineering) including strengthening your understanding of the fundamental of performance modelling please visit the SPE Fundamentals section here at Practical Performance Analyst.

Analytical Modelling Solution: For purposes of this tutorial we will be using VisualizeIT.  VisualizeIT offers access to a bunch of Analytical Models, Statistical Models and Simcropped-visualize_it_logo__transparent_090415.pngulation Models. Access to all the Analytical (Mathematical) models is free. Go grab an account at VisualizeIT for FREE and get started with modelling system performance. Attaining Modelling Nirvana has never been this easy.

Conclusion : On any system you want to avoid getting into the Zone Of Non Linear Performance (ZNLP) i.e. > 75% Utilization. This applies not just to IT (Information Technology) systems but generally systems across the board i.e. a bank with tellers as processors and customers lining up for services or  a fast food store with counters as processors and customers lining up for service. Use Response Time Theory to obtain a sense of direction, to understand what impacts your design decisions will have. With access to simple models like Response Time Theory you have now the capability to visualize system (application, storage, infrastructure, network, etc.) performance before your system actually gets into an integrated performance testing environment.

 

Related Posts

  • Modelling System Performance Using Fundamental Laws – Littles LawModelling System Performance Using Fundamental Laws – Littles Law In the first article of this series we reviewed some of the most basic Performance Modelling techniques using fundamental performance equations. The first part of this series covered a Performance Modelling technique we call "Response Time Theory" and leveraged easy to use performance […]
  • System Resources, Infrastructure Capacity and Moore’s Law – Part IIISystem Resources, Infrastructure Capacity and Moore’s Law – Part III About This Series - This series of articles is a how-to manual on applying performance modelling techniques without any needless discussion of internals or mathematics (with the exception of the necessary but simple Little’s formula which will be included in this article which happens […]
  • Do Applications Have Performance DNA ? – Part IDo Applications Have Performance DNA ? – Part I About This Series - This series of articles is a how-to manual on applying performance modelling techniques without any needless discussion of internals or mathematics (with the exception of the necessary but simple Little’s formula which will be included in the 2nd installment of this […]
  • Applications Have A Usage Volume – Part IIApplications Have A Usage Volume – Part II About This Series - This series of articles is a how-to manual on applying performance modelling techniques without any needless discussion of internals or mathematics (with the exception of the necessary but simple Little’s formula which will be included in this article which happens to […]