Node build/unbuild updates study last modification date#992
Conversation
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThis PR extends unbuild operations in GridSuite Study Server to track the requesting user and emit element-update notifications. The unbuild APIs in StudyService, StudyController, and SupervisionService are updated to accept a userId parameter, and notifications are emitted after unbuild completion. Tests verify userId passing and notification messages. ChangesAdd userId tracking and element-update notifications to unbuild flow
Suggested Reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 3❌ Failed checks (2 warnings, 1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/main/java/org/gridsuite/study/server/controller/StudyController.java`:
- Around line 1703-1708: The pre-check assertNoBlockedNodeInStudy should be run
before entering the try/finally so that unblockNodeTree in the finally does not
run when the pre-check fails; move the call to
studyService.assertNoBlockedNodeInStudy(studyUuid, rootNodeUuid) above the try,
then keep studyService.unbuildNodeTree(...) inside the try and
studyService.unblockNodeTree(...) in the finally so unblock only executes after
unbuild processing has begun.
In `@src/main/java/org/gridsuite/study/server/service/StudyService.java`:
- Around line 1900-1907: The method unbuildNodeTree accepts a nullable userId
but immediately uses it in notificationService.emitElementUpdated; update the
method signature to enforce non-null for userId (e.g., annotate userId with
`@NonNull` or add an explicit Objects.requireNonNull(userId, ...) at the start of
unbuildNodeTree) so callers fail fast and match adjacent APIs; locate the method
by name unbuildNodeTree(UUID studyUuid, UUID rootNodeUuid, boolean
withBlockNodes, String userId) and apply the non-null check/annotation before
any async work or the notification emission.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 780b3f89-ac9b-497c-800b-a3c913b6e170
📒 Files selected for processing (4)
src/main/java/org/gridsuite/study/server/controller/StudyController.javasrc/main/java/org/gridsuite/study/server/service/StudyService.javasrc/main/java/org/gridsuite/study/server/service/SupervisionService.javasrc/test/java/org/gridsuite/study/server/NetworkModificationUnitTest.java
|



PR Summary