Systems and methods for managing queries
First Claim
1. A method for managing a new continuous query that includes folding a new continuous query into a shared continuous query plan (SCP) associated with a global range table, the method comprising:
- receiving via a computer readable storage medium a new continuous query;
compiling the new continuous query to generate an iterator model plan (IMP) and an associated local range table that includes a list of range variables, each of which uniquely identifies an object in the new continuous query, and wherein the IMP corresponds to an execution plan generated for the new continuous query and comprises one or more IMP operators, each of which includes one or more expressions whose variables are associated with the local range table;
analyzing the one or more IMP operators of the IMP and one or more SCP operators of the SCP to produce one or more variable transforms and one or more plan items;
wherein the one or more variable transforms modify the one or more expressions of the one or more IMP operators by associating the one or more IMP operators with variables of a global range table;
wherein the one or more plan items comprise one or more groups of the one or more IMP operators;
applying the variable transforms to modify the variables of the one or more iterator model plan IMP operators;
generating a continuous query operator based on each plan item included in the one or more plan items; and
providing the generated continuous query operator to a shared continuous query plan.
4 Assignments
0 Petitions
Accused Products
Abstract
A streaming database management system may provide support for creating a new continuous query operator for on-the-fly addition of a new query, e.g., a new SQL query and/or new continuous query operator, into a shared continuous query plan. Alternatively, the streaming database management system may associate the new query on-the-fly with an existing continuous query operator, such as a relational operator and expression evaluator, to reuse the existing continuous query operator. In some embodiments, multiple operators are grouped for on-the-fly addition to the shared continuous query plan. Alternatively, the streaming database management system may identify a group of multiple operators in the shared continuous query plan for reuse by the new query.
8 Citations
17 Claims
-
1. A method for managing a new continuous query that includes folding a new continuous query into a shared continuous query plan (SCP) associated with a global range table, the method comprising:
-
receiving via a computer readable storage medium a new continuous query; compiling the new continuous query to generate an iterator model plan (IMP) and an associated local range table that includes a list of range variables, each of which uniquely identifies an object in the new continuous query, and wherein the IMP corresponds to an execution plan generated for the new continuous query and comprises one or more IMP operators, each of which includes one or more expressions whose variables are associated with the local range table; analyzing the one or more IMP operators of the IMP and one or more SCP operators of the SCP to produce one or more variable transforms and one or more plan items; wherein the one or more variable transforms modify the one or more expressions of the one or more IMP operators by associating the one or more IMP operators with variables of a global range table; wherein the one or more plan items comprise one or more groups of the one or more IMP operators; applying the variable transforms to modify the variables of the one or more iterator model plan IMP operators; generating a continuous query operator based on each plan item included in the one or more plan items; and providing the generated continuous query operator to a shared continuous query plan. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11)
-
-
12. A system for new continuous query that includes folding a new continuous query into a shared continuous query plan (SCP) associated with a global range table, the system comprising:
-
a processor; and a computer readable storage medium having instructions for execution by the processor which causes the processor to; receive a new continuous query; compile the new continuous query to generate an iterator model plan (IMP) and an associated local range table that includes a list of range variables, each of which uniquely identifies an object in the new continuous query, and wherein the IMP corresponds to an execution plan generated for the new continuous query and comprises one or more IMP operators, each of which includes one or more expressions whose variables are associated with the local range table; analyze the one or more IMP operators of IMP and one or more SCP operators of the SCP to produce one or more variable transforms and one or more plan items; wherein the one or more variable transforms modify the one or more expressions of the one or more IMP operators by associating the one or more IMP operators with variables of a global range table; wherein the one or more plan items comprise one or more groups of the one or more IMP operators; apply the variable transforms to modify the variables of the one or more IMP operators; generate a continuous query operator based on each plan item included in the one or more plan items; and provide the generated continuous query operator to a shared continuous query plan. - View Dependent Claims (13, 14, 15, 16, 17)
-
Specification