Method R is a commonsense method for optimizing a system. It is the straightforward process of answering the four natural questions about performance: How long? Why? What if? and What else?

To answer these questions, Method R prescribes four steps:

  1. Identify the experience that’s the most important to you.
  2. Measure its response time (that’s the ‘R’ in “Method R”). In detail.
  3. Optimize that response time in the most economically efficient way.
  4. Repeat until your system is economically optimal.

The Method R Guide to Mastering Oracle Trace Data, 3rd EditionOptimizing Oracle Performance Method R was first documented in the book Optimizing Oracle Performance, for which Cary Millsap and Jeff Holt were named Oracle Magazine 2004 Authors of the Year. An updated and more detailed version is available in Cary Millsap’s The Method R Guide to Mastering Oracle Trace Data, 3rd Edition.

Method R has been used with tremendous success at Oracle sites since the mid-1990s. Although Method R was first documented in an Oracle context, its usefulness extends far beyond Oracle. In fact, the definition of Method R does not refer specifically to Oracle, databases, or even computers.

The four “magic” questions about performance of course aren’t really magic. They’re actually just four simple questions you naturally ask when something takes too long.
  1. The first question is How long? How long does it take? This is the first question you need answered about the performance of anything.
  2. Next is Why? Why does it take that long? What does it spend its time doing?
  3. And next, What if? What would happen if you changed something? What would be the cost? The benefit? The risk? This is where you create and innovate, but you want to be guided with feedback here, with data.
  4. Finally, What else? This is the loop that takes you back to the first question: How long does it take now?
On the first pass through the four questions, you eliminate the waste you see. On the second pass, the waste that before was overshadowed by bigger problems is now prominent. After another pass or two, there’s no more wasted time left to eliminate, and your job is done. These four questions about performance are how we tune our everyday lives. The questions aren’t magic; you’ve just stopped asking them at work because your tools don’t help you answer them. “If I give you the budget for that upgrade you want, then how many hours will you be able to trim off that fourteen-hour report?” It’s the obvious question. But can you answer it by looking at an AWR report? Would you stake your career on it? Of course not. That’s why a debate breaks out every time there’s a conversation about performance. The four “magic” questions. They’re how you make things go faster. And with Method R, they’re how you make Oracle go faster, too.
The compelling value proposition of Method R is simple: there are no surprises. Method R eliminates surprises because:
  • You measure exactly what you care about. If you measure your interesting task properly, there’s no way that a performance problem can hide from you. If your task is perfectly efficient, you'll be able to see that, too. You’ll never again waste time trying to tune something that can’t help you.
  • You can know in advance how much a proposed performance improvement is going to help you. You won’t have to waste time and money on trial and error. You’ll be able to make fully informed investment decisions about performance.

One of the biggest problems with Oracle Database tuning is that non-technical people (and even a lot of technical ones as well) can’t understand it. Although we invented Method R in an Oracle context, it’s easy to explain our method in everyday terms, because Method R is probably already the method you use to tune everyday things.

Imagine that your performance problem is this: every time you send your son on a shopping errand, it takes him an hour, and it’s really bothering you that it takes him this long. How can you optimize the process?

method-r-pieYou’ve already executed step 1 of Method R by identifying the task that’s important to you: shopping for groceries. Step 2 says to measure that hour in detail. The best way to do that is by creating a profile, which is a spanning, non-overlapping account of your time. Think of a pie chart that explains where all your time has gone.

The pie chart is a good guide, but you can do more with the numbers behind the chart. Imagine that your profile looks like this:

Talk with friends3762%3
Choose item1017%5
Walk to/from store813%2
Pay cashier58%1

Now you can see exactly where your time has gone, and exactly how much time you can save. From this profile, it’s easy to begin imagining solutions, which is step 3. For example, you could reduce the shopping time by 62% (from 60 to 23 minutes) if your boy didn’t stop to chat. The profile also tells you what not to do: buying that car he wants is going to save only some fraction of 8 minutes; a car is certainly not where your performance leverage is here.

Step 4 says to stop your analysis when the cost of further optimization exceeds the benefit. It pays to be clever: the smartest optimizations are the ones that produce tremendous benefit at low cost.

We use the same general procedure to optimize computer software performance. The real tricks are learning how to create the profile, and then learning how to attack the problems that your profile reveals. That’s where our software, education, and consulting services enter the picture.

Lots of companies, large and small, including companies in the Fortune 100, use Method R software.
  • Oracle application developers use Method R software to find and fix bugs in their code, and to measure and optimize their code while they’re writing or repairing it.
  • Oracle DBAs use Method R software to prevent performance problems by measuring application performance on test systems, and to monitor and troubleshoot user performance experiences on production systems.
  • Non-technical users, managers, and consultants use Method R software to connect detailed Oracle performance data with the end users’ performance experiences that affect the business.

Oracle’s and Method R’s performance tools are not mutually exclusive. Just about every Method R customer in the world uses ASH (Active Session History), AWR (Automatic Workload Repository), and OEM (Oracle Enterprise Manager), too.

People use Method R software in conjunction with these other tools because Method R provides important additional value. Two examples:

  • ASH, AWR, and OEM are tools designed for DBAs, not application developers. Developers don’t usually even have access to them. So, while ASH, AWR, and OEM help experienced specialists study production systems, they don’t help your developers create scalable, high-performance systems.
  • OEM and the dozens of third-party tools that are based on ASH and AWR are tricky to use, even for DBAs. They don’t show code path, and they don’t help you answer, even approximately, the four fundamental questions about performance: how long? why? what if? and what else? Experienced Oracle specialists spend a lot of time trying to make sense out of Oracle’s complex performance diagnostic data.

Method R software saves you time by doing that hard work for you. We make it easy for developers and DBAs of all experience levels to learn exactly why your software consumes the time it does.

Toad and the tools offered by Method R are not mutually exclusive. Many Method R customers are also Toad users. Method R is a way of thinking about the process of optimizing. That process involves measuring the response time (the ‘R’ in “Method R”) of individual experiences that users have with your system. Toad doesn’t provide that capability. Unfortunately, Toad doesn’t offer a framework for third-party extensions like Oracle SQL Developer does. We would love to have a Method R Trace extension for Toad, but their architecture just doesn’t permit it.

Sometimes, people with slow systems say that step 1 of Method R is difficult because every task is important, and every task is slow. Method R was designed in exactly these situations. Even when everything is slow, you see, something is the business’s most important thing to fix first.

Often, fixing one task collaterally fixes others as well. Regardless of whether you’re lucky enough for that to happen, Method R is designed so that the most important tasks get fixed first.

The Method R Guide to Mastering Oracle Trace Data, 3rd EditionAn experience doesn’t have to be broken to be important. Companies that routinely measure the performance of their important user experiences in the Method R way have a much better chance of preventing performance problems so that their users will never even see them.

For a lot more information, see part 3 in The Method R Guide to Mastering Oracle Trace Data, 3rd edition.

The ‘R’ in the name “Method R” stands for response time. Cary Millsap chose the name for the book Optimizing Oracle Performance to distinguish the new method from the conventional trial-and-error approach to tuning, which he called “Method C” (‘C’ for conventional).
The diamond in the Method R Corporation logo is the kind of diamond that you see in flowcharts. It represents the key distinction of the method itself: that there is a deterministic decision-making process that leads you—and everyone else, regardless of their experience level—from a single starting point to exactly the aspect of performance in your system that you should be focused on next. Method R is the antithesis of trial-and-error tuning, and we chose the diamond for our logo to help remind people of that.