Remove YouTube integration from backend and deployment config

Drops the YouTube-backed second catalog source entirely: the
Local/External split on Track/Album collapses into single concrete
entities, Artist/TrackArtist/ExternalTrack/ExternalAlbum and the
YouTube service/download pipeline (yt-dlp, MassTransit consumer,
routing slip) are deleted, and mixes now source discovery only from
local listening history. Includes the RemoveYouTubeIntegration EF
Core migration and matching Worker/deploy/compose cleanup (no more
yt-dlp/python/deno in the Worker image, no thumbnail-cache/YtDlp
config sections).
This commit is contained in:
2026-09-15 21:17:03 +02:00
parent 5696683859
commit 31032bd8e8
137 changed files with 1933 additions and 3969 deletions
@@ -8,8 +8,6 @@ using Musify.Application.Albums.Responses;
using Musify.Application.Contracts;
using Musify.Application.Shared;
using Musify.Application.Tracks.Responses;
using Musify.Application.YouTube;
using Musify.Domain.ValueObjects;
namespace Musify.Api.Endpoints;
@@ -22,7 +20,7 @@ public static class AlbumEndpoints
group.MapGet("/", GetAlbums)
.WithName("GetAlbums")
.WithSummary("Get Paginated Albums, Combined With Live YouTube Music Results When A Title Filter Is Given.")
.WithSummary("Get Paginated Albums, Optionally Filtered By Title.")
.Produces<AlbumsSearchResponse>();
group.MapGet("/{id}", GetAlbumById)
@@ -31,12 +29,6 @@ public static class AlbumEndpoints
.Produces<AlbumApplicationResponse>()
.Produces(StatusCodes.Status404NotFound);
group.MapGet("/external/{source}/{externalId}", GetExternalAlbum)
.WithName("GetExternalAlbum")
.WithSummary("Get An Album From An External Source (Currently Only YouTube Music) With Its Tracklist.")
.Produces<YouTubeAlbumDetail>()
.Produces(StatusCodes.Status404NotFound);
group.MapGet("/users/{userId}", GetAlbumsByUserId)
.WithName("GetAlbumsByUserId")
.WithSummary("Get Paginated Albums For A User.")
@@ -125,10 +117,9 @@ public static class AlbumEndpoints
CancellationToken cancellationToken,
string? title,
int pageNumber = 1,
int pageSize = 10,
string? youtubeContinuationToken = null)
int pageSize = 10)
{
var result = await mediator.Send(new GetAlbumsQuery(title, pageNumber, pageSize, youtubeContinuationToken), cancellationToken);
var result = await mediator.Send(new GetAlbumsQuery(title, pageNumber, pageSize), cancellationToken);
return result.ToHttpResult();
}
@@ -141,19 +132,6 @@ public static class AlbumEndpoints
return result.ToHttpResult();
}
private static async Task<IResult> GetExternalAlbum(
IMediator mediator,
string source,
string externalId,
CancellationToken cancellationToken)
{
if (!Enum.TryParse<TrackSource>(source, ignoreCase: true, out var trackSource) || trackSource != TrackSource.YouTube)
return Results.NotFound($"Unknown or unsupported source '{source}'.");
var result = await mediator.Send(new GetYouTubeAlbumQuery(externalId), cancellationToken);
return result.ToHttpResult();
}
private static async Task<IResult> GetAlbumsByUserId(
IMediator mediator,
long userId,