Skip to content

Commit

Permalink
Standardize the cached results to match action results
Browse files Browse the repository at this point in the history
  • Loading branch information
Mythicaeda committed Sep 27, 2023
1 parent 50d69e6 commit 62e20de
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ static JsonParser<SpansSelectWhenTrue> spansSelectWhenTrueF(JsonParser<Expressio

public static final JsonParser<Violation> violationP =
productP
.field("violationWindows", listP(intervalP))
.field("windows", listP(intervalP))
.field("activityInstanceIds", listP(longP))
.map(
untuple(Violation::new),
Expand All @@ -310,8 +310,8 @@ static JsonParser<SpansSelectWhenTrue> spansSelectWhenTrueF(JsonParser<Expressio
productP
.field("violations", listP(violationP))
.field("gaps", listP(intervalP))
.field("constraintType", enumP(ConstraintType.class, Enum::name))
.field("resourceNames", listP(stringP))
.field("type", enumP(ConstraintType.class, Enum::name))
.field("resourceIds", listP(stringP))
.field("constraintId", longP)
.field("constraintName", stringP)
.map(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-- The JSON schema of the constraint violations in constraint_run is changed.
-- Because the table is a cache it is safer to clear it than to attempt to transform it using SQL
truncate constraint_run;
call migrations.mark_migration_rolled_back('29');
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-- The JSON schema of the constraint violations in constraint_run is changed.
-- Because the table is a cache it is safer to clear it than to attempt to transform it using SQL
truncate constraint_run;
call migrations.mark_migration_applied('29');
1 change: 1 addition & 0 deletions merlin-server/sql/merlin/applied_migrations.sql
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,4 @@ call migrations.mark_migration_applied('25');
call migrations.mark_migration_applied('26');
call migrations.mark_migration_applied('27');
call migrations.mark_migration_applied('28');
call migrations.mark_migration_applied('29');

0 comments on commit 62e20de

Please sign in to comment.