DeepDrftAPI Rename

This commit is contained in:
Daniel Harvey
2026-05-25 10:38:36 -04:00
parent 98b2c8d744
commit 551cef0fe8
59 changed files with 510 additions and 524 deletions
@@ -62,7 +62,7 @@
</MudContainer>
@code {
// 1 GB ceiling matches DeepDrftContent's per-request limit on api/track/upload; the
// 1 GB ceiling matches DeepDrftAPI's per-request limit on api/track/upload; the
// streaming path means the limit caps the request, not in-memory buffering.
private const long MaxUploadBytes = 1_073_741_824L;
@@ -132,7 +132,7 @@
{
// OpenReadStream streams chunks from the browser via the SignalR circuit; the
// service wraps it in StreamContent so the whole file is never materialised in
// memory before DeepDrftContent receives it.
// memory before DeepDrftAPI receives it.
await using var fileStream = _selectedFile.OpenReadStream(MaxUploadBytes);
var result = await CmsTrackService.UploadTrackAsync(
+2 -2
View File
@@ -27,7 +27,7 @@ builder.Configuration.AddJsonFile(authBlocksPath, optional: false, reloadOnChang
builder.Services.AddMudServices();
// CMS track operations (read + mutate). Every track read and write goes over HTTP to the
// DeepDrftContent API via the named clients below — the Manager holds no in-process data layer.
// DeepDrftAPI API via the named clients below — the Manager holds no in-process data layer.
builder.Services.AddScoped<ICmsTrackService, CmsTrackService>();
// AuthBlocks: JWT Bearer auth, Identity, EF schema, admin seeding.
@@ -68,7 +68,7 @@ var baseUrl = GetKestrelUrl(builder);
AuthBlocksWeb.Startup.ConfigureAuthServices(builder.Services, baseUrl);
// Named HttpClient for unauthenticated Content API calls (CmsTrackService proxying WAV data
// to DeepDrftContent's POST api/track/upload). API key added per-request by the service.
// to DeepDrftAPI's POST api/track/upload). API key added per-request by the service.
var contentApiUrl = builder.Configuration["Api:ContentApiUrl"]
?? throw new InvalidOperationException("Api:ContentApiUrl is required");
builder.Services.AddHttpClient("DeepDrft.Content", client =>
+3 -3
View File
@@ -8,9 +8,9 @@ using NetBlocks.Models;
namespace DeepDrftManager.Services;
/// <summary>
/// HTTP client over the DeepDrftContent API for all CMS track operations. The Manager is
/// HTTP client over the DeepDrftAPI API for all CMS track operations. The Manager is
/// InteractiveServer-only and holds no in-process data layer: every track read and write is a
/// network call to DeepDrftContent, which is the single authority over both the SQL metadata
/// network call to DeepDrftAPI, which is the single authority over both the SQL metadata
/// store and the binary audio vault. The ApiKey is baked into the <c>DeepDrft.Content.Cms</c>
/// named client's default headers.
/// </summary>
@@ -82,7 +82,7 @@ public class CmsTrackService : ICmsTrackService
return ResultContainer<TrackEntity>.CreateFailResult("Upload failed on the content server. Please try again.");
}
// 4xx: body is user-friendly validation text from DeepDrftContent — relay as-is.
// 4xx: body is user-friendly validation text from DeepDrftAPI — relay as-is.
_logger.LogWarning("Content API rejected upload: {Status} {Body}", statusCode, body);
return ResultContainer<TrackEntity>.CreateFailResult(
string.IsNullOrWhiteSpace(body) ? $"Upload rejected ({statusCode})." : body);
+2 -2
View File
@@ -6,13 +6,13 @@ namespace DeepDrftManager.Services;
/// <summary>
/// CMS-side track operations for the Manager host. Every read and write goes over HTTP to the
/// DeepDrftContent API, which is the single authority over both the SQL metadata store and the
/// DeepDrftAPI API, which is the single authority over both the SQL metadata store and the
/// binary audio vault. DeepDrftManager holds no in-process data layer.
/// </summary>
public interface ICmsTrackService
{
/// <summary>
/// Proxy a WAV upload to DeepDrftContent. The Content API owns the dual-database write and
/// Proxy a WAV upload to DeepDrftAPI. The Content API owns the dual-database write and
/// returns the persisted entity carrying the SQL-assigned <c>Id</c>. A vault-without-SQL
/// orphan is handled and logged server-side; here it surfaces as a failed result.
/// </summary>