| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>org.apache.drill.test (Drill : 1.20.0 API)</title> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> |
| <script type="text/javascript" src="../../../../script.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="org.apache.drill.test (Drill : 1.20.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li class="navBarCell1Rev">Package</li> |
| <li>Class</li> |
| <li><a href="package-use.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/drill/store/openTSDB/package-summary.html">Prev Package</a></li> |
| <li><a href="../../../../org/apache/drill/test/rowSet/package-summary.html">Next Package</a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/drill/test/package-summary.html" target="_top">Frames</a></li> |
| <li><a href="package-summary.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <a name="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <div class="header"> |
| <h1 title="Package" class="title">Package org.apache.drill.test</h1> |
| <div class="docSummary"> |
| <div class="block"> |
| Provides a variety of test framework tools to simplify Drill unit |
| tests and ad-hoc tests created while developing features.</div> |
| </div> |
| <p>See: <a href="#package.description">Description</a></p> |
| </div> |
| <div class="contentContainer"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Interface Summary table, listing interfaces, and an explanation"> |
| <caption><span>Interface Summary</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Interface</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tbody> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DrillTestWrapper.TestServices.html" title="interface in org.apache.drill.test">DrillTestWrapper.TestServices</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.VectorQueryReader.html" title="interface in org.apache.drill.test">QueryBuilder.VectorQueryReader</a><T,V></td> |
| <td class="colLast"> |
| <div class="block">VectorQueryReader function interface</div> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| </li> |
| <li class="blockList"> |
| <table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Class Summary table, listing classes, and an explanation"> |
| <caption><span>Class Summary</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Class</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tbody> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html" title="class in org.apache.drill.test">BaseDirTestWatcher</a></td> |
| <td class="colLast"> |
| <div class="block">Overview</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseFixture.html" title="class in org.apache.drill.test">BaseFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Base class for "fixtures." Provides the basics such as the Drill |
| configuration, a memory allocator and so on.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseTest.html" title="class in org.apache.drill.test">BaseTest</a></td> |
| <td class="colLast"> |
| <div class="block">Contains patchers that must be executed at the very beginning of test runs.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseTestQuery.html" title="class in org.apache.drill.test">BaseTestQuery</a></td> |
| <td class="colLast"> |
| <div class="block">deprecated Use <a href="../../../../org/apache/drill/test/ClusterTest.html" title="class in org.apache.drill.test"><code>ClusterTest</code></a> instead.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseTestQuery.ClassicTestServices.html" title="class in org.apache.drill.test">BaseTestQuery.ClassicTestServices</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseTestQuery.SilentListener.html" title="class in org.apache.drill.test">BaseTestQuery.SilentListener</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BufferingQueryEventListener.html" title="class in org.apache.drill.test">BufferingQueryEventListener</a></td> |
| <td class="colLast"> |
| <div class="block">Drill query event listener that buffers rows into a producer-consumer |
| queue.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BufferingQueryEventListener.QueryEvent.html" title="class in org.apache.drill.test">BufferingQueryEventListener.QueryEvent</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClientFixture.html" title="class in org.apache.drill.test">ClientFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Represents a Drill client.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClientFixture.ClientBuilder.html" title="class in org.apache.drill.test">ClientFixture.ClientBuilder</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClientFixture.StatementParser.html" title="class in org.apache.drill.test">ClientFixture.StatementParser</a></td> |
| <td class="colLast"> |
| <div class="block">Very simple parser for semi-colon separated lists of SQL statements which |
| handles quoted semicolons.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterFixture.html" title="class in org.apache.drill.test">ClusterFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Test fixture to start a Drillbit with provide options, create a client, and |
| execute queries.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterFixture.FixtureTestServices.html" title="class in org.apache.drill.test">ClusterFixture.FixtureTestServices</a></td> |
| <td class="colLast"> |
| <div class="block">Shim class to allow the <a href="../../../../org/apache/drill/test/TestBuilder.html" title="class in org.apache.drill.test"><code>TestBuilder</code></a> class to work with the |
| cluster fixture.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterFixtureBuilder.html" title="class in org.apache.drill.test">ClusterFixtureBuilder</a></td> |
| <td class="colLast"> |
| <div class="block">Build a Drillbit and client with the options provided.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterFixtureBuilder.RuntimeOption.html" title="class in org.apache.drill.test">ClusterFixtureBuilder.RuntimeOption</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterMockStorageFixture.html" title="class in org.apache.drill.test">ClusterMockStorageFixture</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ClusterTest.html" title="class in org.apache.drill.test">ClusterTest</a></td> |
| <td class="colLast"> |
| <div class="block">Base class for tests that use a single cluster fixture for a set of |
| tests.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ConfigBuilder.html" title="class in org.apache.drill.test">ConfigBuilder</a></td> |
| <td class="colLast"> |
| <div class="block">Builds a <a href="../../../../org/apache/drill/common/config/DrillConfig.html" title="class in org.apache.drill.common.config"><code>DrillConfig</code></a> for use in tests.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DirTestWatcher.html" title="class in org.apache.drill.test">DirTestWatcher</a></td> |
| <td class="colLast"> |
| <div class="block"> |
| This class is used to create consistently named and safe temp directories for |
| unit tests.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DrillAssert.html" title="class in org.apache.drill.test">DrillAssert</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DrillTest.html" title="class in org.apache.drill.test">DrillTest</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DrillTest.MemWatcher.html" title="class in org.apache.drill.test">DrillTest.MemWatcher</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/DrillTestWrapper.html" title="class in org.apache.drill.test">DrillTestWrapper</a></td> |
| <td class="colLast"> |
| <div class="block">Encapsulates the options for a Drill unit test, as well as the execution |
| methods to perform the tests and validation of results.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ExampleTest.html" title="class in org.apache.drill.test">ExampleTest</a></td> |
| <td class="colLast"> |
| <div class="block">Example test case using the Drill cluster fixture.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/FieldDef.html" title="class in org.apache.drill.test">FieldDef</a></td> |
| <td class="colLast"> |
| <div class="block">Basic representation of a column parsed from a query profile.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/HadoopUtils.html" title="class in org.apache.drill.test">HadoopUtils</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/LegacyOperatorTestBuilder.html" title="class in org.apache.drill.test">LegacyOperatorTestBuilder</a></td> |
| <td class="colLast">Deprecated |
| <div class="block"><span class="deprecationComment">Use <a href="../../../../org/apache/drill/test/OperatorTestBuilder.html" title="class in org.apache.drill.test"><code>OperatorTestBuilder</code></a> instead.</span></div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/LogFixture.html" title="class in org.apache.drill.test">LogFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Establishes test-specific logging without having to alter the global |
| <tt>logback-test.xml</tt> file.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/LogFixture.LogFixtureBuilder.html" title="class in org.apache.drill.test">LogFixture.LogFixtureBuilder</a></td> |
| <td class="colLast"> |
| <div class="block">Builds the log settings to be used for a test.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/LogFixture.LogSpec.html" title="class in org.apache.drill.test">LogFixture.LogSpec</a></td> |
| <td class="colLast"> |
| <div class="block">Memento for a logger name and level.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorFixture.html" title="class in org.apache.drill.test">OperatorFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Test fixture for operator and (especially) "sub-operator" tests.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorFixture.Builder.html" title="class in org.apache.drill.test">OperatorFixture.Builder</a></td> |
| <td class="colLast"> |
| <div class="block">Builds an operator fixture based on a set of config options and system/session |
| options.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorFixture.MockExecutorState.html" title="class in org.apache.drill.test">OperatorFixture.MockExecutorState</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorFixture.MockFragmentContext.html" title="class in org.apache.drill.test">OperatorFixture.MockFragmentContext</a></td> |
| <td class="colLast"> |
| <div class="block">Provide a simplified test-time code generation context that |
| uses the same code generation mechanism as the full Drill, but |
| provide test-specific versions of various other services.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorFixture.MockOperatorContext.html" title="class in org.apache.drill.test">OperatorFixture.MockOperatorContext</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorTestBuilder.html" title="class in org.apache.drill.test">OperatorTestBuilder</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorTestBuilderTest.html" title="class in org.apache.drill.test">OperatorTestBuilderTest</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/OperatorTestBuilderTest.MockPhysicalOperator.html" title="class in org.apache.drill.test">OperatorTestBuilderTest.MockPhysicalOperator</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PhysicalOpUnitTestBase.html" title="class in org.apache.drill.test">PhysicalOpUnitTestBase</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PhysicalOpUnitTestBase.BatchIterator.html" title="class in org.apache.drill.test">PhysicalOpUnitTestBase.BatchIterator</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PhysicalOpUnitTestBase.MockExecutorFragmentContext.html" title="class in org.apache.drill.test">PhysicalOpUnitTestBase.MockExecutorFragmentContext</a></td> |
| <td class="colLast"> |
| <div class="block">Note</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PhysicalOpUnitTestBase.MockPhysicalOperator.html" title="class in org.apache.drill.test">PhysicalOpUnitTestBase.MockPhysicalOperator</a></td> |
| <td class="colLast"> |
| <div class="block">Note</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PrintingResultsListener.html" title="class in org.apache.drill.test">PrintingResultsListener</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/PrintingUtils.html" title="class in org.apache.drill.test">PrintingUtils</a></td> |
| <td class="colLast"> |
| <div class="block"> |
| This class contains utility methods to run lambda functions with the necessary <a href="../../../../org/apache/drill/test/LogFixture.html" title="class in org.apache.drill.test"><code>LogFixture</code></a> |
| boilerplate to print results to stdout for debugging purposes.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.html" title="class in org.apache.drill.test">ProfileParser</a></td> |
| <td class="colLast"> |
| <div class="block">Parses a query profile and provides access to various bits of the profile |
| for diagnostic purposes during tests.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.Aggregator.html" title="class in org.apache.drill.test">ProfileParser.Aggregator</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.CostPrinter.html" title="class in org.apache.drill.test">ProfileParser.CostPrinter</a></td> |
| <td class="colLast"> |
| <div class="block">Print out the tree showing a comparison of estimated vs.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.FindOpVisitor.html" title="class in org.apache.drill.test">ProfileParser.FindOpVisitor</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.FragInfo.html" title="class in org.apache.drill.test">ProfileParser.FragInfo</a></td> |
| <td class="colLast"> |
| <div class="block">Information for a fragment, including the operators |
| in that fragment and the set of minor fragments.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.MinorFragInfo.html" title="class in org.apache.drill.test">ProfileParser.MinorFragInfo</a></td> |
| <td class="colLast"> |
| <div class="block">Information about a minor fragment as parsed from the profile.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.OperatorProfile.html" title="class in org.apache.drill.test">ProfileParser.OperatorProfile</a></td> |
| <td class="colLast"> |
| <div class="block">Detailed information about each operator within a minor fragment |
| for a major fragment.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.OperatorSummary.html" title="class in org.apache.drill.test">ProfileParser.OperatorSummary</a></td> |
| <td class="colLast"> |
| <div class="block">Information about an operator definition: the plan-time information |
| that appears in the plan portion of the profile.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.TimePrinter.html" title="class in org.apache.drill.test">ProfileParser.TimePrinter</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.TreePrinter.html" title="class in org.apache.drill.test">ProfileParser.TreePrinter</a></td> |
| <td class="colLast"> |
| <div class="block">Print the operator tree for analysis.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/ProfileParser.TreeVisitor.html" title="class in org.apache.drill.test">ProfileParser.TreeVisitor</a></td> |
| <td class="colLast"> |
| <div class="block">Visit a tree of operator definitions to support printing, |
| analysis and other tasks.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBatchIterator.html" title="class in org.apache.drill.test">QueryBatchIterator</a></td> |
| <td class="colLast"> |
| <div class="block">Iterator over batches returned from a query.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.html" title="class in org.apache.drill.test">QueryBuilder</a></td> |
| <td class="colLast"> |
| <div class="block">Builder for a Drill query.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.PlanMatcher.html" title="class in org.apache.drill.test">QueryBuilder.PlanMatcher</a></td> |
| <td class="colLast"> |
| <div class="block">Collects expected and non-expected query patterns.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.QuerySummary.html" title="class in org.apache.drill.test">QueryBuilder.QuerySummary</a></td> |
| <td class="colLast"> |
| <div class="block">Summary results of a query: records, batches, run time.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.QuerySummaryFuture.html" title="class in org.apache.drill.test">QueryBuilder.QuerySummaryFuture</a></td> |
| <td class="colLast"> |
| <div class="block">The future used to wait for the completion of an async query.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryBuilder.SummaryOnlyQueryEventListener.html" title="class in org.apache.drill.test">QueryBuilder.SummaryOnlyQueryEventListener</a></td> |
| <td class="colLast"> |
| <div class="block">Listener used to retrieve the query summary (only) asynchronously |
| using a <a href="../../../../org/apache/drill/test/QueryBuilder.QuerySummaryFuture.html" title="class in org.apache.drill.test"><code>QueryBuilder.QuerySummaryFuture</code></a>.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryResultSet.html" title="class in org.apache.drill.test">QueryResultSet</a></td> |
| <td class="colLast"> |
| <div class="block">Returns query results as an iterator over row sets.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryRowSetIterator.html" title="class in org.apache.drill.test">QueryRowSetIterator</a></td> |
| <td class="colLast"> |
| <div class="block">Converts an incoming set of record batches into an iterator over a |
| set of row sets.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryRowSetReader.html" title="class in org.apache.drill.test">QueryRowSetReader</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/QueryTestUtil.html" title="class in org.apache.drill.test">QueryTestUtil</a></td> |
| <td class="colLast"> |
| <div class="block">Utilities useful for tests that issue SQL queries.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/RestClientFixture.html" title="class in org.apache.drill.test">RestClientFixture</a></td> |
| <td class="colLast"> |
| <div class="block">Represents a client for the Drill Rest API.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/RestClientFixture.Builder.html" title="class in org.apache.drill.test">RestClientFixture.Builder</a></td> |
| <td class="colLast"> |
| <div class="block">A builder for the rest client.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/StatementParser.html" title="class in org.apache.drill.test">StatementParser</a></td> |
| <td class="colLast"> |
| <div class="block">Very simple parser for semi-colon separated lists of SQL statements which |
| handles quoted semicolons.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/SubDirTestWatcher.html" title="class in org.apache.drill.test">SubDirTestWatcher</a></td> |
| <td class="colLast"> |
| <div class="block">This is a <code>org.junit.rules.TestWatcher</code> which is used to create and delete sub directories before and after unit tests respectively.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/SubDirTestWatcher.Builder.html" title="class in org.apache.drill.test">SubDirTestWatcher.Builder</a></td> |
| <td class="colLast"> |
| <div class="block">This is a builder for a <a href="../../../../org/apache/drill/test/SubDirTestWatcher.html" title="class in org.apache.drill.test"><code>SubDirTestWatcher</code></a>.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/SubOperatorTest.html" title="class in org.apache.drill.test">SubOperatorTest</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/TestBuilder.html" title="class in org.apache.drill.test">TestBuilder</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/TestGracefulShutdown.html" title="class in org.apache.drill.test">TestGracefulShutdown</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/TestTools.html" title="class in org.apache.drill.test">TestTools</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/UserExceptionMatcher.html" title="class in org.apache.drill.test">UserExceptionMatcher</a></td> |
| <td class="colLast"> |
| <div class="block">Matcher for UserException that matches if expected type and actual type are the same, and expected message is |
| contained in the actual message.</div> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| </li> |
| <li class="blockList"> |
| <table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Enum Summary table, listing enums, and an explanation"> |
| <caption><span>Enum Summary</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Enum</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tbody> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BaseDirTestWatcher.DirType.html" title="enum in org.apache.drill.test">BaseDirTestWatcher.DirType</a></td> |
| <td class="colLast"> |
| <div class="block">An enum used to represent the directories mapped to the <b>dfs.root</b> and |
| <b>dfs.tmp</b> workspaces respectively.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/BufferingQueryEventListener.QueryEvent.Type.html" title="enum in org.apache.drill.test">BufferingQueryEventListener.QueryEvent.Type</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/FieldDef.Type.html" title="enum in org.apache.drill.test">FieldDef.Type</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/FieldDef.TypeHint.html" title="enum in org.apache.drill.test">FieldDef.TypeHint</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><a href="../../../../org/apache/drill/test/TestTools.FileSource.html" title="enum in org.apache.drill.test">TestTools.FileSource</a></td> |
| <td class="colLast"> </td> |
| </tr> |
| </tbody> |
| </table> |
| </li> |
| </ul> |
| <a name="package.description"> |
| <!-- --> |
| </a> |
| <h2 title="Package org.apache.drill.test Description">Package org.apache.drill.test Description</h2> |
| <div class="block"><p> |
| Provides a variety of test framework tools to simplify Drill unit |
| tests and ad-hoc tests created while developing features. Key components |
| include: |
| </p> |
| <ul> |
| <li> |
| <a href="../../../../org/apache/drill/test/ClusterFixtureBuilder.html" title="class in org.apache.drill.test"><code>ClusterFixtureBuilder</code></a>: Builder pattern to create an embedded Drillbit, |
| or cluster of Drillbits, using a specified set of configuration, session |
| and system options. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/ClusterFixture.html" title="class in org.apache.drill.test"><code>ClusterFixture</code></a>: The cluster created by the builder. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/ClientFixture.html" title="class in org.apache.drill.test"><code>ClientFixture</code></a>: A facade to the Drill client that provides |
| convenience methods for setting session options, running queries and |
| so on. A client is associated with a cluster. If tests desire, multiple |
| clients can be created for a single cluster, though most need just one |
| client. A builder exists for clients, but most tests get the client |
| directly from the cluster. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/QueryBuilder.html" title="class in org.apache.drill.test"><code>QueryBuilder</code></a>: a builder pattern for constructing and |
| running any form of query (SQL, logical or physical) and running the |
| query in a wide variety of ways (just count the rows, return the |
| results as a list, run using a listener, etc.) |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/QueryBuilder.QuerySummary.html" title="class in org.apache.drill.test"><code>QuerySummary</code></a>: a summary of a |
| query returned from running the query. Contains the query ID, the |
| row count, the batch count and elapsed run time. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/ProfileParser.html" title="class in org.apache.drill.test"><code>ProfileParser</code></a>: A simple tool to load a query profile and |
| provide access to the profile structure. Also prints the key parts of |
| the profile for diagnostic purposes. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/LogFixture.html" title="class in org.apache.drill.test"><code>LogFixture</code></a>: Allows per-test changes to log settings to, |
| say, send a particular logger to the console for easier debugging, or |
| to suppress logging of a deliberately created failure. |
| </li> |
| <li> |
| <a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html" title="class in org.apache.drill.test"><code>BaseDirTestWatcher</code></a>: Creates temporary directories which are used for the following |
| aspects of drill in unit tests: |
| <ul> |
| <li> |
| The <b>drill.tmp-dir</b> property: A temp directory (<a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html#getTmpDir--"><code>BaseDirTestWatcher.getTmpDir()</code></a>) is created and |
| configured as the tmp directory for drill bits. |
| </li> |
| <li> |
| The <b>drill.exec.sys.store.provider.local.path</b> property: A temp directory (<a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html#getStoreDir--"><code>BaseDirTestWatcher.getStoreDir()</code></a>) is created and |
| configured as the store directory for drillbits. |
| </li> |
| <li> |
| The <b>dfs.default</b> workspace: A temp directory (<a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html#getRootDir--"><code>BaseDirTestWatcher.getRootDir()</code></a> is created and configured as the directory |
| for this workspace. |
| </li> |
| <li> |
| The <b>dfs.root</b> workspace: <b>dfs.root</b> is configured to use the same temp directory ad <b>dfs.default</b>. |
| </li> |
| <li> |
| The <b>dfs.tmp</b> workspace: A temp directory (<a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html#getDfsTestTmpDir--"><code>BaseDirTestWatcher.getDfsTestTmpDir()</code></a>) is created and configured as the |
| directory for this workspace. |
| </li> |
| </ul> |
| By default a <a href="../../../../org/apache/drill/test/BaseDirTestWatcher.html" title="class in org.apache.drill.test"><code>BaseDirTestWatcher</code></a> is used in tests that extend <a href="../../../../org/apache/drill/test/BaseTestQuery.html" title="class in org.apache.drill.test"><code>BaseTestQuery</code></a> and tests that use |
| the <a href="../../../../org/apache/drill/test/ClusterFixture.html" title="class in org.apache.drill.test"><code>ClusterFixture</code></a>. |
| </li> |
| </ul> |
| <h3>Usage</h3> |
| <p> |
| A typical test using this framework looks like this: |
| </p> |
| <code><pre> |
| @org.junit.Rule |
| public final BaseDirTestWatcher dirTestWatcher = new BaseDirTestWatcher(); |
| |
| @Test |
| public void exampleTest() throws Exception { |
| createEmployeeCsv(dirTestWatcher.getRootDir()); |
| |
| // Configure the cluster. One Drillbit by default. |
| FixtureBuilder builder = ClusterFixture.builder(dirTestWatcher) |
| // Set up per-test specialized config and session options. |
| .configProperty(ExecConstants.SYS_STORE_PROVIDER_LOCAL_ENABLE_WRITE, true) |
| .configProperty(ExecConstants.REMOVER_ENABLE_GENERIC_COPIER, true) |
| .sessionOption(ExecConstants.MAX_QUERY_MEMORY_PER_NODE_KEY, 3L * 1024 * 1024 * 1024) |
| .maxParallelization(1); |
| |
| // Launch the cluster and client. |
| try (ClusterFixture cluster = builder.build(); |
| ClientFixture client = cluster.clientFixture()) { |
| |
| // Run a query (using the mock data source) and print a summary. |
| String sql = "SELECT id_i FROM dfs.`employee.csv` ORDER BY id_i"; |
| QuerySummary summary = client.queryBuilder().sql(sql).run(); |
| assertEquals(1_000_000, summary.recordCount()); |
| System.out.println(String.format("Sorted %,d records in %d batches.", summary.recordCount(), summary.batchCount())); |
| System.out.println(String.format("Query Id: %s, elapsed: %d ms", summary.queryIdString(), summary.runTimeMs())); |
| client.parseProfile(summary.queryIdString()).print(); |
| } |
| } |
| </pre></code> |
| Typical usage for the logging fixture: |
| <pre><code> |
| @Test |
| public void myTest() { |
| LogFixtureBuilder logBuilder = LogFixture.builder() |
| .toConsole() |
| .disable() // Silence all other loggers |
| .logger(ExternalSortBatch.class, Level.DEBUG); |
| try (LogFixture logs = logBuilder.build()) { |
| // Test code here |
| } |
| } |
| </code></pre></div> |
| </div> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li class="navBarCell1Rev">Package</li> |
| <li>Class</li> |
| <li><a href="package-use.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/drill/store/openTSDB/package-summary.html">Prev Package</a></li> |
| <li><a href="../../../../org/apache/drill/test/rowSet/package-summary.html">Next Package</a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/drill/test/package-summary.html" target="_top">Frames</a></li> |
| <li><a href="package-summary.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2022 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |