Skip to content

Making it possible to skip a timers from the progress tab - #843

Open
IvarKoreman-Ritense wants to merge 6 commits into
next-minorfrom
story/issue-465-skip-timers
Open

Making it possible to skip a timers from the progress tab#843
IvarKoreman-Ritense wants to merge 6 commits into
next-minorfrom
story/issue-465-skip-timers

Conversation

@IvarKoreman-Ritense

@IvarKoreman-Ritense IvarKoreman-Ritense commented Jul 23, 2026

Copy link
Copy Markdown
Member

Describe the changes

Link to the related Github issue: generiekzaakafhandelcomponent/gzac-issues#465

Breaking changes

  • The contribution only contains changes that are not breaking.

Documentation

  • Release notes have been written for these changes.

New features or changes that have been introduced have been documented.

  • Yes
  • Not applicable

Tests

Unit tests have been added that cover these changes

  • Yes
  • Not applicable

Integration tests have been added that cover these changes

  • Yes
  • Not applicable

Describe the testing steps

  • Have a process that has a timer and start this process and walk through it until you're waiting on this timer
  • Login as admin (who will have the OperatonExecution->modify PBAC permission)
  • Go to the case of the above mentioned process and go to the Progress tab.
  • Click on the skip icon above the active timer and skip it.
  • Repeat the first steps and login as a user without the OperatonExecution->modify PBAC permission to ensure that they don't have this skip option.

Security

The Secure by Design principle has been applied to these changes

  • Yes
  • Not applicable

Added or changed REST API endpoints have authentication and authorization in place

  • Yes
  • Not applicable

Valtimo access control checks have been implemented

  • Yes
  • Not applicable

Dependencies

Newly added dependencies do not introduce known vulnerabilities/CVE's and are in line with the Valtimo license

  • Yes
  • Not applicable

@IvarKoreman-Ritense
IvarKoreman-Ritense requested review from a team as code owners July 23, 2026 07:44
@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Warning

Review limit reached

@IvarKoreman-Ritense, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 3 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 1917c335-862d-45a0-977d-66fdcd07b6df

📥 Commits

Reviewing files that changed from the base of the PR and between bf3a8ee and 9985726.

📒 Files selected for processing (4)
  • documentation/features/access-control/container-conditions.md
  • documentation/release-notes/13.x.x/13.39.0/README.md
  • frontend/projects/valtimo/case/src/lib/components/case-detail/tab/progress/progress.component.ts
  • frontend/projects/valtimo/shared/assets/core/nl.json
📝 Walkthrough

Walkthrough

Adds authorization support and case-scoped REST endpoints for listing and skipping process timers. Skips execute timer jobs and publish an auditable ProcessTimerSkippedEvent. The Progress tab now loads skippable timers, displays diagram overlays, confirms skip actions, refreshes process state, and shows translated feedback. Documentation, permissions, auto-configuration, and tests are updated accordingly.

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch story/issue-465-skip-timers

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
backend/process-document/src/test/kotlin/com/ritense/processdocument/web/rest/ProcessInspectionResourceTest.kt (1)

99-116: 🎯 Functional Correctness | 🔴 Critical | ⚡ Quick win

Fix the stale constructor wiring.

Line 99 passes four arguments to ProcessInstanceCaseAccessService, but it now accepts only ProcessDocumentAssociationService. Line 106 also omits the required documentService and authorizationService arguments for ProcessInspectionResource; this test source will not compile.

Proposed fix
 val caseAccessService = ProcessInstanceCaseAccessService(
-    documentService,
-    authorizationService,
     processDocumentAssociationService,
-    runtimeService,
 )

 resource = ProcessInspectionResource(
+    documentService = documentService,
+    authorizationService = authorizationService,
     caseAccessService = caseAccessService,

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: da40f6af-4d3f-4640-881f-a9d4999221c0

📥 Commits

Reviewing files that changed from the base of the PR and between 7eac5b7 and 83be682.

📒 Files selected for processing (27)
  • backend/apps/dev/src/main/resources/config/global/permission/processinstance.permission.json
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/authorization/OperatonExecutionActionProvider.kt
  • backend/process-document/src/main/java/com/ritense/processdocument/autoconfigure/ProcessDocumentAutoConfiguration.java
  • backend/process-document/src/main/java/com/ritense/processdocument/security/config/ProcessDocumentHttpSecurityConfigurer.java
  • backend/process-document/src/main/java/com/ritense/processdocument/service/impl/OperatonProcessJsonSchemaDocumentAuditService.java
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/event/ProcessTimerSkippedEvent.kt
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/service/ProcessInstanceCaseAccessService.kt
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/web/rest/ProcessInspectionResource.kt
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/web/rest/ProcessTimerResource.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/event/ProcessTimerSkippedEventTest.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/service/ProcessInstanceCaseAccessServiceTest.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/service/impl/OperatonProcessJsonSchemaDocumentAuditServiceTest.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/web/rest/ProcessInspectionResourceTest.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/web/rest/ProcessTimerResourceTest.kt
  • documentation/features/case/case-detail/tabs/README.md
  • documentation/features/process/README.md
  • documentation/release-notes/13.x.x/13.39.0/README.md
  • frontend/projects/valtimo/case/src/lib/components/case-detail/tab/progress/progress.component.html
  • frontend/projects/valtimo/case/src/lib/components/case-detail/tab/progress/progress.component.ts
  • frontend/projects/valtimo/case/src/lib/permissions/case-detail.permissions.ts
  • frontend/projects/valtimo/case/src/lib/services/case-process-timer.service.ts
  • frontend/projects/valtimo/case/src/lib/services/index.ts
  • frontend/projects/valtimo/process/src/lib/models/process.model.ts
  • frontend/projects/valtimo/process/src/lib/process-diagram/process-diagram.component.scss
  • frontend/projects/valtimo/process/src/lib/process-diagram/process-diagram.component.ts
  • frontend/projects/valtimo/shared/assets/core/en.json
  • frontend/projects/valtimo/shared/assets/core/nl.json

* permission on it. The process-instance execution row has `ID_ == PROC_INST_ID_`, so it is loaded by
* [processInstanceId]. A missing execution means the instance is not active.
*/
private fun requireExecutionModifyPermission(processInstanceId: String) {

@ivo-ritense ivo-ritense Jul 23, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I discussed this with the team, and we think it's best to have a new entity type for this. The risk right now is that we might in the future want to add other ways of changing a running process that would make sense to also put on operaton execution. Users might then get unintended access to new features.

Our suggestion so far is to make an OperatonTimer entity and perform the complete action. That way we could later also have a different feature to change the timer to a different duration as the modify action.

It would make sense to add a mapper from the OperatonTimer to the OperatonExecution class so you can still refer to the path leading up to the case instances for conditions.

As an example on how something like this could be done, you can look at the ZgwDocument class. Used like this

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
frontend/projects/valtimo/case/src/lib/components/case-detail/tab/progress/progress.component.ts (2)

153-164: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Bind the pending timer to its original process context.

The pending state stores only the timer, while Line 161 uses the currently selected process instance and Line 163 reads the current document ID. If the user changes process instance or navigates while the confirmation is open, the request uses the wrong context and the backend rejects the job as not belonging to that process. Store the document/process IDs with the pending timer, or clear the confirmation when either changes.


176-179: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Refresh process-instance data after a successful skip.

This success path reloads timers and the diagram, but processDocumentInstances$ is driven only by route changes. If skipping a timer changes the process instance’s active/completed state, the Progress tab keeps stale process-instance data until navigation or a full reload. Add a process-instance refresh trigger and emit it here.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 2db5a724-d738-4779-bd37-c38952ebe01f

📥 Commits

Reviewing files that changed from the base of the PR and between f408baa and bf3a8ee.

📒 Files selected for processing (17)
  • backend/apps/dev/src/main/resources/config/global/permission/process-timer.permission.json
  • backend/core/src/main/kotlin/com/ritense/valtimo/autoconfiguration/ValtimoOperatonAutoConfiguration.kt
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/authorization/OperatonTimerActionProvider.kt
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/authorization/OperatonTimerExecutionMapper.kt
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/authorization/OperatonTimerSpecification.kt
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/authorization/OperatonTimerSpecificationFactory.kt
  • backend/core/src/main/kotlin/com/ritense/valtimo/operaton/domain/OperatonTimer.kt
  • backend/core/src/test/kotlin/com/ritense/valtimo/operaton/authorization/OperatonTimerExecutionMapperTest.kt
  • backend/process-document/src/main/java/com/ritense/processdocument/autoconfigure/ProcessDocumentAutoConfiguration.java
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/service/ProcessInstanceCaseAccessService.kt
  • backend/process-document/src/main/kotlin/com/ritense/processdocument/web/rest/ProcessTimerResource.kt
  • backend/process-document/src/test/kotlin/com/ritense/processdocument/web/rest/ProcessTimerResourceTest.kt
  • documentation/features/access-control/configurable-elements.md
  • documentation/features/access-control/container-conditions.md
  • documentation/features/process/README.md
  • documentation/release-notes/13.x.x/13.39.0/README.md
  • frontend/projects/valtimo/case/src/lib/components/case-detail/tab/progress/progress.component.ts
💤 Files with no reviewable changes (1)
  • backend/process-document/src/main/java/com/ritense/processdocument/autoconfigure/ProcessDocumentAutoConfiguration.java

Conflicts:
	documentation/release-notes/13.x.x/13.39.0/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants