← Back to team overview

randgen team mailing list archive

Re: [Branch ~randgen/randgen/rqg2] Rev 576: more robustExecutionTimeComparator

 

On 10/26/10 16:17, Philip Stoev wrote:

more robust ExecutionTimeComparator

Robust... against what? Faulty queries?

Yes, against trying to calculate the relative performance of invalid
queries, including if the query is not valid for one of the servers
being compared.

Thanks, makes sense.


The other thing I tried to achieve is not report performance regressions
where the result set has more rows than a certain threshold. Such
queries spend considerable time just transfering the result rows along
the stack, including DBI and Perl, which affects the measured running
times. Also, they are inconvenient for developers to work with.

OK. I must remember to adjust this if I want to check execution time for bigger results then. But I'll keep in mind the overhead/penalty in that case.


This has to eventually be made configurable. Are you using the
ExecutionTimeComparator in your tests?

I just started playing with it. I expect to use it every now and then going forward.



modified:
lib/GenTest/Validator/ExecutionTimeComparator.pm

Part of the diff:

-------------------------------------------
@@ -47,6 +48,7 @@
my $query = $results->[0]->query();

return STATUS_WONT_HANDLE if $query !~ m{^\s*SELECT}sio;
+ return STATUS_WONT_HANDLE if $results->[0]->status() != STATUS_OK ||
$results->[0]->status() != STATUS_OK;

You are right it must be [1] on the right side.

OK.

--
John



References