This article explains how Leapwork Performance calculates the Virtual User Hours estimate for a timeline.
What Virtual User Hours means
Virtual User Hours measures total usage over time, not only the highest number of concurrent users at a single moment.
1 Virtual User Hour = 1 virtual user running for 1 hour
How the timeline estimate is calculated
Leapwork Performance calculates the timeline estimate by adding together the usage from each sequence block in the timeline.
Review update: Before usage is calculated, each load point is rounded up to the next billing increment of 50 virtual users.
For example:
|
Configured load point |
Billed load point |
|---|---|
|
0 |
50 |
|
1-50 |
50 |
|
51-100 |
100 |
|
101-150 |
150 |
For each load segment in a sequence block, Leapwork Performance:
-
Determines how long the segment runs, in hours.
-
Rounds the start and end load points up to the next billing increment of 50 virtual users.
-
Determines the average billed load for that segment.
-
Multiplies the average billed load by the segment duration.
Segment Virtual User Hours = average billed virtual users x duration in hours
Leapwork Performance then adds all segment values across the timeline.
Total timeline Virtual User Hours = sum of all segment Virtual User Hours values
For reference:
-
30 minutes =
0.5hours -
15 minutes =
0.25hours
How Leapwork Performance handles different load shapes
Constant load
If the load stays flat, Leapwork Performance uses the billed load for the full segment.
Virtual User Hours = billed virtual users x hours
Review update: Example revised for 50-user billing increments.
-
120 virtual users for 30 minutes
-
Billed load =
150 -
150 x 0.5 = 75 Virtual User Hours
Ramp up or ramp down
If the load changes between two points, Leapwork Performance uses the average of the billed start and end loads for that segment.
Segment Virtual User Hours = ((billed start load + billed end load) / 2) x duration in hours
Review update: Example revised for 50-user billing increments.
-
Ramp from 0 to 200 virtual users over 30 minutes
-
Billed load points =
50and200 -
Average billed load =
(50 + 200) / 2 = 125 -
125 x 0.5 = 62.5 Virtual User Hours
Review update: Example revised for 50-user billing increments.
-
Ramp from 80 to 120 virtual users over 30 minutes
-
Billed load points =
100and150 -
Average billed load =
(100 + 150) / 2 = 125 -
125 x 0.5 = 62.5 Virtual User Hours
Multiple tracks
Virtual User Hours is additive across tracks. Leapwork Performance calculates each sequence block separately and then adds the results together.
Review update: Example revised for 50-user billing increments.
-
Track 1: 80 virtual users for 30 minutes = billed as
100 x 0.5 = 50 Virtual User Hours -
Track 2: 25 virtual users for 60 minutes = billed as
50 x 1 = 50 Virtual User Hours -
Total timeline estimate =
100 Virtual User Hours
It does not matter whether the tracks overlap in time or start at different points in the timeline. If they run, their usage contributes to the total.
What changes the estimate
The estimate changes when you change:
-
the number of virtual users
-
the duration of a segment
-
the shape of the load curve
-
the number of sequence blocks in the timeline
Review update: The estimate can also change when a load point crosses a 50-user billing threshold, for example from 50 to 51, or from 100 to 101.
Moving a sequence block later in the timeline does not change that block's usage by itself. It only changes when the load happens.
The estimate does not depend on:
-
the selected execution region
-
the peak load alone, without considering duration
Virtual User Hours vs peak virtual users
These metrics describe different things:
|
Metric |
What it tells you |
|---|---|
|
Virtual User Hours |
Total usage over the full run, using 50-user billing increments |
|
Peak virtual users |
Highest combined concurrent configured load at any point in the run |
|
Planned runtime |
How long the full timeline is expected to run |
For a duration-based timeline, planned runtime is determined by the latest ending sequence block in the timeline.
Two timelines can have the same Virtual User Hours and very different shapes.
Example:
-
50 virtual users for 1 hour =
50 Virtual User Hours -
100 virtual users for 30 minutes =
50 Virtual User Hours
Both consume the same total usage, but the second has a higher peak load.
Estimate vs actual usage
Before you start a run, Leapwork Performance shows an estimate based on the full timeline design.
Review update: The estimate uses the same 50-user billing increments described above.
Actual usage is calculated from elapsed run time during execution. If a run stops early, actual consumption can be lower than the original estimate.
Execution-target runs and final consumption
When a sequence block is configured to stop after reaching an execution target, Leapwork Performance separates the planning estimate from the final persisted usage.
-
The timeline estimate reflects the configured billed load profile and the maximum time the block could run.
-
During execution, Leapwork Performance tracks how many seconds the sequence block actually ran.
-
As soon as the execution target is reached, the run stops.
-
Final usage is then calculated from the actual elapsed runtime, not the maximum possible runtime.
Example:
-
A sequence block could be configured with a load profile that would allow it to run for 4 minutes.
-
If the execution target is reached after 1 minute, the final usage is based on that 1 minute of actual runtime.
-
In other words, Leapwork Performance does not continue deducting usage for the remaining 3 minutes that never ran.
Summary
To estimate Virtual User Hours in a timeline, Leapwork Performance calculates the total virtual-user-over-time consumption for every sequence block and adds those values together.
Review update: Apply the 50-user billing increment to each load point first, then calculate the segment and timeline totals.
As a quick rule of thumb:
-
flat segment:
billed users x hours -
ramp segment:
average billed users x hours -
full timeline: add every segment across every track