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

[#6758] Platform: Reuse on-premise instance once the instance got delete. #6970

Merged
merged 12 commits into from
Feb 16, 2021

Conversation

mahendranbhat
Copy link
Contributor

@mahendranbhat mahendranbhat commented Jan 22, 2021

Description: Once we delete the onpremis universe, we have to clear the node instance so that we can use the node to create another universe.

Testing: :

  1. Add instance under onpremis
  2. Created the universe with the instance (failed)
  3. Delete the universe .
  4. Used the same instance to create another universe.

[info] Passed: Total 1141, Failed 0, Errors 0, Passed 1137, Skipped 4 [success] Total time: 707 s, completed 20 Jan, 2021 12:15:09 PM

@CLAassistant
Copy link

CLAassistant commented Jan 22, 2021

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ mahendranbhat
❌ mahendra bhat


mahendra bhat seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@Arnav15 Arnav15 changed the title [#6758] Platform: Reuse onpremis instance once the instance got delete. [#6758] Platform: Reuse on-premise instance once the instance got delete. Jan 22, 2021
@mahendranbhat mahendranbhat requested a review from Arnav15 January 27, 2021 12:43
Copy link
Contributor

@SergeyPotachev SergeyPotachev left a comment

Choose a reason for hiding this comment

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

  1. Cover these changes with junit tests.
  2. When this problem occurs? Only when on-prem instance doesn't have public IP? Or in both cases (with and w/o public IP)? I want to know the root cause because not long time ago this functionality worked.

@mahendranbhat
Copy link
Contributor Author

mahendranbhat commented Jan 28, 2021

  1. Cover these changes with junit tests.
  2. When this problem occurs? Only when on-prem instance doesn't have public IP? Or in both cases (with and w/o public IP)? I want to know the root cause because not long time ago this functionality worked.

@SergeyPotachev

  1. As mentioned in the description, checked with @Arnav15 about the test cases.
  2. This happens only when the node doesn't have private ip. Currently, our on-prem universe creation is failing in our local. When you delete the universe it didn't clear the onprem instance ( to reuse it to create the new universe as shown in the ticket )

@SergeyPotachev
Copy link
Contributor

SergeyPotachev commented Jan 28, 2021

  1. Cover these changes with junit tests.

@SergeyPotachev

  1. As mentioned in the description, checked with @Arnav15 about the test cases.

Initially I didn't pay attention on this part of comments, but now I disagree with this:
You can't write junit test for complete check of a universe deletion, but (!) you can write a test (and I can prove that it is not too difficult) to check this one function only. One test is for a case when your code is executed, another test - when it is not.
Do call the function and then check that according node details are cleaned or not cleaned. The only thing here which can be not easy - to prepare a correctly filled universe.

@mahendranbhat mahendranbhat merged commit 5466bfd into yugabyte:master Feb 16, 2021
polarweasel pushed a commit to lizayugabyte/yugabyte-db that referenced this pull request Mar 9, 2021
… got delete. (yugabyte#6970)

Summary:
Once we delete the on-premise universe, we have to clear the node instance so that we can use the node to create another universe.

Testing:
1. Add instance under on-premise
2. Created the universe with the instance ( should get failed)
3. Delete the universe.
4. Used the same instance to create another universe. ( should be possible after the change )

Reviewed by: Sergey Potachev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[platform] Unable to reuse On-premise instance incase previouse universe failed / deleted
4 participants