Delete unneeded actions and selectors in apitokens clusterInitBundles integrations#5202
Merged
pedrottimark merged 1 commit intomasterfrom Mar 13, 2023
Conversation
|
Images are ready for the commit at 16c4e2c. To use with deploy scripts, first |
vjwilson
approved these changes
Mar 13, 2023
JoukoVirtanen
pushed a commit
that referenced
this pull request
Mar 20, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Another warm up exercise after returning from week away from code. The following analysis from November 2022.
Found while researching minimum unneeded code in #3759
One more step toward deleting sagas for integrations.
Analysis of reducers/apitokens.js
Find dispatch of actions:
requestactionFind reference to selectors:
Analysis of reducers/clusterInitBundles.js
Find dispatch of actions:
requestactionFind reference to selectors
Analysis of reducers/integrations
Find dispatch of actions:
Find reference to selectors:
Interpretation for reducers
Integrations container code:
does dispatch fetch actions.
does dispatch revoke action for API Token
does not dispatch revoke action for Cluster Init Bundle:
DeleteClusterInitBundleConfirmationModalcomponent calls the service function.does not dispatch generate actions:
useIntegrationActionshook calls the service functionsdoes not dispatch
testIntegrationnorsaveIntegrationactionsuseIntegrationActionshook calls the service functionsdoes not dispatch any Wizard or Create actions
does refer to get selectors
does not refer to any Wizard or Current or CreateState selectors
Interpretation for sagas/apiTokenSagas.js
Delete
generateAPITokenandwatchGenerateRequestbecause:Delete
types.GENERATE_API_TOKEN.SUCCESSforgetAPITokensbecause:Delete
watchModalOpenbecause:Interpretation for sagas/clusterInitBundleSagas.js
Delete
generateClusterInitBundleandwatchGenerateRequestbecause:Delete
types.GENERATE_CLUSTER_INIT_BUNDLEforgetClusterInitBundlesbecause:Delete
requestFetchRolesandwatchModalOpenbecause:Interpretation for sagas/integrationSagas.js
Everything is needed.
Analysis of integration tests
Residue
revokeAPITokenaction with service function call in parallel withrevokeClusterInitBundlewithin Integrations container code.useFetchIntegrationsbehavior to request both apitokens and clusterinitbundles when only one or the other changed.Checklist
Unit test and regression tests addedTesting Performed
yarn lintin uiyarn buildin uiwc build/static/js/*.jsin uiyarn cypress-openin ui/apps/platform