feat: Recently Added Guard plugin for Jellyfin 12.2
Keeps Radarr/Sonarr quality upgrades out of "Recently Added" by keeping a ledger of the first date added per logical medium (movie or episode, identified by provider ids and the series) and restoring it on upgrades. - core logic without Jellyfin types (Reconciler, MediaKeys, GuardProcessor) - thread-safe ledger with atomic, debounced persistence - event processing via channel and background worker, seed on first start - scheduled task "Ledger synchronisieren", status API, configuration page - xUnit tests and a Jellyfin 12.2 integration test - Gitea workflows: build/test, release with jprm and manifest branch Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
d431486095
38 files changed
+4396
No files matched your search
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Jellyfin.Plugin.RecentlyAddedGuard.Core;
|
||||
|
||||
/// <summary>
|
||||
/// Kind of logical medium tracked by the ledger.
|
||||
/// </summary>
|
||||
public enum MediaKind
|
||||
{
|
||||
/// <summary>A movie.</summary>
|
||||
Movie,
|
||||
|
||||
/// <summary>A TV episode (or a multi-episode file).</summary>
|
||||
Episode
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Jellyfin-independent snapshot of a library item, as consumed by the <see cref="Reconciler"/>.
|
||||
/// </summary>
|
||||
/// <param name="ItemId">The Jellyfin item id.</param>
|
||||
/// <param name="Kind">The kind of medium.</param>
|
||||
/// <param name="DateCreated">The item's current "date added" (UTC).</param>
|
||||
/// <param name="Keys">All identity keys of the logical medium; empty if the item cannot be identified yet.</param>
|
||||
/// <param name="DisplayName">Human readable name for logs and the configuration page.</param>
|
||||
public sealed record MediaIdentity(
|
||||
Guid ItemId,
|
||||
MediaKind Kind,
|
||||
DateTime DateCreated,
|
||||
IReadOnlyList<string> Keys,
|
||||
string DisplayName);
|
||||
Reference in new issue
Block a user