-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Fleet] Fixing unnecessary network requests on showing Fleet Server on prem instructions #117647
Conversation
Pinging @elastic/fleet (Team:Fleet) |
...eet/sections/agents/agent_requirements_page/components/fleet_server_on_prem_instructions.tsx
Outdated
Show resolved
Hide resolved
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.
🚀 Thanks for fixing this!
We should probably backport this to 7.16 what do you think?
@kpollich are you okay with latest changes? I can't merge until it shows as change requested |
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.
🚀
@elasticmachine merge upstream |
💚 Build Succeeded
Metrics [docs]Page load bundle
History
To update your PR or re-run it, just comment with: |
…n prem instructions (elastic#117647) * removed fn dependency * fixing useDefaultOutput * fixed tslint
…n prem instructions (elastic#117647) * removed fn dependency * fixing useDefaultOutput * fixed tslint
…n prem instructions (#117647) (#117867) * removed fn dependency * fixing useDefaultOutput * fixed tslint Co-authored-by: Julia Bardi <[email protected]>
…n prem instructions (#117647) (#117866) * removed fn dependency * fixing useDefaultOutput * fixed tslint Co-authored-by: Julia Bardi <[email protected]>
Fixing a bug I observed in v7.16, v8.0
When opening Fleet UI for the first time, there are continuous
/settings
and/outputs
network calls being made (~3k/min).By digging in the code, it seems related to
useEffect
havingrefresh
function as dependency.https://github.com/elastic/kibana/blob/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_requirements_page/components/fleet_server_on_prem_instructions.tsx#L281
https://github.com/elastic/kibana/blob/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_requirements_page/components/fleet_server_on_prem_instructions.tsx#L701
By removing this dependency, the extra network requests no longer happen, only when the
Fleet settings
modal is toggled as expected.This feature was initially implemented here: #103550