Skip to content

Commit 67c1dcd

Browse files
Drop run-summary JSON visibility columns
Drop run-summary JSON visibility columns
1 parent b9c9b99 commit 67c1dcd

9 files changed

Lines changed: 8 additions & 24 deletions

docs/search-attributes-architecture.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -326,8 +326,6 @@ is no separate v2-alpha cutover surface to preserve.
326326
Required cleanup before v2.0 stable:
327327

328328
- runtime stops dual-writing the JSON column from `WorkflowExecutor`
329-
- runtime stops dual-reading the JSON column as a fallback in
330-
`WorkflowRunSummary` and other projections
331329
- the `workflow_runs.search_attributes` column is dropped from the
332330
`create_workflow_runs_table` migration
333331
- this document and `docs/workflow-memos-architecture.md` describe the

docs/workflow-memos-architecture.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -255,8 +255,6 @@ is no separate v2-alpha cutover surface to preserve.
255255
Required cleanup before v2.0 stable:
256256

257257
- runtime stops dual-writing the JSON column from `WorkflowExecutor`
258-
- runtime stops dual-reading the JSON column as a fallback in
259-
`WorkflowRunSummary::getMemos()` and other projections
260258
- the `workflow_runs.memo` column is dropped from the
261259
`create_workflow_runs_table` migration
262260
- this document and `docs/search-attributes-architecture.md` describe

src/V2/Support/RunSummaryProjector.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,6 @@ public static function project(WorkflowRun $run): WorkflowRunSummary
318318
'namespace' => $run->namespace ?? $run->instance?->namespace,
319319
'business_key' => $run->business_key ?? $run->instance?->business_key,
320320
'visibility_labels' => $run->visibility_labels ?? $run->instance?->visibility_labels,
321-
'search_attributes' => $run->search_attributes,
322321
'compatibility' => $run->compatibility,
323322
'declared_entry_mode' => $commandContract['entry_mode'],
324323
'declared_contract_source' => $commandContract['source'],

src/migrations/2026_04_05_000106_create_workflow_run_summaries_table.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,6 @@ public function up(): void
5252
->index('workflow_run_summaries_business_key_index');
5353
$table->json('visibility_labels')
5454
->nullable();
55-
$table->json('memo')
56-
->nullable();
57-
$table->json('search_attributes')
58-
->nullable();
5955

6056
// Execution status
6157
$table->string('status')

tests/Unit/Providers/WorkflowServiceProviderTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,8 @@ public function testProviderLoadsPackageMigrationsForFreshApps(): void
190190
$this->assertTrue(Schema::hasTable('workflow_instances'));
191191
$this->assertTrue(Schema::hasTable('workflow_runs'));
192192
$this->assertTrue(Schema::hasTable('workflow_run_summaries'));
193-
$this->assertTrue(Schema::hasColumn('workflow_run_summaries', 'memo'));
193+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'memo'));
194+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'search_attributes'));
194195
$this->assertTrue(Schema::hasTable('workflow_commands'));
195196
}
196197

@@ -220,7 +221,8 @@ public function testPublishedMigrationsCanRunAsInstallSource(): void
220221
$this->assertTrue(Schema::hasTable('workflow_instances'));
221222
$this->assertTrue(Schema::hasTable('workflow_runs'));
222223
$this->assertTrue(Schema::hasTable('workflow_run_summaries'));
223-
$this->assertTrue(Schema::hasColumn('workflow_run_summaries', 'memo'));
224+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'memo'));
225+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'search_attributes'));
224226
$this->assertTrue(Schema::hasTable('workflow_schedules'));
225227
$this->assertTrue(Schema::hasTable('workflow_schedule_history_events'));
226228
} finally {

tests/Unit/V2/VisibilityFiltersTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,6 @@ private function createSearchAttributeSummary(string $runId, string $instanceId,
728728
'engine_source' => 'v2',
729729
'class' => 'BillingWorkflow',
730730
'workflow_type' => 'billing.invoice-sync',
731-
'search_attributes' => $searchAttributes,
732731
'status' => 'running',
733732
'status_bucket' => 'running',
734733
]);

tests/Unit/V2/VisibilityMetadataContractDocumentationTest.php

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ public function testSearchAttributesDocNamesRequiredCleanupSurfaces(): void
9797
{
9898
$contents = $this->documentContents(self::SEARCH_ATTRIBUTES_DOCUMENT);
9999

100-
foreach (['WorkflowExecutor', 'WorkflowRunSummary', 'create_workflow_runs_table'] as $surface) {
100+
foreach (['WorkflowExecutor', 'create_workflow_runs_table'] as $surface) {
101101
$this->assertStringContainsString(
102102
$surface,
103103
$contents,
@@ -113,11 +113,7 @@ public function testMemosDocNamesRequiredCleanupSurfaces(): void
113113
{
114114
$contents = $this->documentContents(self::MEMOS_DOCUMENT);
115115

116-
foreach ([
117-
'WorkflowExecutor',
118-
'WorkflowRunSummary::getMemos()',
119-
'create_workflow_runs_table',
120-
] as $surface) {
116+
foreach (['WorkflowExecutor', 'create_workflow_runs_table'] as $surface) {
121117
$this->assertStringContainsString(
122118
$surface,
123119
$contents,

tests/Unit/V2/WorkflowRunVisibilityMetadataAccessorsTest.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,6 @@ public function testSummaryPropertiesPreferTypedVisibilityRows(): void
7575
'projection_schema_version' => 1,
7676
'class' => $run->workflow_class,
7777
'workflow_type' => $run->workflow_type,
78-
'memo' => [
79-
'legacy' => 'json',
80-
],
81-
'search_attributes' => [
82-
'legacy' => 'json',
83-
],
8478
'status' => $run->status->value,
8579
'status_bucket' => $statusBucket->value,
8680
]);

tests/Unit/migrations/MigrationsTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,8 @@ public function testDownMethodsDropTables(): void
193193
$this->assertTrue(Schema::hasColumn('workflow_run_summaries', 'task_problem'));
194194
$this->assertTrue(Schema::hasColumn('workflow_run_summaries', 'declared_entry_mode'));
195195
$this->assertTrue(Schema::hasColumn('workflow_run_summaries', 'declared_contract_source'));
196+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'memo'));
197+
$this->assertFalse(Schema::hasColumn('workflow_run_summaries', 'search_attributes'));
196198
$this->assertTrue(Schema::hasColumn('workflow_links', 'sequence'));
197199
$this->assertTrue(Schema::hasColumn('workflow_tasks', 'last_dispatch_attempt_at'));
198200
$this->assertTrue(Schema::hasColumn('workflow_tasks', 'last_dispatch_error'));

0 commit comments

Comments
 (0)