pvillard31 opened a new pull request, #10681: URL: https://github.com/apache/nifi/pull/10681
# Summary NIFI-15381 - Improve UX for the view Show/Revert Local Changes to account for environmental changes ## Issue description As part of the change in [NIFI-14442](https://issues.apache.org/jira/browse/NIFI-14442), when listing local changes we are also listing the fact that bundle versions may have changed as part of an upgrade and that it'll be part of the commit. However we are also going to show those changes when clicking "revert local changes" in the UI but those changes should not be listed since we are NOT going to revert this as part of the action. However it can get tricky... those changes can be environmental because we upgraded the NiFi version and the component NAR went from X to Y automatically as part of the upgrade. But we could also have a bundle version change as the result of a manual action from the user when you have multiple versions of the same NAR in NiFi. In this case changing the version is not an environmental change and the user could indeed revert that version change. So we need to improve the logic around all of this to have the proper UX and show only the list of things that would effectively be reverted if reverting local changes. And when listing local changes, we should add a checkbox to hide/display changes that are environmental but not the result of a user action. ## Changes The "Show local changes" view now displays a checkbox to show (default) / hide environmental changes: <img width="1037" height="797" alt="Screenshot 2025-12-22 at 15 43 29" src="https://github.com/user-attachments/assets/c1d50f12-f778-4227-8777-4a0d750d2aa3" /> <img width="1038" height="804" alt="Screenshot 2025-12-22 at 15 43 36" src="https://github.com/user-attachments/assets/84530982-ed9e-40c8-9134-e98fddf447cb" /> The "Revert local changes" is hiding the changes that would not be reverted: <img width="1035" height="794" alt="Screenshot 2025-12-22 at 15 43 51" src="https://github.com/user-attachments/assets/f388ecf6-7ed3-4430-8033-e968b8b08b60" /> If the version change was user-initiated because you have multiple versions of the NAR, then it would not be showing as an environmental change and the revert is actually possible (and working). <img width="1044" height="803" alt="Screenshot 2025-12-22 at 15 52 04" src="https://github.com/user-attachments/assets/4e26975d-547d-47cd-833a-902cd4c50347" /> # 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
