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

Fix SyncPropagation Defer #4924

Merged
merged 1 commit into from
Nov 11, 2024
Merged

Fix SyncPropagation Defer #4924

merged 1 commit into from
Nov 11, 2024

Conversation

kobergj
Copy link
Contributor

@kobergj kobergj commented Nov 11, 2024

Fixes the defer in the sync propagation. Removes the unnecessary Close call.

@micbar
Copy link
Member

micbar commented Nov 11, 2024

@kobergj @aduffeck We have a failing test in https://drone.owncloud.com/cs3org/reva/5521/32/7

@kobergj
Copy link
Contributor Author

kobergj commented Nov 11, 2024

It is different tests failing. Same step (posixfs-integration-tests-4), but different tests. They are flaky. Both were green on the other run.

Run 1
coreApiWebdavDelete/deleteFile.feature:48

Run 2
coreApiTrashbinRestore/trashbinRestore.feature:537

Run 3
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:28
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:29
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:51
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:52
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:72
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:73
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:95
coreApiWebdavEtagPropagation2/restoreFromTrash.feature:96

4 times is a charm ✔️

cc @ScharfViktor @aduffeck

if err == nil && cerr != nil && !errors.Is(cerr, os.ErrClosed) {
err = cerr // only overwrite err with en error from close if the former was nil
}
_ = os.Remove(f.Name())
Copy link
Contributor

Choose a reason for hiding this comment

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

Note: this is the Remove is dropped on purpose, so the inode of the parent lock file remains the same when propagating multiple files concurrently on NFS. This prevents stale NFS file handle errors

@kobergj kobergj merged commit e77dd61 into cs3org:edge Nov 11, 2024
10 checks passed
@kobergj kobergj deleted the FixSyncDefers branch November 11, 2024 16:29
@micbar micbar mentioned this pull request Nov 12, 2024
87 tasks
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.

3 participants