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

fix(localpv): handle case of BDC-BD taking longer time #1262

Merged
merged 1 commit into from
Jun 7, 2019
Merged

fix(localpv): handle case of BDC-BD taking longer time #1262

merged 1 commit into from
Jun 7, 2019

Conversation

kmova
Copy link
Contributor

@kmova kmova commented Jun 7, 2019

When a PVC with Local PV host device is triggered,
Local PV provisioner will create BDC and waits
for 60 seconds to get the BD attached. Post that
it returns the control back to K8s.

K8s will re-attempt to create a PV, and in
the second iteration - the Local PV provisioner
will check if the BDC was already created
and will try to re-use it instead of creating another one.

Creating another BDC, in the setup where BD/BDC takes
longer will never result in PV getting created. Also,
timing out and reporting the error to user will make the
process intuitive when BD/BDC process is taking longer.

Signed-off-by: kmova [email protected]

What this PR does / why we need it:

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #

Special notes for your reviewer:

Checklist:

  • Fixes #
  • Labelled this PR & related issue with documentation tag
  • PR messages has document related information
  • Labelled this PR & related issue with breaking-changes tag
  • PR messages has breaking changes related information
  • Labelled this PR & related issue with requires-upgrade tag
  • PR messages has upgrade related information
  • Commit has unit tests
  • Commit has integration tests

When a PVC with Local PV host device is triggered,
Local PV provisioner will create BDC and waits
for 60 seconds to get the BD attached. Post that
it returns the control back to K8s.

K8s will re-attempt to create a PV, and in
the second iteration - the Local PV provisioner
will check if the BDC was already created
and will try to re-use it instead of creating another one.

Creating another BDC, in the setup where BD/BDC takes
longer will never result in PV getting created. Also,
timing out and reporting the error to user will make the
process intuitive when BD/BDC process is taking longer.

Signed-off-by: kmova <[email protected]>
@kmova kmova requested review from AmitKumarDas and vishnuitta June 7, 2019 09:03
Copy link

@AmitKumarDas AmitKumarDas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@AmitKumarDas AmitKumarDas merged commit df079dc into openebs-archive:master Jun 7, 2019
shubham14bajpai pushed a commit to shubham14bajpai/maya that referenced this pull request Jun 7, 2019
…ve#1262)

When a PVC with Local PV host device is triggered,
Local PV provisioner will create BDC and waits
for 60 seconds to get the BD attached. Post that
it returns the control back to K8s.

K8s will re-attempt to create a PV, and in
the second iteration - the Local PV provisioner
will check if the BDC was already created
and will try to re-use it instead of creating another one.

Creating another BDC, in the setup where BD/BDC takes
longer will never result in PV getting created. Also,
timing out and reporting the error to user will make the
process intuitive when BD/BDC process is taking longer.

Signed-off-by: kmova <[email protected]>
shubham14bajpai pushed a commit to shubham14bajpai/maya that referenced this pull request Jun 7, 2019
…ve#1262)

When a PVC with Local PV host device is triggered,
Local PV provisioner will create BDC and waits
for 60 seconds to get the BD attached. Post that
it returns the control back to K8s.

K8s will re-attempt to create a PV, and in
the second iteration - the Local PV provisioner
will check if the BDC was already created
and will try to re-use it instead of creating another one.

Creating another BDC, in the setup where BD/BDC takes
longer will never result in PV getting created. Also,
timing out and reporting the error to user will make the
process intuitive when BD/BDC process is taking longer.

Signed-off-by: kmova <[email protected]>
prateekpandey14 pushed a commit that referenced this pull request Jun 7, 2019
When a PVC with Local PV host device is triggered,
Local PV provisioner will create BDC and waits
for 60 seconds to get the BD attached. Post that
it returns the control back to K8s.

K8s will re-attempt to create a PV, and in
the second iteration - the Local PV provisioner
will check if the BDC was already created
and will try to re-use it instead of creating another one.

Creating another BDC, in the setup where BD/BDC takes
longer will never result in PV getting created. Also,
timing out and reporting the error to user will make the
process intuitive when BD/BDC process is taking longer.

Signed-off-by: kmova <[email protected]>
@kmova kmova deleted the handle-bdc-race branch June 15, 2019 03:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants