From 883f68301b2b09241be6b084d05e8b5bc2ae02a6 Mon Sep 17 00:00:00 2001 From: Zac Spitzer Date: Tue, 16 Jul 2024 13:39:17 +0200 Subject: [PATCH] cleanup --- custom/benchmark/index.cfm | 16 ++++++++-------- custom/benchmark/report.cfm | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/custom/benchmark/index.cfm b/custom/benchmark/index.cfm index eec080d..adb3e0d 100644 --- a/custom/benchmark/index.cfm +++ b/custom/benchmark/index.cfm @@ -1,5 +1,5 @@ - runs = server.system.environment.BENCHMARK_CYCLES ?: 20000; + runs = server.system.environment.BENCHMARK_CYCLES ?: 100000; arr = []; warmup = [] @@ -11,22 +11,22 @@ runs: runs } }; - + ArraySet( arr, 1, runs, 0 ); ArraySet( warmup, 1, 100, 0 ); - - _memBefore = reportMem( "", {}, "before", "HEAP" ); + + _memBefore = reportMem( "", {}, "before", "HEAP" ); loop list="once,never" item="inspect" { configImport( {"inspectTemplate": inspect }, "server", "admin" ); - + loop list="#application.testSuite.toList()#" item="type" { ArrayEach( arr, function( item ){ _internalRequest( template: "/tests/#type#.cfm" ); }, true ); - systemOutput( "Sleeping 2s first, after warmup", true ); + systemOutput( "Sleeping 2s first, after warmup", true ); sleep( 2000 ); // time to settle systemOutput( "Running #type# [#numberFormat( runs )#] times, inspect: [#inspect#]", true ); @@ -43,7 +43,7 @@ ArrayAppend( results.data, { time: time, inspect: inspect, - type: type + type: type }); } } @@ -86,7 +86,7 @@ continue; if (qry.max == -1) var perc = 0; - else + else var perc = int( ( qry.used / qry.max ) * 100 ); //if(qry.max<0 || qry.used<0 || perc<90) continue; //if(qry.max<0 || qry.used<0 || perc<90) continue; diff --git a/custom/benchmark/report.cfm b/custom/benchmark/report.cfm index 3aa2dbf..cb15500 100644 --- a/custom/benchmark/report.cfm +++ b/custom/benchmark/report.cfm @@ -30,7 +30,7 @@ loop list="once,never" item="inspect" { loop list="#application.testSuite.toList()#" item="type" { - dumpTable( q_hello_once, type, inspect, replace(type,"-", " ", "all") & " - " & UCase( inspect ) ); + dumpTable( q, type, inspect, replace(type,"-", " ", "all") & " - " & UCase( inspect ) ); } }