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

reuse existing upload on duplicate request #8999

Conversation

arafubeatbox
Copy link
Contributor

@arafubeatbox arafubeatbox commented Jul 29, 2024

実装方針

  • PageBulkExportJob に revisionListHash を追加し、エクスポートする全てのページのその時点での revision の id からハッシュを作成して格納する。
  • 新規に作成された PageBulkExportJob に revisionListHash が追加された時点で、同じ hash を持つ export job がないかを確認し、ある場合いは attachment をコピーしてジョブを完了させる。

task

https://redmine.weseek.co.jp/issues/151412

Copy link

changeset-bot bot commented Jul 29, 2024

⚠️ No Changeset found

Latest commit: 90d15fe

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

…nto feat/147526-151412-reuse-upload-on-duplicate-request
…nto feat/147526-151412-reuse-upload-on-duplicate-request
…nto feat/147526-151412-reuse-upload-on-duplicate-request
…nto feat/147526-151412-reuse-upload-on-duplicate-request
Base automatically changed from feat/78039-151411-cancel-streams-on-export-job-abort to feat/page-bulk-export August 26, 2024 09:34
@arafubeatbox arafubeatbox marked this pull request as ready for review August 26, 2024 09:39
@@ -188,6 +207,9 @@ class PageBulkExportService {
objectMode: true,
write: async(page: PageDocument, encoding, callback) => {
try {
if (page.revision != null) {
revisionListHash.update(getIdForRef(page.revision).toString());
Copy link
Member

Choose a reason for hiding this comment

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

現在は getIdStringForRef というのがあります

@arafubeatbox arafubeatbox merged commit 1e65f0d into feat/page-bulk-export Aug 26, 2024
5 checks passed
@arafubeatbox arafubeatbox deleted the feat/147526-151412-reuse-upload-on-duplicate-request branch August 26, 2024 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants