US 12,222,924 B2
Buffering techniques for a change record stream of a database
Benjamin Busjaeger, San Carlos, CA (US); and Igor Fedorenko, Toronto (CA)
Assigned to Salesforce, Inc., San Francisco, CA (US)
Filed by salesforce.com, inc., San Francisco, CA (US)
Filed on Nov. 11, 2021, as Appl. No. 17/454,585.
Prior Publication US 2023/0143636 A1, May 11, 2023
Int. Cl. G06F 16/23 (2019.01); G06F 16/21 (2019.01); G06F 16/2455 (2019.01); G06F 16/2458 (2019.01); G06F 16/25 (2019.01)
CPC G06F 16/2358 (2019.01) [G06F 16/219 (2019.01); G06F 16/24568 (2019.01); G06F 16/256 (2019.01)] 20 Claims
OG exemplary drawing
 
1. A method comprising:
receiving, by a computer system in a multi-tenant database service, a stream of shards that include change event records for a database stored on a server that is separate from the computer system, wherein a given change event record is indicative of a modification made to the database by one of a plurality of tenants, and wherein a given shard includes one or more change event records associated with a subset of the plurality of tenants over a particular period of time;
storing, by the computer system into one or more buffers, received shards of the stream of shards including the change event records, wherein the received shards are accessed from the one or more buffers independently from the server;
generating, by the computer system, a data structure that is separate from the one or more buffers, wherein the data structure includes information for respective shards of the received shards including a corresponding order of reception and a subset of tenants associated with a respective shard;
in response to receiving a query from a given tenant, processing, by the computer system, the query using the data structure to identify one or more of the received shards that include change event records associated with the given tenant; and
accessing, by the computer system, the identified shards from the one or more buffers to retrieve change event records relevant to the received query.