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
(feat): Add create local volume set #9600
(feat): Add create local volume set #9600
Conversation
@@ -0,0 +1,47 @@ | |||
import * as React from 'react'; |
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.
@vbnrh @cloudbehl @bipuladh This is the new addition.
Rest of the files just migrated from ocs install flows to create-storage-system. The state is difefrent hence cant refactor them.
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.
Please review this.
}); | ||
}; | ||
|
||
export const CreateLocalVolumeSet: React.FC<CreateLocalVolumeSetProps> = ({ |
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.
This is the starting point.
const [csv, csvLoaded, csvLoadError] = useFetchCsv(LSO_OPERATOR); | ||
const { t } = useTranslation(); | ||
const [inProgress, setInProgress] = React.useState(false); | ||
const [error, setError] = React.useState(null); | ||
const [lvdInProgress, setLvdInProgress] = React.useState(false); | ||
const [lvdError, setLvdError] = React.useState(null); | ||
|
||
React.useEffect(() => { | ||
if (!csvLoadError && csvLoaded) { | ||
setLvdInProgress(true); | ||
k8sGet(NodeModel) | ||
.then(async (nodes) => { | ||
try { | ||
await createLocalVolumeDiscovery(nodes, csv?.metadata?.namespace, OCS_TOLERATION); | ||
setLvdInProgress(false); | ||
} catch (e) { |
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.
Cheking for csv from the new hook.
And creating discoveries for all the nodes.
9e5dd81
to
5c7d72c
Compare
...omponents/create-storage-system/create-storage-system-steps/create-local-volume-set/body.tsx
Outdated
Show resolved
Hide resolved
5c7d72c
to
fd4df7c
Compare
fd4df7c
to
f570cbf
Compare
...orage-system/create-storage-system-steps/create-local-volume-set/create-local-volume-set.tsx
Outdated
Show resolved
Hide resolved
...orage-system/create-storage-system-steps/create-local-volume-set/create-local-volume-set.tsx
Outdated
Show resolved
Hide resolved
...omponents/create-storage-system/create-storage-system-steps/create-local-volume-set/body.tsx
Outdated
Show resolved
Hide resolved
...omponents/create-storage-system/create-storage-system-steps/create-local-volume-set/body.tsx
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.
nit: change dir name to create-local-volume-set-step for consistency
...omponents/create-storage-system/create-storage-system-steps/create-local-volume-set/body.tsx
Show resolved
Hide resolved
042b521
to
b7feddc
Compare
/lgtm |
b7feddc
to
975ada4
Compare
/lgtm |
/retest |
975ada4
to
11dccbc
Compare
/lgtm |
- creating discoveries automatically - this is mostly the existing just now using new state object - separaeted the logic for fetching csv in hook. This will be helpful at a couple of places where we need to fetch csv for ocs and lso - installing lso automatically is not in this PR due to some issues and refactors. implements https://issues.redhat.com/browse/ODFE-94 Signed-off-by: Afreen Rahman <afrahman@redhat.com>
11dccbc
to
677ba5c
Compare
/LGTM |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: afreen23, bipuladh, GowthamShanmugam, SanjalKatiyar, vbnrh The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/test e2e-gcp-console |
implements https://issues.redhat.com/browse/ODFE-94
Signed-off-by: Afreen Rahman afrahman@redhat.com