Nicolas Dular activity https://gitlab.com/nicolasdular 2026-03-18T14:20:53Z tag:gitlab.com,2026-03-18:5217882362 Nicolas Dular commented on merge request !226100 at GitLab.org / GitLab 2026-03-18T14:20:53Z nicolasdular Nicolas Dular [email protected]

@mksionek i had to fix a CE test: !226100 (a16eb2a0)

  1. seems like roll_up is actually part of CE (and just always false)
  2. the instance_double didn't work in EE when we set EE variables
tag:gitlab.com,2026-03-18:5217813495 Nicolas Dular pushed to project branch nd/add-more-rest-entities at GitLab.org / GitLab 2026-03-18T14:08:08Z nicolasdular Nicolas Dular [email protected]

Nicolas Dular (a16eb2a0) at 18 Mar 14:08

Fix CE tests

tag:gitlab.com,2026-03-18:5217796283 Nicolas Dular opened merge request !227907: Add EE work item REST API features and N+1 test at GitLab.org / GitLab 2026-03-18T14:05:14Z nicolasdular Nicolas Dular [email protected]

What does this MR do and why?

Add EE work item REST API features and N+1 test

Add EE entity extensions for work item widgets:

  • ee/lib/ee/api/entities/work_items/features.rb: exposes color, health_status, progress, iteration widgets
  • ee/lib/ee/api/work_items.rb: adds EE preloads for N+1 prevention

Add N+1 query prevention test covering all EE features:

  • iteration, health_status, start_and_due_date, color, progress
  • Tests epic work items (color) and objective work items (progress)

Minimal CE changes (prepend_mod only):

  • lib/api/entities/work_items/features.rb
  • lib/api/work_items.rb

References

Screenshots or screen recordings

Before After

How to set up and validate locally

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

tag:gitlab.com,2026-03-18:5217759318 Nicolas Dular pushed new project branch nd/work-item-api-time-tracking-milestones-etc at GitLab.org / GitLab 2026-03-18T13:58:09Z nicolasdular Nicolas Dular [email protected]

Nicolas Dular (172bca6f) at 18 Mar 13:58

Add N+1 query prevention test for development feature in project scope

... and 5 more commits

tag:gitlab.com,2026-03-18:5217731012 Nicolas Dular commented on issue #477974 at GitLab.org / GitLab 2026-03-18T13:52:43Z nicolasdular Nicolas Dular [email protected]

@mksionek I think most of this work is done by all the presenter work we did where we read from the WorkItem instead of the epic. At least for the main epic entitity.

For the relationships like related_items or epic_issues etc, we have the other epics to cover that work.

WDYT about closing this ?

tag:gitlab.com,2026-03-18:5217380203 Nicolas Dular approved merge request !223191: Refactor ids for base and decendants models part at GitLab.org / GitLab 2026-03-18T12:41:32Z nicolasdular Nicolas Dular [email protected]

What does this MR do and why?

We want to stop using epics table as much as possible. This MR preps for refactor of ee/lib/gitlab/graphql/loaders/bulk_epic_aggregate_loader.rb file.

To keep changes limited for ease of review, this code added here is not used yet. It will be in the second part of this work.

This MR refactors work item hierarchy traversal methods to improve code organization and maintainability. It introduces a new generic service for aggregating child issue data and consolidates hierarchy traversal logic.

Changes:

  1. New WorkItems::AggregateChildIssuesService - Adds a dedicated service to aggregate child issue metadata for work items (epics). This service:
    • Aggregates issue counts, weights, and state information
    • Optionally includes health status counts (on track, needs attention, at risk)
    • Supports configurable limits for performance
    • Uses optimized SQL joins and grouping for efficient data retrieval
  2. Generic descendant_ids_for method in WorkItem model - Introduces a reusable method for traversing work item hierarchies:
    • Returns all descendant IDs for given work items
    • Supports optional filtering by work item type
    • Uses Gitlab::WorkItems::WorkItemHierarchy for consistent traversal logic
  3. Backward compatibility for Epic methods - Refactors existing Epic-specific methods while maintaining compatibility:
    • Renames ids_for_base_and_decendants to ids_for_base_and_descendants_legacy (fixes typo)
    • Renames issue_metadata_for_epics to issue_metadata_for_epics_legacy
    • Adds method aliases to preserve existing API
    • Prepares for future migration to the new generic service

Benefits:

  • Centralizes hierarchy traversal logic in the WorkItem model
  • Provides a more flexible and testable service for aggregating child data
  • Maintains backward compatibility while enabling future refactoring
  • Improves code organization by separating concerns

References

First draft of this refactor is here: !223043 <= this version was not polished and not final, but I wanted to see if it's even possible. It's just for a reference.

Screenshots or screen recordings

Before After

How to set up and validate locally

There are no visible changes now.

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

tag:gitlab.com,2026-03-18:5217240138 Nicolas Dular commented on merge request !227889 at GitLab.org / GitLab 2026-03-18T12:11:33Z nicolasdular Nicolas Dular [email protected]

!227705 (merged) the related MR that added the field to project_attributes.yml that we read from. Since it's an EE-only feature, we need to remove it in the CE test.

tag:gitlab.com,2026-03-18:5217218992 Nicolas Dular commented on merge request !227889 at GitLab.org / GitLab 2026-03-18T12:07:17Z nicolasdular Nicolas Dular [email protected]

@GitLabDuo read the whole diff, it's guarded

tag:gitlab.com,2026-03-18:5217203913 Nicolas Dular pushed to project branch fix-pre-receive-secret-detection-foss-test at GitLab.org / GitLab 2026-03-18T12:04:27Z nicolasdular Nicolas Dular [email protected]

Nicolas Dular (4757c42a) at 18 Mar 12:04

Fix FOSS test for pre_receive_secret_detection_enabled

tag:gitlab.com,2026-03-18:5217200611 Nicolas Dular opened merge request !227889: Fix FOSS test for pre_receive_secret_detection_enabled at GitLab.org / GitLab 2026-03-18T12:03:40Z nicolasdular Nicolas Dular [email protected]

What does this MR do and why?

This is an EE-only feature, so we need to exclude it from the keys in the CE specs.

References

Screenshots or screen recordings

Before After

How to set up and validate locally

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

tag:gitlab.com,2026-03-18:5217196136 Nicolas Dular pushed new project branch fix-pre-receive-secret-detection-foss-test at GitLab.org / GitLab 2026-03-18T12:02:36Z nicolasdular Nicolas Dular [email protected]

Nicolas Dular (8e27144b) at 18 Mar 12:02

Fix FOSS test for pre_receive_secret_detection_enabled

tag:gitlab.com,2026-03-18:5216538617 Nicolas Dular commented on merge request !227413 at GitLab.org / GitLab 2026-03-18T09:39:30Z nicolasdular Nicolas Dular [email protected]

I am approving as the logic is fine 👍 You can decide if you want to change to the epics table or not.

tag:gitlab.com,2026-03-18:5216537412 Nicolas Dular approved merge request !227413: Backfill description_versions issue_id for epic work items at GitLab.org / GitLab 2026-03-18T09:39:14Z nicolasdular Nicolas Dular [email protected]

What does this MR do and why?

  • This MR backfills the description_versions table, setting issue_id to the value of the corresponding epic's issue_id, and setting epic_id to null.

References

Screenshots or screen recordings

Not provided

Database

https://console.postgres.ai/gitlab/gitlab-production-main/sessions/49881/commands/148334

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #454439

tag:gitlab.com,2026-03-18:5216440679 Nicolas Dular commented on merge request !227413 at GitLab.org / GitLab 2026-03-18T09:18:41Z nicolasdular Nicolas Dular [email protected]

Thanks @mdangelo6 I'd have expected that we iterate over the epics table as it's the way smaller table. Let me know if you want to change the approach @mdangelo6 and @bmarjanovic

I also currently check in the replica if that's the latest description version, but I am 99% sure it's fine 👍

tag:gitlab.com,2026-03-18:5216440611 Nicolas Dular commented on merge request !227413 at GitLab.org / GitLab 2026-03-18T09:18:41Z nicolasdular Nicolas Dular [email protected]

Wouldn't it be easier and faster to iterate over the epics table as it's the way smaller (300x smaller) table?

tag:gitlab.com,2026-03-18:5216379249 Nicolas Dular commented on merge request !227688 at GitLab.org / GitLab 2026-03-18T09:05:06Z nicolasdular Nicolas Dular [email protected]

Hey @daniyalAD would you mind to perform the review on this MR please?