Details
-
Task
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
Impala 2.7.0
-
None
Description
The query generator design could use improvement. One of the design principles I've heard is "an object should have 1 responsibility". That is not the case with the query generator, especially with the QueryResultComparator and QueryExecutor in disrepancy_searcher.py. They each have several responsibilities. Also, Leopard's Job() duplicates some of this work.
There should be 1 thing that can compare two Query objects' results.
There should be 1 thing that knows how to execute any AbstractStatement concurrently on both a test and reference database.
There should be 1 thing to track so-called "execution modes". Really what we want here is a sequence of setup statements, a sequence of test statements, and a sequence of teardown statements.
As it stands the above is all mingled together across the classes, make extensibility difficult.