Skip to content

Commit

Permalink
[test](fix) replace hardcode s3BucketName
Browse files Browse the repository at this point in the history
  • Loading branch information
stephen committed Jul 15, 2024
1 parent 4acc692 commit 3f883bb
Show file tree
Hide file tree
Showing 17 changed files with 328 additions and 313 deletions.
23 changes: 12 additions & 11 deletions regression-test/suites/export_p0/test_outfile_exception.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ import java.nio.file.Files
import java.nio.file.Paths

suite("test_outfile_exception") {

def s3Endpoint = getS3Endpoint()
def s3Region = getS3Region()
def tableName = "outfile_exception_test"
sql """ DROP TABLE IF EXISTS ${tableName} """
sql """
Expand Down Expand Up @@ -70,8 +71,8 @@ suite("test_outfile_exception") {
into outfile "s3://ftw-datalake-test/test_outfile/exp_"
format as parquet
properties(
"s3.endpoint" = "https://cos.ap-beijing.myqcloud.com",
"s3.region" = "ap-beijing",
"s3.endpoint" = "https://${s3Endpoint}",
"s3.region" = "${s3Region}",
"s3.access_key"= "xx",
"s3.secret_key" = "yy"
);
Expand All @@ -89,8 +90,8 @@ suite("test_outfile_exception") {
into outfile "s3://ftw-datalake-test/test_outfile/exp_"
format as orc
properties(
"s3.endpoint" = "https://cos.ap-beijing.myqcloud.com",
"s3.region" = "ap-beijing",
"s3.endpoint" = "https://${s3Endpoint}",
"s3.region" = "${s3Region}",
"s3.access_key"= "xx",
"s3.secret_key" = "yy"
);
Expand All @@ -108,8 +109,8 @@ suite("test_outfile_exception") {
into outfile "s3://ftw-datalake-test/test_outfile/exp_"
format as csv
properties(
"s3.endpoint" = "https://cos.ap-beijing.myqcloud.com",
"s3.region" = "ap-beijing",
"s3.endpoint" = "https://${s3Endpoint}",
"s3.region" = "${s3Region}",
"s3.access_key"= "xx",
"s3.secret_key" = "yy"
);
Expand All @@ -127,8 +128,8 @@ suite("test_outfile_exception") {
into outfile "s3://ftw-datalake-test/test_outfile/exp_"
format as csv_with_names
properties(
"s3.endpoint" = "https://cos.ap-beijing.myqcloud.com",
"s3.region" = "ap-beijing",
"s3.endpoint" = "https://${s3Endpoint}",
"s3.region" = "${s3Region}",
"s3.access_key"= "xx",
"s3.secret_key" = "yy"
);
Expand All @@ -146,8 +147,8 @@ suite("test_outfile_exception") {
into outfile "s3://ftw-datalake-test/test_outfile/exp_"
format as csv_with_names_and_types
properties(
"s3.endpoint" = "https://cos.ap-beijing.myqcloud.com",
"s3.region" = "ap-beijing",
"s3.endpoint" = "https://${s3Endpoint}",
"s3.region" = "${s3Region}",
"s3.access_key"= "xx",
"s3.secret_key" = "yy"
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ suite("test_external_catalog_mysql", "p2") {
"user"="${extMysqlUser}",
"password"="${extMysqlPassword}",
"jdbc_url"="jdbc:mysql://${extMysqlHost}:${extMysqlPort}/ssb?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai&useSSL=false",
"driver_url"="https://doris-community-bj-1308700295.cos.ap-beijing.myqcloud.com/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_url"="https://${getS3BucketName()}.${getS3Endpoint()}/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_class"="com.mysql.cj.jdbc.Driver"
);
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ suite("test_external_resource_mysql", "p2") {
"user"="${extMysqlUser}",
"password"="${extMysqlPassword}",
"jdbc_url"="jdbc:mysql://${extMysqlHost}:${extMysqlPort}/ssb?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai&useSSL=false",
"driver_url"="https://doris-community-bj-1308700295.cos.ap-beijing.myqcloud.com/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_url"="https://${getS3BucketName()}.${getS3Endpoint()}/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_class"="com.mysql.cj.jdbc.Driver"
);
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ suite("test_external_resource_mysql_nereids", "p2") {
"user"="${extMysqlUser}",
"password"="${extMysqlPassword}",
"jdbc_url"="jdbc:mysql://${extMysqlHost}:${extMysqlPort}/ssb?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai&useSSL=false",
"driver_url"="https://doris-community-bj-1308700295.cos.ap-beijing.myqcloud.com/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_url"="https://${getS3BucketName()}.${getS3Endpoint()}/jdbc_drivers/mysql-connector-java-8.0.25.jar",
"driver_class"="com.mysql.cj.jdbc.Driver"
);
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ suite("test_external_pg", "p2") {
"user"="${extPgUser}",
"password"="${extPgPassword}",
"jdbc_url"="jdbc:postgresql://${extPgHost}:${extPgPort}/ssb?currentSchema=ssb&useCursorFetch=true",
"driver_url"="https://doris-community-bj-1308700295.cos.ap-beijing.myqcloud.com/jdbc_drivers/postgresql-42.5.0.jar",
"driver_url"="https://${getS3BucketName()}.${getS3Endpoint()}/jdbc_drivers/postgresql-42.5.0.jar",
"driver_class"="org.postgresql.Driver"
);
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ suite("test_external_pg_nereids", "p2") {
"user"="${extPgUser}",
"password"="${extPgPassword}",
"jdbc_url"="jdbc:postgresql://${extPgHost}:${extPgPort}/ssb?currentSchema=ssb&useCursorFetch=true",
"driver_url"="https://doris-community-bj-1308700295.cos.ap-beijing.myqcloud.com/jdbc_drivers/postgresql-42.5.0.jar",
"driver_url"="${getS3BucketName()}.${getS3Endpoint()}/jdbc_drivers/postgresql-42.5.0.jar",
"driver_class"="org.postgresql.Driver"
);
"""
Expand Down
2 changes: 1 addition & 1 deletion regression-test/suites/github_events_p2/load.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ suite("load") {
ak "${getS3AK()}"
sk "${getS3SK()}"
endpoint "http://${getS3Endpoint()}"
region "ap-beijing"
region "${getS3Region()}"
repository "regression_test_github_events"
snapshot "github_events"
timestamp "2022-03-23-12-19-51"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
// under the License.

suite("test_compress_type", "load_p0") {
def s3BucketName = getS3BucketName()
def tableName = "basic_data"

// GZ/LZO/BZ2/LZ4FRAME/DEFLATE/LZOP
Expand Down Expand Up @@ -50,18 +51,18 @@ suite("test_compress_type", "load_p0") {
]

def paths = [
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.gz",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.bz2",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.lz4",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.gz",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.bz2",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.lz4",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.gz",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.bz2",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.lz4",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.gz",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.bz2",
"s3://doris-build-1308700295/regression/load/data/basic_data.csv.lz4"
"s3://${s3BucketName}/regression/load/data/basic_data.csv.gz",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.bz2",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.lz4",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.gz",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.bz2",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.lz4",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.gz",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.bz2",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.lz4",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.gz",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.bz2",
"s3://${s3BucketName}/regression/load/data/basic_data.csv.lz4"
]
def labels = []

Expand All @@ -88,8 +89,8 @@ suite("test_compress_type", "load_p0") {
WITH S3 (
"AWS_ACCESS_KEY" = "$ak",
"AWS_SECRET_KEY" = "$sk",
"AWS_ENDPOINT" = "cos.ap-beijing.myqcloud.com",
"AWS_REGION" = "ap-beijing"
"AWS_ENDPOINT" = "${getS3Endpoint()}",
"AWS_REGION" = "${getS3Region()}"
)
properties(
"use_new_load_scan_node" = "true"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ suite("test_etl_failed", "load_p0") {
PROPERTIES ("replication_allocation" = "tag.location.default: 1");
"""
String label = "test_etl_failed"
String path = "s3://doris-build-1308700295/regression/load/data/etl_failure/etl-failure.csv"
String path = "s3://${getS3BucketName()}/regression/load/data/etl_failure/etl-failure.csv"
String format = "CSV"
String ak = getS3AK()
String sk = getS3SK()
Expand All @@ -46,8 +46,8 @@ suite("test_etl_failed", "load_p0") {
WITH S3 (
"AWS_ACCESS_KEY" = "$ak",
"AWS_SECRET_KEY" = "$sk",
"AWS_ENDPOINT" = "cos.ap-beijing.myqcloud.com",
"AWS_REGION" = "ap-beijing"
"AWS_ENDPOINT" = "${getS3Endpoint()}",
"AWS_REGION" = "${getS3Region()}"
)
PROPERTIES(
"use_new_load_scan_node" = "true",
Expand Down
Loading

0 comments on commit 3f883bb

Please sign in to comment.