Skip to content

Avoid loading full result sets for run input roles and the classic Lineage panel - #8157

Merged
labkey-jeckels merged 2 commits into
developfrom
fb_large_result_loads
Oct 19, 2026
Merged

labkey-jeckels merged 2 commits into
developfrom
fb_large_result_loads

Conversation

@labkey-jeckels

@labkey-jeckels labkey-jeckels commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

Rationale

Two experiment code paths load tens or hundreds of thousands of rows into memory to produce a small result: the input roles shown with experiment run lists, and the classic data/sample Lineage panel.

Related Pull Requests

Changes

  • Input roles are selected as distinct values in SQL instead of one row per run input (up to ~760K rows observed).
  • The classic Lineage panel builds its grids from lineage row ids and a small distinct folder/type query instead of loading every data object, sample, and run in the item's full lineage. The full recursion is unchanged.
  • The panel's grids now use a permission-checking container filter limited to the lineage's readable folders instead of the unsafe "everything" filter.

Tasks

…very item

The panel loaded every data object, sample, and run in the item's full lineage to show at most 100 rows per grid.
@labkey-jeckels labkey-jeckels self-assigned this Oct 11, 2026
@labkey-jeckels
labkey-jeckels marked this pull request as ready for review October 11, 2026 17:17
@labkey-jeckels
labkey-jeckels requested a review from a team October 11, 2026 17:17
@labkey-gokhano

labkey-gokhano commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Manual testing: passed

Tested locally with this branch merged onto current develop, as an admin and as a user with Reader on one subfolder only.

Classic Lineage panel

Case Result
Parents/children all of one sample type or data class ✅ Grid uses that type's own columns
Parents of mixed sample types or data classes ✅ Generic grid with all items
Grandparents / grandchildren ✅ Still shown; full recursion intact
No lineage ✅ Empty grids, no errors
Parent in another folder the user can read (Issue 38018) ✅ Shown
Reader: one parent in a readable folder, one not ✅ Only the readable parent shown; type detection uses readable items only
Reader: only parent is in an unreadable folder ✅ Empty grid, nothing leaks
Sample with 500 children ✅ Loads in under 0.1s

Input roles

Case Result
Runs grid Input lookup columns ✅ Each role once, filled per run
Runs grid Export → Files role checkboxes ✅ Each role once
Derive samples role dropdown ⚪ Not tested; removed from develop in #8135

Not covered: lineage mixing data that has no data class (e.g. assay result files) with data class items, and roles that differ only by case.

Existing behavior, not from this PR: the Lineage grids hide their pager, so only the first 100 rows can be seen. Here that showed 100 of 500 children.

@labkey-jeckels
labkey-jeckels merged commit d87a97b into develop Oct 19, 2026
14 checks passed
@labkey-jeckels
labkey-jeckels deleted the fb_large_result_loads branch October 19, 2026 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants