static void constructAvgHitsGraph ( Map . Entry < String , LrProjectScenarioResults > scenarioResults , JSONObject scenarioGraphData ) { Map < Integer , WholeRunResult > avgHitsPerSec = scenarioResults . getValue ( ) . getAverageHitsPerSecondResults ( ) ; JSONObject avgHitsPerSecGraphSet = extractWholeRunSlaResult ( avgHitsPerSec , "Hits/Sec" ) ; if ( ! avgHitsPerSecGraphSet . getJSONArray ( LABELS ) . isEmpty ( ) ) { avgHitsPerSecGraphSet . put ( TITLE , "Average Hits per Second" ) ; avgHitsPerSecGraphSet . put ( X_AXIS_TITLE , "Build number" ) ; avgHitsPerSecGraphSet . put ( Y_AXIS_TITLE , "Hits" ) ; avgHitsPerSecGraphSet . put ( DESCRIPTION , "Displays the number of hits made on the Web server by Vusers " + "during each second of the load test. This graph helps you evaluate the amount of load " + "Vusers" + " " + "generate, in terms of the number of hits." ) ; scenarioGraphData . put ( "avgHitsPerSec" , avgHitsPerSecGraphSet ) ; } }
Construct avg hits graph .