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

Adding Restore URL support to the new OM restore dialog for MI Server #25080

Merged
merged 15 commits into from
Dec 7, 2023

Conversation

ssreerama
Copy link
Contributor

@ssreerama ssreerama commented Nov 30, 2023

Adds the ability to support the restore database from URL, for a new restore dialog and for MI databases.

Note: TODO: Tasks tab shows multiple messages (unwanted one even in fail cases) will send a new PR if it takes time.

NewRestoreURL_MI

@coveralls
Copy link

coveralls commented Nov 30, 2023

Pull Request Test Coverage Report for Build 7123315438

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 41.604%

Totals Coverage Status
Change from base Build 7111709705: 0.0%
Covered Lines: 30818
Relevant Lines: 69389

💛 - Coveralls

@corivera
Copy link
Member

corivera commented Dec 2, 2023

Tried the changes out locally since they were a bit complicated to parse through just in text. I'm hitting an issue where the dialog is stuck in a spinning state after selecting a backup file from blob storage to use for the Restore from URL scenario. I'm using both of your ADS and STS branches for this change.

Looks like some planDetails fields are undefined when I'm hitting that problem. So like when trying to get the currentValue for the sourceDatabaseName or targetDatabaseName in the planDetails.

For my test scenario, I made a backup from a 2022 Docker instance, and then tried to select that backup file from a storage account when restoring to a newly created Managed Instance database. The backup file might end up being incompatible due to version differences, but I'm not even able to get to the step where I can Script out the operation or hit Restore. The buttons remain grayed out.

@ssreerama
Copy link
Contributor Author

Hey @corivera , I tried to repro the issue and couldn't, it is working fine. Below are the steps that I followed.

  1. Created a database and added a table with data in 2022 Docker instance.
  2. Using SSMS, I took a backup to URL.
  3. In Managed Instance Server, opened the restore database and selected the above backed up file from the blob storage.
  4. It took few seconds(hardly 4-6) to load the restore plan with the selected one.
  5. Selected a new database name (as we cannot restore on existing DB in MI).
  6. both script and restore button worked and I can see the new database.

Please correct me if I missed any step. Thanks

@ssreerama
Copy link
Contributor Author

Able to found couple of issues with Docker and fixed them also, added URL support to on-prem servers. (MI supports only URL, all other supports database/back-up files/ URL)

@ssreerama ssreerama merged commit 0c8c730 into main Dec 7, 2023
12 checks passed
@ssreerama ssreerama deleted the sai/restoreUrl branch December 7, 2023 16:06
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.

Add URL support to the new Restore dialog for the MI Servers
4 participants