Query Optimization for Stream Databases Presented by: Guillermo Cabrera Fall 2008.

Slides:



Advertisements
Similar presentations
Distributed Query Processing
Advertisements

Analysis of : Operator Scheduling in a Data Stream Manager CS561 – Advanced Database Systems By Eric Bloom.
Selinger Optimizer Lecture 10 October 15, 2009 Sam Madden.
C-Store: Self-Organizing Tuple Reconstruction Jianlin Feng School of Software SUN YAT-SEN UNIVERSITY Apr. 17, 2009.
Jaringan Komputer Lanjut Packet Switching Network.
Adaptive Query Processing with Eddies Amol Deshpande University of Maryland.
한국기술교육대학교 컴퓨터 공학 김홍연 TinyDB : An Acquisitional Query Processing System for Sensor Networks. - Samuel R. Madden, Michael J. Franklin, Joseph M. Hellerstein,
On-the-Fly Sharing for Streamed Aggregation Sailesh Krishnamurthy, Chung Wu, and Michael J. Franklin Presented by: Joshua Lee and Mingrui Wei Material.
Static Optimization of Conjunctive Queries with Sliding Windows over Infinite Streams Presented by: Andy Mason and Sheng Zhong Ahmed M.Ayad and Jeffrey.
IntroductionAQP FamiliesComparisonNew IdeasConclusions Adaptive Query Processing in the Looking Glass Shivnath Babu (Stanford Univ.) Pedro Bizarro (Univ.
Continuously Adaptive Processing of Data and Query Streams Michael Franklin UC Berkeley April 2002 Joint work w/Joe Hellerstein and the Berkeley DB Group.
Eddies: Continuously Adaptive Query Processing Ron Avnur Joseph M. Hellerstein UC Berkeley.
1-1 CMPE 259 Sensor Networks Katia Obraczka Winter 2005 Storage and Querying II.
Adaptive Ordering of Pipelined Stream Filters S. Babu, R. Motwani, K. Munagala, I. Nishizawa, and J. Widom In Proc. of SIGMOD 2004, June 2004.
Evaluating Window Joins Over Unbounded Streams By Nishant Mehta and Abhishek Kumar.
Dynamic Plan Migration for Continuous Query over Data Streams Yali Zhu, Elke Rundensteiner and George Heineman Database System Research Group Worcester.
1 Continuously Adaptive Continuous Queries (CACQ) over Streams Samuel Madden, Mehul Shah, Joseph Hellerstein, and Vijayshankar Raman Presented by: Bhuvan.
Adaptive Query Processing with Eddies Amol Deshpande University of Maryland.
CS 347Notes 041 CS 347: Distributed Databases and Transaction Processing Notes04: Query Optimization Hector Garcia-Molina.
Exploiting Correlated Attributes in Acquisitional Query Processing Amol Deshpande University of Maryland Joint work with Carlos Sam
Freddies: DHT-Based Adaptive Query Processing via Federated Eddies Ryan Huebsch Shawn Jeffery CS Peer-to-Peer Systems 12/9/03.
Flow Algorithms for Two Pipelined Filtering Problems Anne Condon, University of British Columbia Amol Deshpande, University of Maryland Lisa Hellerstein,
ITIS 5160 Indexing. Indexing datacubes Objective: speed queries up. Traditional databases (OLTP): B-Trees Time and space logarithmic to the amount of.
Dynamic Plan Migration for Continuous Queries over Data Streams Yali Zhu, Elke Rundensteiner and George Heineman Database System Research Group, WPI. Massachusetts,
Challenges in Sensor Network Query Processing Sam Madden NEST Retreat January 15, 2002.
The Design of an Acquisitional Query Processor For Sensor Networks Samuel Madden, Michael J. Franklin, Joseph M. Hellerstein, and Wei Hong Presentation.
Performance Issues in Adaptive Query Processing Fred Reiss U.C. Berkeley Database Group.
Models and Issues in Data Streaming Presented By :- Ankur Jain Department of Computer Science 6/23/03 A list of relevant papers is available at
Eddies: Continuously Adaptive Query Processing Based on a SIGMOD’2002 paper and talk by Avnur and Hellerstein.
Query Processing Presented by Aung S. Win.
Efficient Scheduling of Heterogeneous Continuous Queries Mohamed A. Sharaf Panos K. Chrysanthis Alexandros Labrinidis Kirk Pruhs Advanced Data Management.
NiagaraCQ : A Scalable Continuous Query System for Internet Databases (modified slides available on course webpage) Jianjun Chen et al Computer Sciences.
施賀傑 何承恩 TelegraphCQ. Outline Introduction Data Movement Implies Adaptivity Telegraph - an Ancestor of TelegraphCQ Adaptive Building.
The Design of an Acquisitional Query Processor For Sensor Networks Samuel Madden, Michael J. Franklin, Joseph M. Hellerstein, and Wei Hong.
1 XJoin: Faster Query Results Over Slow And Bursty Networks IEEE Bulletin, 2000 by T. Urhan and M Franklin Based on a talk prepared by Asima Silva & Leena.
Optimizing Sensor Data Acquisition for Energy-Efficient Smartphone-based Continuous Event Processing Lipyeow Lim University of Hawai`i at M ā noa Archan.
Index Tuning for Adaptive Multi-Route Data Stream Systems Karen Works, Elke A. Rundensteiner, and Emmanuel Agu Database Systems Research.
Data Streams and Continuous Query Systems
ITCS 6163 Lecture 5. Indexing datacubes Objective: speed queries up. Traditional databases (OLTP): B-Trees Time and space logarithmic to the amount of.
The Design of an Acquisitional Query Processor for Sensor Networks CS851 Presentation 2005 Presented by: Gang Zhou University of Virginia.
1 Fjording The Stream An Architecture for Queries over Streaming Sensor Data Samuel Madden, Michael Franklin UC Berkeley.
Ripple Joins for Online Aggregation by Peter J. Haas and Joseph M. Hellerstein published in June 1999 presented by Nag Prajval B.C.
REED: Robust, Efficient Filtering and Event Detection in Sensor Networks Daniel Abadi, Samuel Madden, Wolfgang Lindner MIT United States VLDB 2005.
1 REED: Robust, Efficient Filtering and Event Detection in Sensor Networks Daniel Abadi, Samuel Madden, Wolfgang Lindner MIT United States VLDB 2005.
Energy-Efficient Monitoring of Extreme Values in Sensor Networks Loo, Kin Kong 10 May, 2007.
Adaptive Query Processing in Data Stream Systems Paper written by Shivnath Babu Kamesh Munagala, Rajeev Motwani, Jennifer Widom stanfordstreamdatamanager.
An Example Data Stream Management System: TelegraphCQ INF5100, Autumn 2009 Jarle Søberg.
CS6321 Query Optimization Over Web Services Utkarsh Kamesh Jennifer Rajeev Shrivastava Munagala Wisdom Motwani Presented By Ajay Kumar Sarda.
1 Elke. A. Rundensteiner Worcester Polytechnic Institute Elisa Bertino Purdue University 1 Rimma V. Nehme Microsoft.
1 Supporting Dynamic Migration in Tightly Coupled Grid Applications Liang Chen Qian Zhu Gagan Agrawal Computer Science & Engineering The Ohio State University.
1 Continuously Adaptive Continuous Queries (CACQ) over Streams Samuel Madden SIGMOD 2002 June 4, 2002 With Mehul Shah, Joseph Hellerstein, and Vijayshankar.
Eddies: Continuously Adaptive Query Processing Ross Rosemark.
An Adaptive Query Execution Engine for Data Integration Zachary Ives, Daniela Florescu, Marc Friedman, Alon Levy, Daniel S. Weld University of Washington.
Adaptive Ordering of Pipelined Stream Filters Babu, Motwani, Munagala, Nishizawa, and Widom SIGMOD 2004 Jun 13-18, 2004 presented by Joshua Lee Mingzhu.
Rate-Based Query Optimization for Streaming Information Sources Stratis D. Viglas Jeffrey F. Naughton.
By: Peter J. Haas and Joseph M. Hellerstein published in June 1999 : Presented By: Sthuti Kripanidhi 9/28/20101 CSE Data Exploration.
The Design of an Acquisitional Query Processor For Sensor Networks Samuel Madden, Michael J. Franklin, Joseph M. Hellerstein, and Wei Hong Presentation.
ITIS 5160 Indexing.
Distributed database approach,
CrowdDb.
Coordination and computation over wireless networks
Streaming Sensor Data Fjord / Sensor Proxy Multiquery Eddy
CSE 4340/5349 Mobile Systems Engineering
REED : Robust, Efficient Filtering and Event Detection
TelegraphCQ: Continuous Dataflow Processing for an Uncertain World
Eddies for Continuous Queries
Recall Retrieved from:
Adaptive Query Processing (Background)
Relax and Adapt: Computing Top-k Matches to XPath Queries
Challenges in Sensor Network Query Processing
Presentation transcript:

Query Optimization for Stream Databases Presented by: Guillermo Cabrera Fall 2008

Agenda Scope Core Problem Eddy –Motivation –Challenges –Example Eddy usage in CACQ Final Remarks

Scope Query Optimization –Rate-based –Resource based –QoS –Query Adaptivity

Core Problem Traditional DMBS –Static query processing –Cost-based optimization Cost of query plan changes –Processing time of operator –Selectivity of predicate –Arrival rate of a stream Traditional optimizers unable to adapt to new environment

Light Sensor Selectivity

Adaptive Query Processing Adaptivity loop Measure AnalyzePlan Actuate

Eddy Motivation Need query plan to be re-optimized regularly Reorder operators while in flight

What is an Eddy Continuously reorders operators in query plan on tuple-by-tuple basis AB |X| C A |X| B A C B B C A Output B |X| C A |X| B Eddy Output

Challenges How to reorder operators? –Synchronization barriers –Moments of Symmetry How to route tuples? –Routing policies

Join Review R S RS Basic NLJGrid view R S S R … …

Reorder Operators Synchronization Barriers –One task waits for another to finish Moments of Symmetry –Stage for reordering Goal –Frequent moments of symmetry, non- existent barriers and minimal ordering constraints Ripple Joins

Route Tuples Tuple descriptor –Ready bits: Where to go next –Done bits: What has been done Naïve –Slower operators receive less tuples Lottery –Eddy holds lottery before sending tuple Window –Forget history to some extent

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…1100 Attribute…ReadyDone Value…1000 b: a:

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…1100 Attribute…ReadyDone Value…1000 b: a: a b c

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…1100 Attribute…ReadyDone Value…1000 b: a: a b c Options: (A B) C A (B C)

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…1100 Attribute…ReadyDone Value…1000 b: a: a b c

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…1001 Attribute…ReadyDone Value…1000 b: a: a bc

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…0011 Attribute…ReadyDone Value…1000 b: a: abc bc

Eddy Example Output A |X| B B |X| C Eddy SELECT * from A, B, C WHERE A.x = B.x AND B.x = C.x c: Attribute…ReadyDone Value…0100 B C A Attribute…ReadyDone Value…0011 Attribute…ReadyDone Value…1000 b: a: abc

CACQ Project Continuously Adaptive Continuous Queries CQ lives long enough for changes to occur Motivation –Streams of data from sensor networks EddyCQ Pred. Index SteMsCACQ

CACQ Performance NiagaraCQ uses static plan

Final Remarks Stream databases in constant change Need to efficiently react to changes Tradeoff between adaptivity and overhead required to route tuples separately Routing policies very important –Not much work so far Other optimization schemes

References [AH00] R. Avnur, J. M. Hellerstein: Eddies: Continuously Adaptive Query Processing SIGMOD Conference 2000 [M02] S. Madden, et.al: Continuously Adaptive Continuous Queries over Streams. SIGMOD Conference 2002