Skip to content

feat(k8s-dashboard): bump k8s dashboard api and refetch resource list without cache on resource change #2303

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

Conversation

floreks
Copy link
Member

@floreks floreks commented May 29, 2025

There are a couple of important changes here to allow proper dynamic header handling on refetch:

  • bump k8s dashboard API chart version to 7.13.0
  • updated all resource lists to pass query document instead of query hook
  • use lazy query instead of query in resource list
  • manually handle resource list polling since regular refetch with extra context data permanently overrides it causing all subsequent requests to contain extra data
  • expose lazy query as refetch to allow providing context with custom headers since regular refetch function only allow passing extra variables

This was the only way to ensure that only a single refetch request contains the Cache-Control: 'no-cache' header and regular polling requests do not, while avoiding double requests at the same time.

Test Plan

Locally

Checklist

  • If required, I have updated the Plural documentation accordingly.
  • I have added tests to cover my changes.
  • I have added a meaningful title and summary to convey the impact of this PR to a user.

Plural Flow: console

…d refactor query usage in components to allow dynamic headers on resource list queries
Copy link

linear bot commented May 29, 2025

@floreks floreks self-assigned this May 29, 2025
@floreks floreks added the enhancement New feature or request label May 29, 2025
@michaeljguarino michaeljguarino merged commit ea89446 into master May 30, 2025
11 checks passed
@michaeljguarino michaeljguarino deleted the sebastian/prod-3632-add-refetches-for-k8s-actions-in-dashbaord branch May 30, 2025 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants