feat: meter AI usage
CI and Deploy / test (push) Failing after 58s
CI and Deploy / deploy (push) Has been skipped

This commit is contained in:
cesnimda
2026-07-30 22:39:24 +02:00
parent f8466c2ebc
commit c08232b9d7
15 changed files with 2482 additions and 11 deletions
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,23 @@
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace JobTrackerApi.Migrations
{
/// <inheritdoc />
public partial class AddAiUsageMetering : Migration
{
// Intentionally a no-op: StartupInitializationExtensions owns idempotent SQLite/MariaDB
// column reconciliation and runs before EF migrations. The snapshot records the model change;
// the reconciler performs the provider-safe DDL without duplicate-column failures.
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
}
}
}
@@ -26,6 +26,12 @@ namespace JobTrackerApi.Migrations
b.Property<DateTimeOffset>("CreatedAtUtc")
.HasColumnType("TEXT");
b.Property<int>("EstimatedTokenCount")
.HasColumnType("INTEGER");
b.Property<int>("InputCharacterCount")
.HasColumnType("INTEGER");
b.Property<int>("JobApplicationId")
.HasColumnType("INTEGER");
@@ -37,6 +43,9 @@ namespace JobTrackerApi.Migrations
.HasMaxLength(64)
.HasColumnType("TEXT");
b.Property<int>("OutputCharacterCount")
.HasColumnType("INTEGER");
b.Property<string>("OwnerUserId")
.IsRequired()
.HasMaxLength(255)