Skip to content

Commit

Permalink
Enable Concurrent safety on Bulk Load (#2744)
Browse files Browse the repository at this point in the history
  • Loading branch information
prasar-ashutosh authored Apr 3, 2024
1 parent 5d2754a commit 907b2a9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,10 @@ public LogicalPlan buildLogicalPlanForPreActions(Resources resources)
{
operations.add(Create.of(false, externalDataset));
}
if (options().enableConcurrentSafety())
{
operations.add(Create.of(true, lockInfoDataset().orElseThrow(IllegalStateException::new).get()));
}
return LogicalPlan.of(operations);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -744,6 +744,7 @@ private List<IngestorResult> performBulkLoad(Datasets datasets, Transformer<SqlG
Executor<SqlGen, TabularData, SqlPlan> executor, GeneratorResult generatorResult,
IngestMode ingestMode, SchemaEvolutionResult schemaEvolutionResult)
{
acquireLock();
List<IngestorResult> results = new ArrayList<>();
Map<String, PlaceholderValue> placeHolderKeyValues = extractPlaceHolderKeyValues(datasets, executor, planner, transformer, ingestMode, Optional.empty());

Expand Down

0 comments on commit 907b2a9

Please sign in to comment.