# US 10,976,950 B1 · Distributed dataset modification, retention, and replication

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 10,976,950 B1
- Document ID: US10976950B1
- Status: Granted
- Kind: B1
- Application number: 16/248,640
- Filed: 2019-01-15
- Granted: 2021-04-13
- Earliest claimed: 2019-01-15
- Assignees: Twitter, Inc.
- Applicants: Twitter, Inc.
- Inventors: Chris Trezzo; Jason Sprowl; Joep Rottinghuis
- Web page: https://patentgrep.com/patent/US10976950B1

## CPC

- G06F 3/0619: {in relation to data integrity, e.g. data losses, bit errors}
- G06F 3/0644: {Management of space entities, e.g. partitions, extents, pools}
- G06F 3/0608: {Saving storage space on storage systems}
- G06F 3/0625: {Power saving in storage systems}
- G06F 3/0649: {Lifecycle management}
- G06F 3/0652: {Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket}
- G06F 3/067: {Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]}
- Y02D 10/00: Energy efficient computing, e.g. low power processors, power management or thermal management
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- Y02D: CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE

## Abstract

Methods, systems, and apparatus, including computer programs encoded on computer storage media, for data retention and modification. One of the methods includes dividing partitions into a set of generations according to a retention policy; accumulating modification and deletion events that define changes to be applied to data of the distributed dataset; and when a triggering event occurs for a triggered generation in the set of generations, rolling an oldest partition out of the triggered generation, the rolling comprising: if the oldest partition has reached the end of a retention period for the dataset, marking the oldest partition for deletion in the triggered generation; otherwise: creating a new partition corresponding to the data of the oldest partition, wherein the data is cleaned using a scrubbing process; adding the new partition to a next generation in the set of generations; and marking the oldest partition for deletion in the triggered generation.

## Claims

### Claim 1

A method for data retention and modification, according to a retention policy, of a distributed dataset stored in partitions, the method comprising:
dividing the partitions into an ordered set of generations according to the retention policy;
accumulating modification and deletion events that define changes to be applied to data of the distributed dataset; and
when a triggering event occurs for a triggered generation in the set of generations, rolling an oldest partition out of the triggered generation, the rolling comprising:
if the oldest partition has reached the end of a retention period for the dataset, marking the oldest partition for deletion in the triggered generation;
otherwise:
creating a new partition corresponding to the data of the oldest partition, wherein the data is cleaned using a scrubbing process based on the defined changes to be applied to data in the oldest partition;
adding the new partition to a next generation in the ordered set of generations of the dataset; and
marking the oldest partition for deletion in the triggered generation.

### Claim 2 (depends on 1)

The method of claim 1, wherein the set of generations includes a number of generations determined based on an overall retention period of the dataset and an active size of a generation.

### Claim 3 (depends on 1)

The method of claim 1, wherein marking the oldest partition for deletion includes marking the oldest partition inactive in the generation for a time period limited by a specified deletion period.

### Claim 4 (depends on 1)

The method of claim 1, wherein dividing the dataset partitions into the set of generations structures includes associating each dataset partition with metadata that includes generation information and information about when the dataset partition was created.

### Claim 5 (depends on 3)

The method of claim 3, wherein adding the new partition to a next generation in the set of generations of the dataset includes associating the new partition with metadata that represents the clean time and generation information of the new partition.

### Claim 6 (depends on 1)

The method of claim 1, wherein the scrubbing process is associated with at least one of the accumulated modification and deletion events.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
determining whether the oldest partition reached the end of a retention period for the dataset by:
determining whether the oldest partition has reached the maximum age in the triggered generation and the triggered generation is a last generation in the set of generations.

### Claim 8 (depends on 1)

The method of claim 1, wherein for each of the accumulated modification and deletion events:
identifying one or more partitions containing data associated with the event;
generating one or more respective scrubbing tasks for modifying the data in the one or more partitions; and
executing the respective scrubbing tasks on a schedule based on a rolling window of partition scrubbing.

### Claim 9 (depends on 1)

The method of claim 1, wherein responsive to a subsequent triggering event:
determining that a problem has occurred in creating a subsequent new partition corresponding to a current oldest partition; and
performing a partition roll back on the current oldest partition to restore the data prior to creating the subsequent new partition.

### Claim 10

One or more non-transitory computer storage media encoded with instructions that, when executed by one or more computers, cause the one or more computers to perform operations for data retention and modification, according to a retention policy, of a distributed dataset stored in partitions comprising:
dividing the partitions into an ordered set of generations according to the retention policy;
accumulating modification and deletion events that define changes to be applied to data of the distributed dataset; and
when a triggering event occurs for a triggered generation in the set of generations, rolling an oldest partition out of the triggered generation, the rolling comprising:
if the oldest partition has reached the end of a retention period for the dataset, marking the oldest partition for deletion in the triggered generation;
otherwise:
creating a new partition corresponding to the data of the oldest partition, wherein the data is cleaned using a scrubbing process based on the defined changes to be applied to data in the oldest partition;
adding the new partition to a next generation in the ordered set of generations of the dataset; and
marking the oldest partition for deletion in the triggered generation.

### Claim 11 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein the set of generations includes a number of generations determined based on an overall retention period of the dataset and an active size of a generation.

### Claim 12 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein marking the oldest partition for deletion includes marking the oldest partition inactive in the generation for a time period limited by a specified deletion period.

### Claim 13 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein dividing the dataset partitions into the set of generations structures includes associating each dataset partition with metadata that includes generation information and information about when the dataset partition was created.

### Claim 14 (depends on 13)

The one or more non-transitory computer storage media of claim 13, wherein adding the new partition to a next generation in the set of generations of the dataset includes associating the new partition with metadata that represents the clean time and generation information of the new partition.

### Claim 15 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein the scrubbing process is associated with at least one of the accumulated modification and deletion events.

### Claim 16 (depends on 10)

The one or more non-transitory computer storage media of claim 10, further comprising instructions that, when executed, cause the one or more computers to perform operations comprising:
determining whether the oldest partition reached the end of a retention period for the dataset by:
determining whether the oldest partition has reached the maximum age in the triggered generation and the triggered generation is a last generation in the set of generations.

### Claim 17 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein for each of the accumulated modification and deletion events:
identifying one or more partitions containing data associated with the event;
generating one or more respective scrubbing tasks for modifying the data in the one or more partitions; and
executing the respective scrubbing tasks on a schedule based on a rolling window of partition scrubbing.

### Claim 18 (depends on 10)

The one or more non-transitory computer storage media of claim 10, wherein responsive to a subsequent triggering event:
determining that a problem has occurred in creating a subsequent new partition corresponding to a current oldest partition; and
performing a partition roll back on the current oldest partition to restore the data prior to creating the subsequent new partition.

### Claim 19

A system comprising:
one or more computers and one or more storage devices storing instructions that are operable, when executed by the one or more computers, to cause the one or more computers to perform operations for data retention and modification, according to a retention policy, of a distributed dataset stored in partitions comprising:
dividing the partitions into an ordered set of generations according to the retention policy;
accumulating modification and deletion events that define changes to be applied to data of the distributed dataset; and
when a triggering event occurs for a triggered generation in the set of generations, rolling an oldest partition out of the triggered generation, the rolling comprising:
if the oldest partition has reached the end of a retention period for the dataset, marking the oldest partition for deletion in the triggered generation;
otherwise:
creating a new partition corresponding to the data of the oldest partition, wherein the data is cleaned using a scrubbing process based on the defined changes to be applied to data in the oldest partition;
adding the new partition to a next generation in the ordered set of generations of the dataset; and
marking the oldest partition for deletion in the triggered generation.

### Claim 20 (depends on 19)

The system of claim 19, wherein the set of generations includes a number of generations determined based on an overall retention period of the dataset and an active size of a generation.

### Claim 21 (depends on 19)

The system of claim 19, wherein marking the oldest partition for deletion includes marking the oldest partition inactive in the generation for a time period limited by a specified deletion period.

### Claim 22 (depends on 19)

The system of claim 19, wherein dividing the dataset partitions into the set of generations structures includes associating each dataset partition with metadata that includes generation information and information about when the dataset partition was created.

### Claim 23 (depends on 22)

The system of claim 22, wherein adding the new partition to a next generation in the set of generations of the dataset includes associating the new partition with metadata that represents the clean time and generation information of the new partition.

### Claim 24 (depends on 19)

The system of claim 19, wherein the scrubbing process is associated with at least one of the accumulated modification and deletion events.

### Claim 25 (depends on 19)

The system of claim 19, further storing instructions that are operable to cause the one or more computers to perform operations comprising:
determining whether the oldest partition reached the end of a retention period for the dataset by:
determining whether the oldest partition has reached the maximum age in the triggered generation and the triggered generation is a last generation in the set of generations.

### Claim 26 (depends on 19)

The system of claim 19, wherein for each of the accumulated modification and deletion events:
identifying one or more partitions containing data associated with the event;
generating one or more respective scrubbing tasks for modifying the data in the one or more partitions; and
executing the respective scrubbing tasks on a schedule based on a rolling window of partition scrubbing.

### Claim 27 (depends on 19)

The system of claim 19, wherein responsive to a subsequent triggering event:
determining that a problem has occurred in creating a subsequent new partition corresponding to a current oldest partition; and
performing a partition roll back on the oldest partition to restore the data prior to creating the subsequent new partition.
