Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update of entity loading to be more efficient and avoid global addSelects #4827

Merged
merged 12 commits into from
Feb 11, 2024

Commits on Feb 4, 2024

  1. DB: Started update of entity loading to avoid global selects

    Removes page/chpater addSelect global query, to load book slug, and
    instead extracts base queries to be managed in new static class, while
    updating specific entitiy relation loading to use our more efficient
    MixedEntityListLoader where appropriate.
    
    Related to #4823
    ssddanbrown committed Feb 4, 2024
    Configuration menu
    Copy the full SHA
    a70ed81 View commit details
    Browse the repository at this point in the history
  2. Queries: Migrated BookRepo queries to new query class

    Also moved to a non-static approach, and added a high-level class to
    allow easy access to all other entity queries, for use in mixed-entity
    scenarios and easier/simpler injection.
    ssddanbrown committed Feb 4, 2024
    Configuration menu
    Copy the full SHA
    1559b0a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3886aed View commit details
    Browse the repository at this point in the history

Commits on Feb 5, 2024

  1. Queries: Extracted chapter repo queries to class

    Updated query classes to align to interface for common aligned
    operations.
    Extracted repeated string-identifier-based finding from page/chapter
    repos to shared higher-level entity queries.
    ssddanbrown committed Feb 5, 2024
    Configuration menu
    Copy the full SHA
    8e78b4c View commit details
    Browse the repository at this point in the history
  2. Queries: Extracted PageRepo queries to own class

    Started new class for PageRevisions too as part of these changes
    ssddanbrown committed Feb 5, 2024
    Configuration menu
    Copy the full SHA
    222c665 View commit details
    Browse the repository at this point in the history

Commits on Feb 7, 2024

  1. Configuration menu
    Copy the full SHA
    c95f4ca View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4834107 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    546cfb0 View commit details
    Browse the repository at this point in the history
  4. Queries: Moved out or removed some class-level items

    Also ran auto-removal of unused imports across app folder.
    ssddanbrown committed Feb 7, 2024
    Configuration menu
    Copy the full SHA
    b77ab6f View commit details
    Browse the repository at this point in the history

Commits on Feb 8, 2024

  1. Queries: Updated old use-specific entity query classes

    - Updated name to align, and differentate from new 'XQueries' clases.
    - Removed old sketchy base class with app resolving workarounds, to a
      proper injection-based approach.
    - Also fixed wrong translation text used in PageQueries.
    ssddanbrown committed Feb 8, 2024
    Configuration menu
    Copy the full SHA
    ed21a6d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ed9c013 View commit details
    Browse the repository at this point in the history

Commits on Feb 11, 2024

  1. Queries: Update API to align data with previous versions

    Ensures fields returned match API docs and previous versions of
    BookStack where we were accidentally returning more fields than
    expected.
    Updates tests to cover many of these.
    Also updated clockwork to ignore image requests for less noisy
    debugging.
    Also updated chapter page query to not be loading all page data, via new
    query in PageQueries.
    ssddanbrown committed Feb 11, 2024
    Configuration menu
    Copy the full SHA
    1ea2ac8 View commit details
    Browse the repository at this point in the history