发明名称 Efficient locking of large data collections
摘要 The present disclosure provides systems and techniques for efficient locking of datasets in a database when updates to a dataset may be delayed. A method may include accumulating a plurality of updates to a first set of one or more values associated with one or more features. The first set of one or more values may be stored within a first database column. Next, it may be determined that a first database column update aggregation rule is satisfied. A lock assigned to at least a portion of at least a first database column may be acquired. Accordingly, one or more values in the first set within the first database column may be updated based on the plurality of updates. In an implementation, the first set of one or more values may be associated with the first lock.
申请公布号 US9569481(B1) 申请公布日期 2017.02.14
申请号 US201314101611 申请日期 2013.12.10
申请人 Google Inc. 发明人 Chandra Tushar Deepak;Shaked Tal;Singer Yoram;Ie Tze Way Eugene;Redstone Joshua
分类号 G06F7/00;G06F17/30 主分类号 G06F7/00
代理机构 Fish & Richardson P.C. 代理人 Fish & Richardson P.C.
主权项 1. A method comprising: storing a database that includes a plurality of database columns that each include a plurality of entries each having a respective value, wherein the plurality of database columns includes a first column; associating a first lock with a first lock portion of the database; associating a second lock with a second lock portion of the database, wherein the second lock portion does not overlap the first lock portion of the database and wherein the first lock portion of the database is more frequently updated than the second lock portion of the database; accumulating a plurality of first updates, each first update being an update to a value in the first lock portion of the database, prior to acquiring the first lock, until a first predetermined update aggregation rule is satisfied; in response to determining that the first predetermined update aggregation rule is satisfied, acquiring the first lock associated with the first lock portion of the database and then updating the database by applying the accumulated first updates to the first lock portion of the database; accumulating a plurality of second updates, each second update being an update to a value in the second lock portion of the database, prior to acquiring the second lock, until a second predetermined update aggregation rule is satisfied; in response to determining that the second predetermined update aggregation rule is satisfied, acquiring the second lock associated with the second lock portion of the database and then updating the database by applying the accumulated second updates to the second lock portion of the database; and associating one or more third locks with respective third lock portions of the database, wherein the third lock portions do not overlap each other, the first lock portion, or the second lock portion of the database, wherein the third lock portions are more frequently updated than the second lock portion, and wherein more frequently updated values are distributed across the first lock portion and one or more third lock portions to avoid lock contention.
地址 Mountain View CA US