-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NIFI-9309: Include a uiOnly flag when requesting flow for a given pro… #5462
Conversation
Thanks for this improvement @markap14! The concept seems like a helpful improvement, but what do you think about changing the name of the flag to something different than Although the flag is descriptive in terms of the purpose, it seems somewhat more narrow than necessary. Another REST API consumer may make use of the resource for some other purpose where a more optimized response is preferable, but not be related to a user interface. What do you think about something along the lines of |
@exceptionfactory i did consider some alternatives. I went with Typically, we do use a flag of |
Hi @markap14! I quickly tested your changes with a bigger flow (around 32_000 proceccors organized into multiple levels of groups) and the request time for variable in a group dropped significantly. Originally it was around 16 seconds and after applying your commit, it was somewhere between 140 and 150 milliseconds. This is a great improvement! Meanwile I take a look on the code itself. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I wrote earlier, this is a significant boost. I tried some other things in order to make it even faster (like minimising the walks on the flow graph), but neither of my tries made it faster without secreficing on the functionality side. So it LGTM.
...fi-framework-components/src/main/java/org/apache/nifi/events/VolatileBulletinRepository.java
Show resolved
Hide resolved
...ework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java
Show resolved
Hide resolved
…cess group. In that case, do not include the property descriptors, property values, etc. for Processors. When fetching Variable Registry, improved logic to cache the VariableImpact for each property value instead of parsing/recreating it every time. When fetching bulletins for a component, avoid filtering through all components' bulletins and instead only look at bulletins that might pertain to the appropriate component
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 on the front end changes.
+1 as well |
Thanks for the background @markap14, that is helpful. In light of that purpose, using It seems like changing the parameter to something along the lines of |
Thanks for the theory reviews all. Given the three +1's here I'll go ahead and merge. |
apache#5462) NIFI-9309: Include a uiOnly flag when requesting flow for a given process group. In that case, do not include the property descriptors, property values, etc. for Processors. When fetching Variable Registry, improved logic to cache the VariableImpact for each property value instead of parsing/recreating it every time. When fetching bulletins for a component, avoid filtering through all components' bulletins and instead only look at bulletins that might pertain to the appropriate component
…cess group. In that case, do not include the property descriptors, property values, etc. for Processors. When fetching Variable Registry, improved logic to cache the VariableImpact for each property value instead of parsing/recreating it every time. When fetching bulletins for a component, avoid filtering through all components' bulletins and instead only look at bulletins that might pertain to the appropriate component
Thank you for submitting a contribution to Apache NiFi.
Please provide a short description of the PR here:
Description of PR
Enables X functionality; fixes bug NIFI-YYYY.
In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:
For all changes:
Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?
Does your PR title start with NIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.
Has your PR been rebased against the latest commit within the target branch (typically
main
)?Is your initial contribution a single, squashed commit? Additional commits in response to PR reviewer feedback should be made on this branch and pushed to allow change tracking. Do not
squash
or use--force
when pushing to allow for clean monitoring of changes.For code changes:
mvn -Pcontrib-check clean install
at the rootnifi
folder?LICENSE
file, including the mainLICENSE
file undernifi-assembly
?NOTICE
file, including the mainNOTICE
file found undernifi-assembly
?.displayName
in addition to .name (programmatic access) for each of the new properties?For documentation related changes:
Note:
Please ensure that once the PR is submitted, you check GitHub Actions CI for build issues and submit an update to your PR as soon as possible.