Migration_Service
Migration Service class.
Namespace: WebberZone\Contextual_Related_Posts\Util
Since: 4.2.0
Source: includes/util/class-migration-service.php line 21
Methods
get_status() static
Get migration status information.
Since: 4.2.0
Line: 37
static public function get_status( ): array;
Returns: array — Migration status.
migrate_batch() static
Migrate a batch of meta entries from crp_post_meta array to individual crp* keys.
Since: 4.2.0
Line: 64
static public function migrate_batch( int $last_id = ..., int $batch_size = ..., bool $dry_run = ... ): array;
| Type | Name | Description |
|---|---|---|
int | $last_id | Last processed meta_id. |
int | $batch_size | Number of entries to process. |
bool | $dry_run | Whether this is a dry run. |
Returns: array — Migration results.
rollback_batch() static
Rollback a batch of meta entries from individual crp* keys back to crp_post_meta array.
Since: 4.2.0
Line: 149
static public function rollback_batch( int $last_id = ..., int $batch_size = ..., bool $dry_run = ... ): array;
| Type | Name | Description |
|---|---|---|
int | $last_id | Last processed post_id. |
int | $batch_size | Number of posts to process. |
bool | $dry_run | Whether this is a dry run. |
Returns: array — Rollback results.