You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "pvillard31 (via GitHub)" <gi...@apache.org> on 2025/12/29 11:02:24 UTC
[PR] NIFI-15395 - Clearing bulletins when there is no component should not throw 400 [nifi]
pvillard31 opened a new pull request, #10700:
URL: https://github.com/apache/nifi/pull/10700
# Summary
NIFI-15395 - Clearing bulletins when there is no component should not throw 400
# Tracking
Please complete the following tracking steps prior to pull request creation.
### Issue Tracking
- [ ] [Apache NiFi Jira](https://issues.apache.org/jira/browse/NIFI) issue created
### Pull Request Tracking
- [ ] Pull Request title starts with Apache NiFi Jira issue number, such as `NIFI-00000`
- [ ] Pull Request commit message starts with Apache NiFi Jira issue number, as such `NIFI-00000`
### Pull Request Formatting
- [ ] Pull Request based on current revision of the `main` branch
- [ ] Pull Request refers to a feature branch with one commit containing changes
# Verification
Please indicate the verification steps performed prior to pull request creation.
### Build
- [ ] Build completed using `./mvnw clean install -P contrib-check`
- [ ] JDK 21
- [ ] JDK 25
### Licensing
- [ ] New dependencies are compatible with the [Apache License 2.0](https://apache.org/licenses/LICENSE-2.0) according to the [License Policy](https://www.apache.org/legal/resolved.html)
- [ ] New dependencies are documented in applicable `LICENSE` and `NOTICE` files
### Documentation
- [ ] Documentation formatting appears as expected in rendered files
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-15395 - Clearing bulletins when there is no component should not throw 400 [nifi]
Posted by "exceptionfactory (via GitHub)" <gi...@apache.org>.
exceptionfactory merged PR #10700:
URL: https://github.com/apache/nifi/pull/10700
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-15395 - Clearing bulletins when there is no component should not throw 400 [nifi]
Posted by "pvillard31 (via GitHub)" <gi...@apache.org>.
pvillard31 commented on code in PR #10700:
URL: https://github.com/apache/nifi/pull/10700#discussion_r2651352409
##########
nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java:
##########
@@ -1357,6 +1357,13 @@ public Response clearBulletins(
clearBulletinsForGroupRequestEntity.setComponents(writableComponentIds);
}
+ // If there are no components to clear bulletins for, return success with 0 bulletins cleared
+ if (clearBulletinsForGroupRequestEntity.getComponents().isEmpty()) {
Review Comment:
yep, that's fair
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-15395 - Clearing bulletins when there is no component should not throw 400 [nifi]
Posted by "pvillard31 (via GitHub)" <gi...@apache.org>.
pvillard31 commented on PR #10700:
URL: https://github.com/apache/nifi/pull/10700#issuecomment-3699052195
Thanks for the review @exceptionfactory - I pushed a commit to address your comment and take the suggested approach
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-15395 - Clearing bulletins when there is no component should not throw 400 [nifi]
Posted by "exceptionfactory (via GitHub)" <gi...@apache.org>.
exceptionfactory commented on code in PR #10700:
URL: https://github.com/apache/nifi/pull/10700#discussion_r2651319285
##########
nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/FlowResource.java:
##########
@@ -1357,6 +1357,13 @@ public Response clearBulletins(
clearBulletinsForGroupRequestEntity.setComponents(writableComponentIds);
}
+ // If there are no components to clear bulletins for, return success with 0 bulletins cleared
+ if (clearBulletinsForGroupRequestEntity.getComponents().isEmpty()) {
Review Comment:
It seems like this conditional should be added to the earlier check for a `null` list of Components. In that case, the absence of Components is interpreted to mean all Components in the Process Group. Handling `null` and an empty list in the same way seems more consistent. What do you think?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org