Skip to content
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

Merged

Conversation

afreen23
Copy link
Contributor

  • 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

@openshift-ci openshift-ci bot requested review from rawagner and shyRozen July 23, 2021 06:19
@openshift-ci openshift-ci bot added component/ceph Related to ceph-storage-plugin kind/i18n Indicates issue or PR relates to internationalization or has content that needs to be translated approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jul 23, 2021
@@ -0,0 +1,47 @@
import * as React from 'react';
Copy link
Contributor Author

@afreen23 afreen23 Jul 23, 2021

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.

Copy link
Contributor Author

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> = ({
Copy link
Contributor Author

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.

Comment on lines 77 to 92
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) {
Copy link
Contributor Author

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.

@openshift-ci openshift-ci bot added the component/lso Related to local-storage-operator-plugin label Jul 23, 2021
Copy link
Contributor

@vbnrh vbnrh left a 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

@afreen23 afreen23 force-pushed the create-local-volume-set branch 2 times, most recently from 042b521 to b7feddc Compare July 23, 2021 12:20
@vbnrh
Copy link
Contributor

vbnrh commented Jul 23, 2021

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 23, 2021
@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
@bipuladh
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
@afreen23
Copy link
Contributor Author

/retest

@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
@SanjalKatiyar
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
 - 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>
@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
@GowthamShanmugam
Copy link
Contributor

/LGTM

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 24, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 24, 2021

[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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@afreen23
Copy link
Contributor Author

/test e2e-gcp-console

@openshift-merge-robot openshift-merge-robot merged commit 2a387fe into openshift:master Jul 24, 2021
@spadgett spadgett added this to the v4.9 milestone Jul 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. component/ceph Related to ceph-storage-plugin component/lso Related to local-storage-operator-plugin kind/i18n Indicates issue or PR relates to internationalization or has content that needs to be translated lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants