Generate shifts for a timeframe based on on-call rotation params
What does this MR do?
Related issue: #262860 (closed).
This is one of several MRs for managing on-call shifts. Under Operations > On-call schedules, we're building the tools to manage an on-call rotation for a project. A project can have an OncallSchedule
, which can have many OncallRotations
, which describe the participants of the rotation and the parameters of the OncallShifts
for that rotation. For example, the image in the proposal section of #262860 (closed) shows a single schedule with a single rotation which has 3-day-long shifts & four participants.
#262860 (closed) is comprised of several pieces:
- Add shifts table (!49423 (merged))
- Add ability to generate shifts from rotation (!49665 (merged))
- Add graphql support for querying shifts (!50006 (merged))
- Persisting historical shifts (TBD)
This MR adds a class which does two things:
- generates a collections shifts based on a range of time and an
IncidenmentManagement::OncallRotation
- generates a single shift based on a timestamp and a rotation
Changes in this MR are not yet user-facing, so there won't be a changelog.
Screenshots (strongly suggested)
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
Related to #262860 (closed)