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

perf: Optimization of ZIP streaming decompression #1057

Open
wants to merge 59 commits into
base: dev/exp
Choose a base branch
from

Conversation

iamscottxu
Copy link
Contributor

@iamscottxu iamscottxu commented Aug 29, 2024

#1037 的优化,此分支可能不稳定,不要合并,如需合并合并#1037

  • 将重试机制从单次压缩包内文件下载前移到单次数据流读取,当单个压缩包内的文件下载到一半失败时无需将其整个文件重新下载;✔️
  • 将域名解析和解析的IP地址可用性检测从单次压缩包内文件下载前移到整个压缩包下载阶段,并均衡地分配服务器节点(如果DNS服务器返回多个可用IP地址);✔️
  • 升级时,先获取删除文件列表和差异文件,根据删除文件列表删除文件后,边下载,边解压,边合并。(部分实现)✔️;
  • 升级时,先获取差异文件列表,边下载,边解压,边合并。

Signed-off-by: scottxu <[email protected]>

# Conflicts:
#	src/Starward.Language/Lang.resx
#	src/Starward.Language/Lang.zh-CN.resx
…cause unexpected behavior after a traditional download mode task was started

Signed-off-by: scottxu <[email protected]>
…a streaming download was retried

Signed-off-by: scottxu <[email protected]>
…rrectly caught as `TaskCanceledException`

Signed-off-by: scottxu <[email protected]>
…tialDownloadException was thrown

Signed-off-by: scottxu <[email protected]>
… fixed the bug in which the progress was displayed incorrectly after the download was paused and restarted

Signed-off-by: OsakaRuma <[email protected]>
…completion or cancellation when streaming downloads

Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward.Language/Lang.es-ES.resx
#	src/Starward.Language/Lang.it-IT.resx
#	src/Starward.Language/Lang.ja-JP.resx
#	src/Starward.Language/Lang.ko-KR.resx
#	src/Starward.Language/Lang.ru-RU.resx
#	src/Starward.Language/Lang.th-TH.resx
…ize streaming download speed

Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward.Core.ZipStreamDownload/FastZipStreamDownloadTask.partial.cs
…e few files in the compressed package during streaming download

Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward/Services/Download/InstallGameService.cs
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward/Services/Download/InstallGameService.cs
…re were multiple steps of the task when installing the game

Signed-off-by: OsakaRuma <[email protected]>
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward.Language/Lang.de-DE.resx
#	src/Starward.Language/Lang.es-ES.resx
#	src/Starward.Language/Lang.it-IT.resx
#	src/Starward.Language/Lang.ja-JP.resx
#	src/Starward.Language/Lang.ko-KR.resx
#	src/Starward.Language/Lang.ru-RU.resx
#	src/Starward.Language/Lang.th-TH.resx
#	src/Starward.Language/Lang.vi-VN.resx
#	src/Starward/Services/Download/InstallGameManager.cs
#	src/Starward/Services/Download/InstallGameService.cs
Signed-off-by: OsakaRuma <[email protected]>

# Conflicts:
#	src/Starward/Services/Download/InstallGameService.cs
@iamscottxu iamscottxu force-pushed the streamdownload_optimization branch from a4cf2c7 to 533129e Compare October 17, 2024 12:57
…the list of files to be deleted, delete the files in the list, then download the files to a temporary folder, and finally move the files.

Signed-off-by: OsakaRuma <[email protected]>
@iamscottxu iamscottxu force-pushed the streamdownload_optimization branch from 1f6ff36 to e698cb1 Compare October 19, 2024 08:56
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.

1 participant