| Age | Commit message (Collapse) | Author |
|
Expose optimized ItemCounts for byName items
|
|
|
|
|
|
|
|
Bound change batches during a scan; keep ffprobe and image saves from failing
|
|
|
|
|
|
The legacy filter queries projected ItemValue before grouping tags and genres. EF Core translated that shape into duplicated correlated aggregates, causing multi-minute requests for libraries with many distinct values and blocking unrelated SQLite-backed API calls.
Join ItemValuesMap directly to ItemValues before grouping. This preserves type and item filtering, clean-value grouping, minimum-value selection and ordering while producing one aggregate query. Add an in-memory SQLite regression test for result semantics and both SQL shapes.
|
|
Fix recursive handling for LinkedChildren
|
|
Fix item counts on the by-name endpoints
|
|
|
|
|
|
|
|
Delete credits nothing maps to and bound item-by-name folder names
|
|
|
|
Ordering mapped both keys to the item's own stored UserData row. Folders do not
have one: a series, season or box set counts as played when no descendant is
left unplayed, which is what the isPlayed filter and the DTO both report. A
mixed library therefore sorted every series and box set into the unplayed group,
and a query could filter and sort by two different notions of "played".
Extract the filter's predicate into BuildIsPlayedFilter and route both sort keys
through it so the two cannot drift apart again.
|
|
|
|
Look up people by item via the credit map instead of a full scan
|
|
Optimize query helper memory
|
|
Fix latest items for mixed libraries
|
|
|
|
Co-Authored-By: Cody Robibero <cody@robibe.ro>
|
|
# Conflicts:
# src/Jellyfin.Database/Jellyfin.Database.Providers.Sqlite/Migrations/JellyfinDbModelSnapshot.cs
|
|
|
|
|
|
* Stop user updates from orphaning permission and preference rows
* Make UserId non-nullable
* Remove unnecessary ToList
* Update Jellyfin.Server.Implementations/Users/UserManager.cs
Co-authored-by: Claus Vium <cvium@users.noreply.github.com>
---------
Co-authored-by: Claus Vium <cvium@users.noreply.github.com>
|
|
|
|
Prevent orphaned user permissions and preferences
|
|
Fix SQLite variable limit in child count batches
|
|
|
|
|
|
|
|
|
|
|
|
Bugfix: #17547 | Batching MediaSourceCount into one call
|
|
Fix PersonTypes not applied when filtering by person
|
|
fix: correct IsAiring negation to exclude airing items
|
|
Cleanup and simplify query helpers
|
|
|
|
|
|
Filter the parent ids with the WhereOneOrMany query helper instead of a
raw Contains so the id list is wrapped in EF.Parameter and EF Core reuses
one compiled query plan across calls, matching how the rest of the item
queries build their id filters.
|
|
Rename GetItemsWithAlternateVersions to GetItemIdsWithAlternateVersions
across the interfaces and implementations since it returns ids. Return
the hashset straight from the query instead of materializing an array
first. Rename the DtoService guard to mayHaveAlternateVersions and
invert it so the computed path is the explicit case. Assert the media
source count value in the batch skip test and add a test covering an
item that is in the returned set still resolving to the correct count.
|
|
Browsing a page of videos with the MediaSourceCount field ran one alternate
version query per item, each opening a fresh DbContext. On a large library that
turned a single page into hundreds of sequential round trips and made the Items
endpoint take tens of seconds while holding a request thread the whole time.
Detect which videos own alternate versions once per page with a single query,
mirroring the existing people batch. Videos absent from that set have a single
media source, so the per item lookups are skipped for the common case. Behavior
is unchanged: a video with no alternates already resolved to a count of one.
Adds a regression test asserting the count resolves from the batch and the per
item lookups are never called.
|
|
Batch people lookups when building item DTOs
|
|
Fix by-name endpoints reporting TotalRecordCount=0 next to a populated Items array
|
|
GetBaseItemDtos already batch fetches user data, child counts, played counts
and artists before its per item loop, but AttachPeople still ran one GetPeople
query per item. Rendering a page of items (for example a large playlist) fired
one extra query per row.
Add GetPeopleByItems to IPeopleRepository, which reads every requested item in a
single query over the people mapping table and returns full PersonInfo (role,
type and sort order) grouped by item id. GetBaseItemDtos prefetches this once
when the People field is requested and passes it into AttachPeople, which reads
from the batch instead of querying per item. The single item GetBaseItemDto path
keeps its existing per item behaviour when no batch is supplied.
Adds a DtoService test asserting people resolve from the batch and the per item
GetPeople is never called.
|
|
|
|
This makes the deletion of BaseItemProviders, BaseItemImageInfos, and BaseItemMetadataFields happen in batch as a contiguous block so the lock isn't held across items, just before the bulk SaveChanges.
|
|
Replace the O(n²) array .First scan with a dictionary lookup
|
|
Makes the test O(log n)
|