Skip to content

Jetpack Section: Backup Status and Backup Complete#15633

Merged
momo-ozawa merged 8 commits intodevelopfrom
task/15191-backup-status
Jan 15, 2021
Merged

Jetpack Section: Backup Status and Backup Complete#15633
momo-ozawa merged 8 commits intodevelopfrom
task/15191-backup-status

Conversation

@momo-ozawa
Copy link
Copy Markdown
Contributor

@momo-ozawa momo-ozawa commented Jan 13, 2021

Part of #15191

  • Hooked up download backup APIs
    • Prepare downloadable backups
    • Get backup status (poll for status every second)
  • Added a new Backup Complete screen

Notes:

  • Styling isn't 100% complete
  • Buttons on Backup Complete screen are not hooked up yet
  • Error handling will be addressed in a separate PR

To test:

  1. My Site > Activity Log > rewindable activity cell
  2. Tap on ellipsis icon
  3. Tap on Download Backup
  4. Tap on Create downloadable file
    • ✅ The progress view should update (roughly 0% → 77% → 88%)
    • ✅ Once the backup is ready to download, the app should transition to the Backup Complete screen
Screen.Recording.2021-01-13.at.19.55.21.mov

PR submission checklist:

  • I have considered adding unit tests where possible.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@peril-wordpress-mobile
Copy link
Copy Markdown

peril-wordpress-mobile bot commented Jan 13, 2021

You can trigger an installable build for these changes by visiting CircleCI here.

@peril-wordpress-mobile
Copy link
Copy Markdown

peril-wordpress-mobile bot commented Jan 13, 2021

You can trigger optional UI/connected tests for these changes by visiting CircleCI here.

}

private func pollBackupStatus(for downloadID: Int) {
Timer.scheduledTimer(withTimeInterval: 1, repeats: true) { [weak self] timer in
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@zwarm 👋
On Android, what polling interval are you using for fetching the backup status?
I'm polling the backup status every second (just for now)

private let site: JetpackSiteRef
private let view: JetpackBackupStatusView

init(site: JetpackSiteRef,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Just a heads up, I had issues using the JetpackSiteRef for the scanning view because I later needed more metadata that the Blog entity contains. I recently switched to using Blog instead of JetpackSiteRef.

Not sure if you'll later need metadata such as site name, timezone, etc.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ah, good to know! Will switch to Blog instead if I end up needing that metadata. Thanks for the heads up! ❤️

@peril-wordpress-mobile
Copy link
Copy Markdown

Warnings
⚠️ PR has more than 500 lines of code changing. Consider splitting into smaller PRs if possible.

Generated by 🚫 dangerJS

@momo-ozawa momo-ozawa merged commit 3502105 into develop Jan 15, 2021
@momo-ozawa momo-ozawa deleted the task/15191-backup-status branch January 15, 2021 01:27
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.

3 participants