Using State Modules for Adaptive Query Processing

Vijayshankar Raman, Amol Deshpande and Joseph M. Hellerstein

EECS Department
University of California, Berkeley
Technical Report No. UCB/CSD-03-1231
February 2003

http://www2.eecs.berkeley.edu/Pubs/TechRpts/2003/CSD-03-1231.pdf

We present a query architecture in which join operators are decomposed into their constituent data structures (State Modules, or SteMs), and dataflow among these SteMs is managed adaptively by an Eddy routing operator. Breaking the encapsulation of joins serves two purposes. First, it allows the Eddy to observe multiple physical operations embedded in a join algorithm, allowing for better calibration and control of these operations. Second, the SteM on a relation serves as a shared materialization point, enabling multiple competing access methods to share results, which can be leveraged by multiple competing join algorithms. Our architecture extends prior work significantly, allowing continuously adaptive decisions for most major aspects of traditional query optimization: choice of access methods and join algorithms, ordering of operators, and choice of a query spanning tree.

SteMs introduce significant routing flexibility to the Eddy, enabling more opportunities for adaptation, but also introducing the possibility of incorrect query results. We present constraints on Eddy routing through SteMs that ensure correctness while preserving a great deal of flexibility. We also demonstrate the benefits of our architecture via experiments in the Telegraph dataflow system. We show that even a simple routing policy allows significant flexibility in adaptation, including novel effects like automatic "hybridization" of multiple algorithms for a single join.


BibTeX citation:

@techreport{Raman:CSD-03-1231,
    Author = {Raman, Vijayshankar and Deshpande, Amol and Hellerstein, Joseph M.},
    Title = {Using State Modules for Adaptive Query Processing},
    Institution = {EECS Department, University of California, Berkeley},
    Year = {2003},
    Month = {Feb},
    URL = {http://www2.eecs.berkeley.edu/Pubs/TechRpts/2003/5351.html},
    Number = {UCB/CSD-03-1231},
    Abstract = {We present a query architecture in which join operators are decomposed into their constituent data structures (State Modules, or SteMs), and dataflow among these SteMs is managed adaptively by an Eddy routing operator. Breaking the encapsulation of joins serves two purposes. First, it allows the Eddy to observe multiple physical operations embedded in a join algorithm, allowing for better calibration and control of these operations. Second, the SteM on a relation serves as a shared materialization point, enabling multiple competing access methods to share results, which can be leveraged by multiple competing join algorithms. Our architecture extends prior work significantly, allowing continuously adaptive decisions for most major aspects of traditional query optimization: choice of access methods and join algorithms, ordering of operators, and choice of a query spanning tree. <p>SteMs introduce significant routing flexibility to the Eddy, enabling more opportunities for adaptation, but also introducing the possibility of incorrect query results. We present constraints on Eddy routing through SteMs that ensure correctness while preserving a great deal of flexibility. We also demonstrate the benefits of our architecture via experiments in the Telegraph dataflow system. We show that even a simple routing policy allows significant flexibility in adaptation, including novel effects like automatic "hybridization" of multiple algorithms for a single join.}
}

EndNote citation:

%0 Report
%A Raman, Vijayshankar
%A Deshpande, Amol
%A Hellerstein, Joseph M.
%T Using State Modules for Adaptive Query Processing
%I EECS Department, University of California, Berkeley
%D 2003
%@ UCB/CSD-03-1231
%U http://www2.eecs.berkeley.edu/Pubs/TechRpts/2003/5351.html
%F Raman:CSD-03-1231