forked from pflooky/data-caterer-example
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgrade to 0.10.9, add in example plan using ODCS
- Loading branch information
Showing
5 changed files
with
47 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
name: Run performance benchmark tests | ||
permissions: | ||
pull-requests: write | ||
|
||
on: | ||
push: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/main/java/io/github/datacatering/plan/AdvancedODCSJavaPlanRun.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package io.github.datacatering.plan; | ||
|
||
import io.github.datacatering.datacaterer.javaapi.api.PlanRun; | ||
|
||
import java.util.Map; | ||
|
||
public class AdvancedODCSJavaPlanRun extends PlanRun { | ||
{ | ||
var accountTask = csv("my_csv", "/opt/app/data/account-odcs", Map.of("saveMode", "overwrite", "header", "true")) | ||
.schema(metadataSource().openDataContractStandard("/opt/app/mount/odcs/full-example.yaml")) | ||
.count(count().records(100)); | ||
|
||
var conf = configuration().enableGeneratePlanAndTasks(true) | ||
.enableGenerateValidations(true) | ||
.generatedReportsFolderPath("/opt/app/data/report"); | ||
|
||
execute(conf, accountTask); | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
src/main/scala/io/github/datacatering/plan/AdvancedODCSPlanRun.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package io.github.datacatering.plan | ||
|
||
import io.github.datacatering.datacaterer.api.PlanRun | ||
|
||
class AdvancedODCSPlanRun extends PlanRun { | ||
|
||
val accountTask = csv("customer_accounts", "/opt/app/data/customer/account-odcs", Map("header" -> "true")) | ||
.schema(metadataSource.openDataContractStandard("/opt/app/mount/odcs/full-example.yaml")) | ||
.count(count.records(100)) | ||
|
||
val conf = configuration.enableGeneratePlanAndTasks(true) | ||
.generatedReportsFolderPath("/opt/app/data/report") | ||
|
||
execute(conf, accountTask) | ||
} |