Skip to content

Commit

Permalink
try to fix test on travis
Browse files Browse the repository at this point in the history
  • Loading branch information
nextdude committed Apr 4, 2023
1 parent 52b3d63 commit 538316d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ case class IcebergSourceConfig[ADT <: FlinkEvent](
TableLoader
.fromCatalog(common.catalogLoader, common.tableIdentifier)
)
logger.debug(s"setting properties: $propertiesMap")
sourceBuilder.setAll(propertiesMap)
if (!batch) {
streamingStartingStrategy.foreach(ss =>
sourceBuilder.streamingStartingStrategy(ss)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ class IcebergConfigSpec extends PropSpec with TestContainersForAll {
isSink: Boolean,
otherConfig: String = ""): String = {
val sourceOrSink: String = if (isSink) "sink" else "source"
val creds = awsCreds(ls)
s"""|${sourceOrSink}s {
| iceberg-$sourceOrSink {
| $otherConfig
Expand All @@ -145,6 +146,8 @@ class IcebergConfigSpec extends PropSpec with TestContainersForAll {
| uri = "${icebergEndpoint(ib)}"
| io-impl = "org.apache.iceberg.aws.s3.S3FileIO"
| s3.endpoint = "${s3Endpoint(ls)}"
| s3.access-key-id = "${creds.accessKeyId()}"
| s3.secret-access-key = "${creds.secretAccessKey()}"
| warehouse = "s3://$bucketName"
| }
| namespace = "testing.tables"
Expand Down Expand Up @@ -200,8 +203,8 @@ class IcebergConfigSpec extends PropSpec with TestContainersForAll {
val props = Map(
AwsProperties.S3FILEIO_ACCESS_KEY_ID -> creds.accessKeyId(),
AwsProperties.S3FILEIO_SECRET_ACCESS_KEY -> creds.secretAccessKey(),
AwsProperties.S3FILEIO_PATH_STYLE_ACCESS -> true,
AwsProperties.CLIENT_ASSUME_ROLE_REGION -> ls.region.toString,
AwsProperties.S3FILEIO_PATH_STYLE_ACCESS -> "true",
"client.region" -> ls.region.toString,
CatalogProperties.CATALOG_IMPL -> "org.apache.iceberg.rest.RESTCatalog",
CatalogProperties.URI -> icebergEndpoint(ib),
CatalogProperties.WAREHOUSE_LOCATION -> s"s3://$bucketName",
Expand Down Expand Up @@ -262,6 +265,7 @@ class IcebergConfigSpec extends PropSpec with TestContainersForAll {
)}
|sinks { print-sink {} }
|""".stripMargin
println(s"CONFIG: $configStr")
getIdentityTableStreamJobRunner[E, MySimpleADT](
configStr,
checkResultsOpt = Some(checkResults)
Expand Down

0 comments on commit 538316d

Please sign in to comment.