feat(inbound-api): ApiMethod.TraceAllCalls (entity, migration, mgmt command, CLI --trace-all-calls)
Flow Debugger (design 2026-09-05 §5.2): bit NOT NULL DEFAULT 0 column + EF migration 20260906034113 with its docs/plans/sql production twin. CreateApiMethodCommand gains TraceAllCalls=false; UpdateApiMethodCommand gains bool? TraceAllCalls (null = unchanged so an older CLI never resets it). Management result echoes the flag; CLI create/update expose --trace-all-calls; README carries the ~7-rows-per-call warning. Claude-Session: https://claude.ai/code/session_01GSLkkHKz9JrAtmJjmQK3cP
This commit is contained in:
+5
@@ -31,6 +31,11 @@ public class ApiMethodConfiguration : IEntityTypeConfiguration<ApiMethod>
|
||||
builder.Property(m => m.ReturnDefinition)
|
||||
.HasMaxLength(4000);
|
||||
|
||||
// Flow Debugger (design 2026-09-05 §5.2): bit NOT NULL DEFAULT 0.
|
||||
builder.Property(m => m.TraceAllCalls)
|
||||
.IsRequired()
|
||||
.HasDefaultValue(false);
|
||||
|
||||
builder.HasIndex(m => m.Name).IsUnique();
|
||||
}
|
||||
}
|
||||
|
||||
+2136
File diff suppressed because it is too large
Load Diff
+29
@@ -0,0 +1,29 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace ZB.MOM.WW.ScadaBridge.ConfigurationDatabase.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class AddApiMethodTraceAllCalls : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "TraceAllCalls",
|
||||
table: "ApiMethods",
|
||||
type: "bit",
|
||||
nullable: false,
|
||||
defaultValue: false);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "TraceAllCalls",
|
||||
table: "ApiMethods");
|
||||
}
|
||||
}
|
||||
}
|
||||
+5
@@ -511,6 +511,11 @@ namespace ZB.MOM.WW.ScadaBridge.ConfigurationDatabase.Migrations
|
||||
b.Property<int>("TimeoutSeconds")
|
||||
.HasColumnType("int");
|
||||
|
||||
b.Property<bool>("TraceAllCalls")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("bit")
|
||||
.HasDefaultValue(false);
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("Name")
|
||||
|
||||
Reference in New Issue
Block a user