Developer Docs - Developer Codex - Post-Update / Rock Update Helper (For Migrating Data)

Also known internally as a “Run Once Job”, this job performs data moving as necessary for a particular Rock update/release.

When you have the need to migrate data but cannot do it in a regular EF migration or Hotfix/Plugin data migration (possibly due to the length of time it takes to run), you can create a custom job that will run after Rock starts.

RockMigrationHelper.AddPostUpdateServiceJob( 
                name: "Rock Update Helper v15.2 - Replace WebForms Blocks with Obsidian Blocks",
                description: "This job will replace WebForms blocks with their Obsidian blocks on all sites, pages, and layouts.",
                jobType: FullyQualifiedJobClassName,
                cronExpression: "0 0 21 1/1 * ? *",
                guid: Rock.SystemGuid.ServiceJob.DATA_MIGRATIONS_152_REPLACE_WEB_FORMS_BLOCKS_WITH_OBSIDIAN_BLOCKS
            );