Database management system, computer, and database management method
AssigneesHitachi, Ltd., The University of Tokyo
InventorsAkira Shimizu, Seisuke Tokuda, Michiko Yoshida, Kazuhiko Mogi, Shinji Fujiwara, Nobuo Kawamura, Masaru Kitsuregawa, Kazuo Goda
Life of this patent
Estimating the term…
Abstract
A database management system (DBMS) generates a query execution plan including information representing one or more database (DB) operations necessary for executing a query and executes the query based on the query execution plan. In the execution of the query, the DBMS dynamically generates a task for executing a DB operation and executes the dynamically generated task. The DBMS executes a task in a plurality of threads executed by a processor core.
Claims15
A database management system being realized by a computer including a plurality of processor cores and for managing a database, comprising:
- a query reception unit being configured to receive a query to the database;
- a query execution plan generation unit being configured to generate a query execution plan including information representing a processing step necessary for executing the received query and an execution procedure of the processing step;
- and
- a query execution unit being configured to execute the received query based on the generated query execution plan, and in executing the received query, dynamically generate a task for executing the processing step and execute the dynamically generated task,
- wherein the query execution plan generation unit is configured to execute a context sharing determination processing based on execution state information of the generated task, the execution state information of the generated task including information related to acquired data that is necessary for generating a result for the generated task, to determine whether a context relating to the processing step is to be shared between a plurality of threads or to be not shared between the plurality of threads, and
- wherein the query execution unit is configured to:
- generate the context including the execution state information of the generated task in the execution of the received query,
- manage the generated context by associating the generated context with a generated task assigned thread, based on a result of the determination,
- assign the plurality of threads to the plurality of processor cores in the execution of the received query, and
- in each of the plurality of threads, execute one or more tasks assigned to the thread, respectively, based on the context associated with the thread.
A computer comprising:
- a storage resource;
- and
- a control device including a plurality of processor cores which is coupled to the storage resource,
- the control device being configured to:
- receive a query to a database,
- generate a query execution plan including information representing a processing step necessary for executing the received query and an execution procedure of the processing step,
- execute the received query based on the generated query execution plan, and in executing the received query, dynamically generate a task for executing a processing step and execute the dynamically generated task,
- execute a context sharing determination processing based on execution state information of the generated task, the execution state information of the generated task including information related to acquired data that is necessary for generating a result for the generated task, to determine whether a context relating to the processing step is to be shared between a plurality of threads or to be not shared between the plurality of threads,
- generate the context including the execution state information of the generated task in the execution of the received query,
- manage the generated context by associating the generated context with a generated task assigned thread, based on a result of the determination,
- assign the plurality of threads to the plurality of processor cores in the execution of the received query, and
- in each of the plurality of threads, execute one or more tasks assigned to the thread, respectively, based on the context associated with the thread.
A database management method for managing a database, comprising the steps of:
- (a) accepting a query to the database;
- (b) generating a query execution plan including information representing a plurality of one or more processing steps necessary for executing the received query and an execution procedure of the one or more processing steps;
- and
- (c) executing the received query by dynamically generating a task for executing a processing step and executing the dynamically generated task based on the generated query execution plan,
- wherein in step (b), the method further comprising:
- executing a context sharing determination processing based on execution state information of the generated task, the execution state information of the generated task including information related to acquired data that is necessary for generating a result for the generated task, to determine whether a context relating to the processing step is to be shared between a plurality of threads or to be not shared between the plurality of threads, and
- wherein in step (c), the method further comprising:
- generating the context including the execution state information of the generated task in the execution of the received query,
- managing the generated context by associating the generated context with a generated task assigned thread, based on a result of the determination,
- assigning the plurality of threads to a plurality of processor cores in the execution of the received query, and
- in each of the plurality of threads, executing one or more tasks assigned to the thread, respectively, based on the context associated with the thread.
Dependencies are inferred from the claim text.