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

Add object deletion test to work around MinIO bug. #6

Closed
Foxcapades opened this issue Aug 16, 2024 · 3 comments
Closed

Add object deletion test to work around MinIO bug. #6

Foxcapades opened this issue Aug 16, 2024 · 3 comments
Assignees

Comments

@Foxcapades
Copy link
Member

MinIO with site replication has a bug where objects may still be available for a short window after a successful delete request.

This causes issues in cases where we clear a workspace and test for that workspace's existence within a short window as we will incorrectly return that the workspace does exist even when it should be deleted.

The object delete code should be updated to block thread/coroutine execution until the target object is confirmed deleted by followup calls to MinIO returning 404s.

This means:

  1. Request a target object's deletion from MinIO
  2. Stat the target object repeatedly until MinIO returns a 404
  3. Return to caller
@Foxcapades
Copy link
Member Author

This issue is slightly complicated by the introduction of blocking. For services that are bound directly to Java threads the delay between stat calls to MinIO should be implemented via Thread.sleep, however in services making use of Kotlin's coroutine API, the delay would be implemented using suspend functions and delay.

@Foxcapades
Copy link
Member Author

To keep the door open for s34k's move to a more idiomatic Kotlin implementation as well as any future coroutine based services, I will adjust the API to use suspend functions and alter the async platform to wrap them and bind them to the current thread.

@Foxcapades
Copy link
Member Author

Handled in #8

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

No branches or pull requests

1 participant