wfu-migrate 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. package/README.md +199 -0
  2. package/dist/commands/cleanup.d.ts +10 -0
  3. package/dist/commands/cleanup.d.ts.map +1 -0
  4. package/dist/commands/cleanup.js +231 -0
  5. package/dist/commands/cleanup.js.map +1 -0
  6. package/dist/commands/config.d.ts +15 -0
  7. package/dist/commands/config.d.ts.map +1 -0
  8. package/dist/commands/config.js +285 -0
  9. package/dist/commands/config.js.map +1 -0
  10. package/dist/commands/doctor.d.ts +15 -0
  11. package/dist/commands/doctor.d.ts.map +1 -0
  12. package/dist/commands/doctor.js +234 -0
  13. package/dist/commands/doctor.js.map +1 -0
  14. package/dist/commands/env-migrate.d.ts +37 -0
  15. package/dist/commands/env-migrate.d.ts.map +1 -0
  16. package/dist/commands/env-migrate.js +703 -0
  17. package/dist/commands/env-migrate.js.map +1 -0
  18. package/dist/commands/migrate.d.ts +19 -0
  19. package/dist/commands/migrate.d.ts.map +1 -0
  20. package/dist/commands/migrate.js +374 -0
  21. package/dist/commands/migrate.js.map +1 -0
  22. package/dist/index.d.ts +15 -0
  23. package/dist/index.d.ts.map +1 -0
  24. package/dist/index.js +31 -0
  25. package/dist/index.js.map +1 -0
  26. package/dist/lib/compress.d.ts +86 -0
  27. package/dist/lib/compress.d.ts.map +1 -0
  28. package/dist/lib/compress.js +203 -0
  29. package/dist/lib/compress.js.map +1 -0
  30. package/dist/lib/config-manager.d.ts +34 -0
  31. package/dist/lib/config-manager.d.ts.map +1 -0
  32. package/dist/lib/config-manager.js +332 -0
  33. package/dist/lib/config-manager.js.map +1 -0
  34. package/dist/lib/database.d.ts +460 -0
  35. package/dist/lib/database.d.ts.map +1 -0
  36. package/dist/lib/database.js +1267 -0
  37. package/dist/lib/database.js.map +1 -0
  38. package/dist/lib/docker.d.ts +240 -0
  39. package/dist/lib/docker.d.ts.map +1 -0
  40. package/dist/lib/docker.js +653 -0
  41. package/dist/lib/docker.js.map +1 -0
  42. package/dist/lib/health.d.ts +99 -0
  43. package/dist/lib/health.d.ts.map +1 -0
  44. package/dist/lib/health.js +139 -0
  45. package/dist/lib/health.js.map +1 -0
  46. package/dist/lib/logger.d.ts +105 -0
  47. package/dist/lib/logger.d.ts.map +1 -0
  48. package/dist/lib/logger.js +259 -0
  49. package/dist/lib/logger.js.map +1 -0
  50. package/dist/lib/migration-engine.d.ts +130 -0
  51. package/dist/lib/migration-engine.d.ts.map +1 -0
  52. package/dist/lib/migration-engine.js +1175 -0
  53. package/dist/lib/migration-engine.js.map +1 -0
  54. package/dist/lib/parallel.d.ts +85 -0
  55. package/dist/lib/parallel.d.ts.map +1 -0
  56. package/dist/lib/parallel.js +138 -0
  57. package/dist/lib/parallel.js.map +1 -0
  58. package/dist/lib/progress.d.ts +101 -0
  59. package/dist/lib/progress.d.ts.map +1 -0
  60. package/dist/lib/progress.js +179 -0
  61. package/dist/lib/progress.js.map +1 -0
  62. package/dist/lib/prompt.d.ts +71 -0
  63. package/dist/lib/prompt.d.ts.map +1 -0
  64. package/dist/lib/prompt.js +116 -0
  65. package/dist/lib/prompt.js.map +1 -0
  66. package/dist/lib/retry.d.ts +61 -0
  67. package/dist/lib/retry.d.ts.map +1 -0
  68. package/dist/lib/retry.js +136 -0
  69. package/dist/lib/retry.js.map +1 -0
  70. package/dist/lib/s3.d.ts +238 -0
  71. package/dist/lib/s3.d.ts.map +1 -0
  72. package/dist/lib/s3.js +507 -0
  73. package/dist/lib/s3.js.map +1 -0
  74. package/dist/lib/serialized.d.ts +114 -0
  75. package/dist/lib/serialized.d.ts.map +1 -0
  76. package/dist/lib/serialized.js +236 -0
  77. package/dist/lib/serialized.js.map +1 -0
  78. package/dist/lib/shutdown.d.ts +78 -0
  79. package/dist/lib/shutdown.d.ts.map +1 -0
  80. package/dist/lib/shutdown.js +153 -0
  81. package/dist/lib/shutdown.js.map +1 -0
  82. package/dist/lib/site-filter.d.ts +98 -0
  83. package/dist/lib/site-filter.d.ts.map +1 -0
  84. package/dist/lib/site-filter.js +213 -0
  85. package/dist/lib/site-filter.js.map +1 -0
  86. package/dist/lib/spinner.d.ts +174 -0
  87. package/dist/lib/spinner.d.ts.map +1 -0
  88. package/dist/lib/spinner.js +273 -0
  89. package/dist/lib/spinner.js.map +1 -0
  90. package/dist/lib/state.d.ts +363 -0
  91. package/dist/lib/state.d.ts.map +1 -0
  92. package/dist/lib/state.js +905 -0
  93. package/dist/lib/state.js.map +1 -0
  94. package/dist/lib/system.d.ts +227 -0
  95. package/dist/lib/system.d.ts.map +1 -0
  96. package/dist/lib/system.js +636 -0
  97. package/dist/lib/system.js.map +1 -0
  98. package/dist/lib/url-patterns.d.ts +46 -0
  99. package/dist/lib/url-patterns.d.ts.map +1 -0
  100. package/dist/lib/url-patterns.js +259 -0
  101. package/dist/lib/url-patterns.js.map +1 -0
  102. package/dist/lib/wp-tables.d.ts +139 -0
  103. package/dist/lib/wp-tables.d.ts.map +1 -0
  104. package/dist/lib/wp-tables.js +296 -0
  105. package/dist/lib/wp-tables.js.map +1 -0
  106. package/dist/types/index.d.ts +96 -0
  107. package/dist/types/index.d.ts.map +1 -0
  108. package/dist/types/index.js +46 -0
  109. package/dist/types/index.js.map +1 -0
  110. package/package.json +58 -0
@@ -0,0 +1,363 @@
1
+ /**
2
+ * State management for WFU-Migrate
3
+ *
4
+ * Tracks migration state for resume capability:
5
+ * - Migration ID, source/target environments
6
+ * - Phase tracking (preflight, network, sites, s3sync, cleanup)
7
+ * - Per-site status (pending, in_progress, completed, failed, timeout)
8
+ * - Counters (total, completed, failed, timeout)
9
+ *
10
+ * File locking:
11
+ * - Uses a .lock file to prevent concurrent modifications
12
+ * - Lock contains PID and timestamp for debugging
13
+ * - Stale locks (>30 min) are automatically cleared
14
+ */
15
+ export interface LockInfo {
16
+ pid: number;
17
+ timestamp: string;
18
+ hostname: string;
19
+ }
20
+ export interface LockResult {
21
+ acquired: boolean;
22
+ error?: string;
23
+ existingLock?: LockInfo;
24
+ }
25
+ export type MigrationPhase = 'preflight' | 'network' | 'sites' | 's3sync' | 'cleanup' | 'completed' | 'failed';
26
+ export type SiteStatus = 'pending' | 'in_progress' | 'completed' | 'failed' | 'timeout' | 'skipped';
27
+ export interface SiteMigrationState {
28
+ siteId: number;
29
+ status: SiteStatus;
30
+ domain?: string;
31
+ startTime?: string;
32
+ endTime?: string;
33
+ error?: string;
34
+ retryCount: number;
35
+ }
36
+ export interface MigrationState {
37
+ id: string;
38
+ source: string;
39
+ target: string;
40
+ status: 'pending' | 'in_progress' | 'completed' | 'failed';
41
+ phase: MigrationPhase;
42
+ sites: SiteMigrationState[];
43
+ counters: {
44
+ total: number;
45
+ completed: number;
46
+ failed: number;
47
+ timeout: number;
48
+ skipped: number;
49
+ };
50
+ startTime: string;
51
+ lastUpdate: string;
52
+ options: {
53
+ networkOnly: boolean;
54
+ sitesOnly: boolean;
55
+ parallel: boolean;
56
+ batchSize: number;
57
+ concurrency: number;
58
+ autoRollback: boolean;
59
+ };
60
+ }
61
+ /**
62
+ * Acquire a lock for a migration state file.
63
+ * Returns success if lock is acquired, or error with details if not.
64
+ */
65
+ export declare function acquireLock(migrationId: string): LockResult;
66
+ /**
67
+ * Release a lock for a migration state file.
68
+ */
69
+ export declare function releaseLock(migrationId: string): void;
70
+ /**
71
+ * Check if a migration state file is currently locked.
72
+ */
73
+ export declare function isLocked(migrationId: string): boolean;
74
+ /**
75
+ * Get lock information for a migration.
76
+ */
77
+ export declare function getLockInfo(migrationId: string): LockInfo | null;
78
+ export declare function generateMigrationId(): string;
79
+ export declare function createMigrationState(source: string, target: string, options: MigrationState['options']): MigrationState;
80
+ export declare function saveMigrationState(state: MigrationState): void;
81
+ export declare function loadMigrationState(migrationId: string): MigrationState | null;
82
+ export declare function listIncompleteMigrations(): MigrationState[];
83
+ export declare function updateSiteStatus(state: MigrationState, siteId: number, status: SiteStatus, error?: string): void;
84
+ export declare function formatMigrationSummary(state: MigrationState): string;
85
+ /**
86
+ * Check if a migration can be resumed.
87
+ * A migration can be resumed if:
88
+ * - It exists and is not completed
89
+ * - It has pending, in_progress, or failed sites
90
+ * - It is not currently locked by another process
91
+ */
92
+ export declare function canResumeMigration(migrationId: string): boolean;
93
+ /**
94
+ * Get sites that are eligible for processing on resume.
95
+ * Returns sites with status: pending, in_progress, or failed.
96
+ * Excludes completed, timeout, and skipped sites.
97
+ */
98
+ export declare function getPendingSites(state: MigrationState): SiteMigrationState[];
99
+ /**
100
+ * Get site IDs that need processing on resume.
101
+ */
102
+ export declare function getPendingSiteIds(state: MigrationState): number[];
103
+ /**
104
+ * Check if a site was already completed successfully.
105
+ */
106
+ export declare function isSiteCompleted(state: MigrationState, siteId: number): boolean;
107
+ /**
108
+ * Reset a site to pending status for retry.
109
+ * Increments the retry count and clears previous error.
110
+ */
111
+ export declare function resetSiteForRetry(state: MigrationState, siteId: number): void;
112
+ /**
113
+ * Prepare state for resume by resetting in_progress sites to pending.
114
+ * This is called when resuming a migration that was interrupted.
115
+ * Sites that were in_progress are assumed to have failed and need retry.
116
+ */
117
+ export declare function prepareStateForResume(state: MigrationState): void;
118
+ /**
119
+ * Get count of remaining sites to process.
120
+ */
121
+ export declare function getRemainingCount(state: MigrationState): number;
122
+ /**
123
+ * Get failed sites for potential retry.
124
+ */
125
+ export declare function getFailedSites(state: MigrationState): SiteMigrationState[];
126
+ /**
127
+ * Get completed sites.
128
+ */
129
+ export declare function getCompletedSites(state: MigrationState): SiteMigrationState[];
130
+ /**
131
+ * Check if all sites are processed (completed, failed, timeout, or skipped).
132
+ */
133
+ export declare function isAllSitesProcessed(state: MigrationState): boolean;
134
+ /**
135
+ * Calculate completion percentage for a migration.
136
+ */
137
+ export declare function getCompletionPercentage(state: MigrationState): number;
138
+ /**
139
+ * Mark all failed sites as skipped.
140
+ * Used with --skip-failed flag to skip previously failed sites on resume.
141
+ * Updates the counters accordingly (decrement failed, increment skipped).
142
+ */
143
+ export declare function skipFailedSites(state: MigrationState): number;
144
+ /**
145
+ * Get sites that should be processed when resuming.
146
+ * Excludes failed sites if skipFailed is true.
147
+ */
148
+ export declare function getSitesToProcess(state: MigrationState, options?: {
149
+ skipFailed?: boolean;
150
+ }): SiteMigrationState[];
151
+ /**
152
+ * Get site IDs that should be processed when resuming.
153
+ * Excludes failed sites if skipFailed is true.
154
+ */
155
+ export declare function getSiteIdsToProcess(state: MigrationState, options?: {
156
+ skipFailed?: boolean;
157
+ }): number[];
158
+ /**
159
+ * Prepare state for resume with skip-failed option.
160
+ * Marks failed sites as skipped and resets in_progress sites.
161
+ */
162
+ export declare function prepareStateForResumeWithSkipFailed(state: MigrationState): number;
163
+ /**
164
+ * Get only failed sites for retry.
165
+ * Used with --retry-failed flag to retry only failed sites.
166
+ */
167
+ export declare function getFailedSitesForRetry(state: MigrationState): SiteMigrationState[];
168
+ /**
169
+ * Get site IDs that failed and need retry.
170
+ */
171
+ export declare function getFailedSiteIdsForRetry(state: MigrationState): number[];
172
+ /**
173
+ * Reset failed sites for retry.
174
+ * Sets failed sites back to pending status for re-processing.
175
+ * Increments retry count and clears error messages.
176
+ */
177
+ export declare function resetFailedSitesForRetry(state: MigrationState): number;
178
+ /**
179
+ * Prepare state for retry-failed mode.
180
+ * Only failed sites are reset for retry.
181
+ * Completed, skipped, and timeout sites remain unchanged.
182
+ * In-progress sites are kept (assumed to be from concurrent operation).
183
+ */
184
+ export declare function prepareStateForRetryFailed(state: MigrationState): number;
185
+ /**
186
+ * Check if retry-failed mode is applicable.
187
+ * Returns true if there are failed sites to retry.
188
+ */
189
+ export declare function canRetryFailed(state: MigrationState): boolean;
190
+ export interface RollbackInfo {
191
+ siteId: number;
192
+ backupFile?: string;
193
+ targetBucket?: string;
194
+ timestamp: string;
195
+ }
196
+ /**
197
+ * Track backup info for potential rollback.
198
+ * Stored per-site so individual sites can be rolled back.
199
+ */
200
+ export declare function registerBackupForRollback(state: MigrationState, siteId: number, backupFile: string, targetBucket?: string): void;
201
+ /**
202
+ * Get rollback info for a site.
203
+ */
204
+ export declare function getRollbackInfo(state: MigrationState, siteId: number): RollbackInfo | undefined;
205
+ /**
206
+ * Check if auto-rollback is enabled for this migration.
207
+ */
208
+ export declare function isAutoRollbackEnabled(state: MigrationState): boolean;
209
+ /**
210
+ * Get sites that need rollback (failed sites with backup info).
211
+ */
212
+ export declare function getSitesForRollback(state: MigrationState): SiteMigrationState[];
213
+ /**
214
+ * Get site IDs that need rollback.
215
+ */
216
+ export declare function getSiteIdsForRollback(state: MigrationState): number[];
217
+ /**
218
+ * Mark a site as rolled back.
219
+ * Sets status to 'skipped' with rollback note.
220
+ */
221
+ export declare function markSiteRolledBack(state: MigrationState, siteId: number): void;
222
+ /**
223
+ * Check if rollback is possible for a migration.
224
+ * Returns true if there are failed sites with backup info.
225
+ */
226
+ export declare function canRollback(state: MigrationState): boolean;
227
+ /**
228
+ * Get rollback summary for display.
229
+ */
230
+ export declare function getRollbackSummary(state: MigrationState): {
231
+ sitesWithBackup: number;
232
+ sitesWithoutBackup: number;
233
+ totalFailed: number;
234
+ };
235
+ export declare const DEFAULT_MAX_RETRIES = 3;
236
+ /**
237
+ * Check if a site has exceeded max retries.
238
+ */
239
+ export declare function hasExceededMaxRetries(state: MigrationState, siteId: number, maxRetries?: number): boolean;
240
+ /**
241
+ * Get retry count for a site.
242
+ */
243
+ export declare function getRetryCount(state: MigrationState, siteId: number): number;
244
+ /**
245
+ * Check if a site can be retried.
246
+ * Returns false if max retries exceeded or site not found.
247
+ */
248
+ export declare function canRetrySite(state: MigrationState, siteId: number, maxRetries?: number): boolean;
249
+ /**
250
+ * Mark site as timed out when max retries exceeded.
251
+ */
252
+ export declare function markSiteMaxRetriesExceeded(state: MigrationState, siteId: number): void;
253
+ /**
254
+ * Get sites that have exceeded max retries.
255
+ */
256
+ export declare function getSitesExceedingMaxRetries(state: MigrationState, maxRetries?: number): SiteMigrationState[];
257
+ /**
258
+ * Get sites eligible for retry (failed but under max retries).
259
+ */
260
+ export declare function getSitesEligibleForRetry(state: MigrationState, maxRetries?: number): SiteMigrationState[];
261
+ /**
262
+ * Mark all sites exceeding max retries as timeout.
263
+ */
264
+ export declare function markAllExceededAsTimeout(state: MigrationState, maxRetries?: number): number;
265
+ /**
266
+ * Reset site for retry if under max retries.
267
+ * Returns true if reset, false if max retries exceeded.
268
+ */
269
+ export declare function resetSiteIfUnderMaxRetries(state: MigrationState, siteId: number, maxRetries?: number): boolean;
270
+ /**
271
+ * Get retry statistics for the migration.
272
+ */
273
+ export declare function getRetryStats(state: MigrationState): {
274
+ totalRetries: number;
275
+ sitesWithRetries: number;
276
+ avgRetriesPerSite: number;
277
+ };
278
+ /**
279
+ * List completed migrations that can be cleaned up.
280
+ */
281
+ export declare function listCompletedMigrations(): MigrationState[];
282
+ /**
283
+ * Delete a migration state from disk.
284
+ * Use with caution - this permanently removes the state file.
285
+ */
286
+ export declare function deleteMigrationState(migrationId: string): {
287
+ success: boolean;
288
+ error?: string;
289
+ };
290
+ /**
291
+ * Clean up completed migrations older than specified age (in days).
292
+ * Returns count of deleted migrations.
293
+ */
294
+ export declare function cleanupCompletedMigrations(olderThanDays?: number): {
295
+ deleted: number;
296
+ errors: string[];
297
+ };
298
+ /**
299
+ * Environment-level locking to prevent concurrent migrations to the same target.
300
+ *
301
+ * Multiple migrations can run concurrently as long as they target different environments.
302
+ * This prevents data corruption from parallel writes to the same database/storage.
303
+ */
304
+ export interface EnvironmentLockInfo {
305
+ pid: number;
306
+ timestamp: string;
307
+ hostname: string;
308
+ migrationId: string;
309
+ source: string;
310
+ }
311
+ export interface EnvironmentLockResult {
312
+ acquired: boolean;
313
+ error?: string;
314
+ existingLock?: EnvironmentLockInfo;
315
+ }
316
+ /**
317
+ * Acquire a lock for a target environment.
318
+ * Prevents concurrent migrations to the same target.
319
+ */
320
+ export declare function acquireEnvironmentLock(environment: string, migrationId: string, source: string): EnvironmentLockResult;
321
+ /**
322
+ * Release environment lock.
323
+ * Only releases if current process owns the lock.
324
+ */
325
+ export declare function releaseEnvironmentLock(environment: string, migrationId: string): void;
326
+ /**
327
+ * Check if an environment is currently locked.
328
+ */
329
+ export declare function isEnvironmentLocked(environment: string): boolean;
330
+ /**
331
+ * Get environment lock information.
332
+ */
333
+ export declare function getEnvironmentLockInfo(environment: string): EnvironmentLockInfo | null;
334
+ /**
335
+ * Check if current process owns the environment lock.
336
+ */
337
+ export declare function ownsEnvironmentLock(environment: string, migrationId: string): boolean;
338
+ /**
339
+ * Format a user-friendly error message for environment lock conflicts.
340
+ */
341
+ export declare function formatEnvironmentLockError(lockInfo: EnvironmentLockInfo, environment: string): string;
342
+ /**
343
+ * List all active environment locks.
344
+ */
345
+ export declare function listEnvironmentLocks(): Array<{
346
+ environment: string;
347
+ info: EnvironmentLockInfo;
348
+ }>;
349
+ /**
350
+ * Clean up stale environment locks.
351
+ * Removes locks that have exceeded the timeout.
352
+ */
353
+ export declare function cleanupStaleEnvironmentLocks(): number;
354
+ /**
355
+ * Check if a migration can start to a target environment.
356
+ * Returns result with explanation if rejected.
357
+ */
358
+ export declare function canStartMigration(target: string): {
359
+ allowed: boolean;
360
+ reason?: string;
361
+ lockInfo?: EnvironmentLockInfo;
362
+ };
363
+ //# sourceMappingURL=state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../src/lib/state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAUH,MAAM,WAAW,QAAQ;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,QAAQ,CAAC;CACzB;AAED,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,GAAG,WAAW,GAAG,QAA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