Database rotation
- UpdatedFeb 1, 2024
- 2 minutes to read
- Washington DC
- Data Management
The Washington DC release is no longer supported. As such, the product documentation and release notes are provided for informational purposes only, and will not be updated.
Database rotation involves managing table size growth and archiving old data.
Data within an instance grows quickly, and as these tables grow in size they require
management. Database Rotation preserves instance performance and averts risk associated
with querying growing data sets utilizing three techniques. These techniques are based on the
concept of managing large quantities of data by separating whole sets into individual tables.
After this task is performed, each technique handles data in a different manner:
- Table Rotation works by rotating among a small set of tables, and deleting and reusing the old tables for new data.
- Table Extension works by periodically starting a new table and allowing old tables to be easily archived and removed from the system.
- Table Sharding works by enabling records to be grouped in a single table by document ID.
Table rotation plugins
- Database Rotations Plugin activates Table Rotation and Extension without any tables automatically included (com.snc.db.rotation)
- Database Rotations Default Tables Plugin applies Table Rotation and Extension to specific tables (com.snc.db.rotation_default_tables)
| Functionality | Tables applied to |
|---|---|
| Table Rotation | syslog
|
| Table Extension |
|
Table rotation and extension
The System Definition Table Rotation module allows you to define a new table rotation, a new table extension, a new table shard, or modify an existing one.
- Name: auto-generated from table name
- Duration: overall time parameter for function
- Initialized: sets function as active (true) or inactive (false)
- Rotations: number of tables to be created within Duration
- Type: indicates Extension (archiving), Rotation (deletion), or Shard (doc ID) functionality
When you define a new rotation, a schedule is created and new data is subsequently written to one of the tables in the rotation group. You will notice the that the group includes the original table plus a number of additional tables. Be aware that deleting a rotation will delete the additional tables and all the data, therefore the rotation should not be deleted if the data is needed.
See these topics for more information on managing tables: