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

[DR-3356] Ensure that ingests always exclusively lock the dataset when bulk mode is set to true #1539

Merged
merged 1 commit into from
Nov 15, 2023

Conversation

nmalfroy
Copy link
Contributor

This feels safe to do since the only real reason someone would use bulk is to speed up file ingests. This may lead to datasets being exclusively locked more than they should (in the case where there are no files) but that feels like a reasonable tradeoff

…e is set to true

This feels safe to do since the only real reason someone would use bulk is to speed up file ingests.  This may lead to datasets being exclusively locked more than they should (in the case where there are no files) but that feels like a reasonable tradeoff
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

Copy link
Contributor

@okotsopoulos okotsopoulos left a comment

Choose a reason for hiding this comment

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

Thanks for fixing! I double checked our Swagger definition and no changes to documentation are required there (it presently indicates that a combined ingest with bulk mode enabled will exclusively lock the dataset, so this brings the behavior in line with that expectation).

@@ -142,7 +142,12 @@ public DatasetIngestFlight(FlightMap inputParameters, Object applicationContext)
.forEach(s -> this.addStep(s.step(), s.retryRule()));
}

addStep(new LockDatasetStep(datasetService, datasetId, true), lockDatasetRetry);
// Originally we didn't exclusively lock the dataset, the thinking being that there might
Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for adding the reasoning here!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Of course! I want to be nicer to future us :)

@nmalfroy nmalfroy merged commit ec8f753 into develop Nov 15, 2023
@nmalfroy nmalfroy deleted the dr-3356-nm-fix-bulk-locking branch November 15, 2023 14:59
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