Skip to content

Commit

Permalink
[enhance](Regression) Construct Azure format url when running regress…
Browse files Browse the repository at this point in the history
…ion tests on azure cloud (apache#36739)

The file url's format on azure Blob is not S3-compatible. This pr
returns the correct url when running on Azure Cloud.
  • Loading branch information
ByteYue authored Jun 24, 2024
1 parent 89a6f12 commit 3dbad0d
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -771,6 +771,11 @@ class Suite implements GroovyInterceptable {

String getS3Url() {
String s3BucketName = context.config.otherConfigs.get("s3BucketName");
if (context.config.otherConfigs.get("s3Provider") == "AZURE") {
String accountName = context.config.otherConfigs.get("ak");
String s3Url = "http://${accountName}.blob.core.windows.net/${s3BucketName}"
return s3Url
}
String s3Endpoint = context.config.otherConfigs.get("s3Endpoint");
String s3Url = "http://${s3BucketName}.${s3Endpoint}"
return s3Url
Expand Down

0 comments on commit 3dbad0d

Please sign in to comment.