Skip to content

Optimize checking for existing ro-crate records #201

Open

Description

@daniel-thom

Copilot made this suggestion:

"find_entity_for_file calls list_ro_crate_entities (fetching all entities for the workflow) to find a single record by file_id. In create_ro_crate_entity_for_file this is called once, and in create_ro_crate_entity_for_output_file it is called once more, meaning for each file processed there is a full list fetch. For workflows with many entities this becomes an O(n) per-file lookup. Consider adding a dedicated API endpoint to look up an entity by file_id, or pass in a pre-fetched map of existing entities to these helpers."

Activity

  1. self-assigned this
    on Apr 21, 2026
  2. added a commit that references this issue on May 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions