Add weights to burnup graph data
What does this MR do?
This is a follow up to !28899 (merged) and adds the issue weight on time to the graph data result.
Database queries
explain
select 'milestone' as "event_type",
rme.created_at,
rme.milestone_id as "value",
rme.action,
rme.issue_id
from resource_milestone_events rme
where issue_id in (33236057, 32235542, 32056787, 31593675,
31531379, 31528119, 31384625, 31307575,
31221797, 30475601, 30426855, 33078394,
33066831, 32668847, 32663897, 32415983,
31877314, 31543122, 31307594, 29564115)
and created_at <= '2020-04-17 23:59:59'
union
select 'weight' as "event_type",
rwe.created_at,
rwe.weight as "value",
null as "action",
rwe.issue_id
from resource_weight_events rwe
where issue_id in (33236057, 32235542, 32056787, 31593675,
31531379, 31528119, 31384625, 31307575,
31221797, 30475601, 30426855, 33078394,
33066831, 32668847, 32663897, 32415983,
31877314, 31543122, 31307594, 29564115)
and created_at <= '2020-04-17 23:59:59'
order by created_at;
Query plan: https://explain.depesz.com/s/2X2S
Time: 25.407 ms
- planning: 1.469 ms
- execution: 23.938 ms
- I/O read: 22.963 ms
- I/O write: 0.000 ms
Shared buffers:
- hits: 85 (~680.00 KiB) from the buffer pool
- reads: 18 (~144.00 KiB) from the OS file cache, including disk I/O
- dirtied: 0
- writes: 0
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers -
Informed Infrastructure department of a default or new setting change, if applicable per definition of done
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
-
Label as security and @ mention @gitlab-com/gl-security/appsec
-
The MR includes necessary changes to maintain consistency between UI, API, email, or other methods -
Security reports checked/validated by a reviewer from the AppSec team
Edited by Toon Claes