Dropping an index without blocking locks

US11360802B2 · US · B2

Patent metadata
FieldValue
Publication numberUS-11360802-B2
Application numberUS-202016887980-A
CountryUS
Kind codeB2
Filing dateMay 29, 2020
Priority dateMar 31, 2014
Publication dateJun 14, 2022
Grant dateJun 14, 2022

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

Techniques for processing “destructive” database statements are provided. Destructive database statements, when processed, cause metadata of a database object to be changed. Examples of such database statements include ones that delete an index, that set a column as unused, and that drop a constraint on a column. When such a statement is received, a change is made to metadata of a database object. Such a metadata change may involve setting an index as unusable, disabling a constraint, or invalidating a cursor. After the metadata change, a first time is determined. Then, it is determined when one or more database transactions that were pending at the first time have committed. After those database transaction(s) have committed, one or more operations are performed, such as dropping an index or dropping a constraint.

First claim

Opening claim text (preview).

What is claimed is: 1. A method comprising: while storing metadata that indicates that an index is usable, receiving an instruction to drop the index that is based on a table; in response to receiving the instruction and without using a lock, to process the instruction, that would block transactions involving the table: updating the metadata to indicate that the index is unusable; after updating the metadata, determining a particular timestamp; waiting for one or more transactions that are pending at a time associated with the particular timestamp to commit; in response to determining that the one or more transactions have committed, dropping the index; wherein the method is performed by one or more computing devices. 2. The method of claim 1 , further comprising: in response to receiving the instruction and prior to determining the particular timestamp, invalidating one or more cursors that are associated with the index. 3. The method of claim 1 , further comprising: in response to receiving the instruction, acquiring a lock on the table upon which the index is based, wherein the lock does not prevent other database transactions from modifying the table. 4. The method of claim 1 , wherein updating, determining, waiting, and dropping are performed within a database transaction. 5. The method of claim 4 , wherein: the database transaction is a first database transaction; updating is performed within a second database transaction that is within the first database transaction. 6. The method of claim 1 , wherein waiting comprises calling a function that takes, as input, the particular timestamp and an object identifier that identifies the index or the table. 7. The method of claim 1 , wherein the one or more transactions involve accessing the index. 8. The method of claim 7 , further comprising: after updating the metadata and prior to the one or more transactions committing, processing the one or more transactions. 9. A method comprising: while storing metadata that indicates that a constraint on a column is usable, receiving an instruction to modify the metadata that is associated with the column of a table; in response to receiving the instruction: updating the metadata to indicate that the constraint on the column of the table is disabled; determining a particular timestamp; waiting for one or more transactions that are pending at a time associated with the particular timestamp to commit; in response to determining that the one or more transactions have committed, dropping the constraint; wherein the method is performed by one or more computing devices. 10. The method of claim 9 , wherein the instruction is to drop the constraint of the column of the table. 11. The method of claim 9 , wherein: the instruction is to set the column unused; the method further comprising, prior to determining the particular timestamp, storing second data that indicates that the column is unusable. 12. The method of claim 11 , further comprising: prior to determining the particular timestamp, determining whether the constraint on the column exists; wherein updating the metadata comprises updating the metadata that indicates that the constraint is disabled in response to determining that the constraint on the column exists. 13. The method of claim 9 , further comprising: in response to receiving the instruction and prior to determining the particular timestamp: determining whether an index exists on the column; if it is determined that an index exists on the column, then storing data that indicates that the index is unusable; in response to determining that the one or more transactions have committed, dropping the index if it is determined that the index exists. 14. The method of claim 9 , further comprising: in response to receiving the instruction and prior to determining the particular timestamp, invalidating one or more cursors. 15. The method of claim 9 , wherein waiting comprises calling a function that takes, as input, the particular timestamp and an object identifier that identifies the column or the table. 16. One or more non-transitory computer-readable media storing instructions which, when executed by one or more processors, cause: while storing metadata that indicates that an index is usable, receiving an instruction to drop the index that is based on a table; in response to receiving the instruction and without using a lock, to process the instruction, that would block transactions involving the table: updating the metadata to indicate that the index is unusable; after updating the metadata, determining a particular timestamp; waiting for one or more transactions that are pending at a time associated with the particular timestamp to commit; in response to determining that the one or more transactions have committed, dropping the index. 17. The one or more non-transitory computer-readable media of claim 16 , wherein the instructions, when executed by the one or more processors, further cause: in response to receiving the instruction and prior to determining the particular timestamp, invalidating one or more cursors that are associated with the index or with the table upon which the index is based. 18. The one or more non-transitory computer-readable media of claim 16 , wherein the instructions, when executed by the one or more processors, further cause: in response to receiving the instruction, acquiring a lock on the table upon which the index is based, wherein the lock does not prevent other database transactions from modifying the table. 19. The one or more non-transitory computer-readable media of claim 16 , wherein updating, determining, waiting, and dropping are performed within a database transaction. 20. The one or more non-transitory computer-readable media of claim 19 , wherein: the database transaction is a first database transaction; updating is performed within a second database transaction that is within the first database transaction.

Assignees

Inventors

Classifications

  • Locking methods, e.g. distributed locking or locking implementation details · CPC title

  • Concurrency control (transaction processing G06F9/466) · CPC title

  • G06F16/22Primary

    Indexing; Data structures therefor; Storage structures · CPC title

  • G06F9/466Primary

    Transaction processing · CPC title

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US11360802B2 cover?
Techniques for processing “destructive” database statements are provided. Destructive database statements, when processed, cause metadata of a database object to be changed. Examples of such database statements include ones that delete an index, that set a column as unused, and that drop a constraint on a column. When such a statement is received, a change is made to metadata of a database obje…
Who is the assignee on this patent?
Oracle Int Corp
What technology area does this patent fall under?
Primary CPC classification G06F16/22. Mapped technology areas include Physics.
When was this patent published?
Publication date Tue Jun 14 2022 00:00:00 GMT+0000 (Coordinated Universal Time) (B2). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 8 related publications on this page (citations in our corpus or others sharing the same primary CPC).