Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#1887 defaultTimestampTimeZone can be source type specific #1916

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,6 @@ object DefaultsByFormat {
private final val DefaultKeyName = "default"
private final val ObsoleteTimestampTimeZoneName = "defaultTimestampTimeZone"
private final val ObsoleteDateTimeZoneName = "defaultDateTimeZone"
private final val TimestampTimeZoneKeyName = "enceladus.defaultTimestampTimeZone"
private final val DateTimeZoneKeyName = "enceladus.defaultDateTimeZone"
private final val TimestampTimeZoneKeyName = "standardization.defaultTimestampTimeZone"
private final val DateTimeZoneKeyName = "standardization.defaultDateTimeZone"
}
4 changes: 2 additions & 2 deletions utils/src/test/resources/application.conf
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@
#system-wide time zone
timezone="UTC"

enceladus.defaultTimestampTimeZone.default="CET"
enceladus.defaultTimestampTimeZone.xml="Africa/Johannesburg"
standardization.defaultTimestampTimeZone.default="CET"
standardization.defaultTimestampTimeZone.xml="Africa/Johannesburg"
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class DefaultsByFormatSuite extends AnyFunSuite {
private val customTimestampConfig = new ConfigReader(
ConfigFactory.empty()
.withValue("defaultTimestampTimeZone", ConfigValueFactory.fromAnyRef("UTC")) // fallback to "obsolete"
.withValue("enceladus.defaultTimestampTimeZone.json", ConfigValueFactory.fromAnyRef("WrongTimeZone"))
.withValue("standardization.defaultTimestampTimeZone.json", ConfigValueFactory.fromAnyRef("WrongTimeZone"))
)

test("Format specific timestamp time zone override exists") {
Expand Down Expand Up @@ -56,9 +56,9 @@ class DefaultsByFormatSuite extends AnyFunSuite {
private val customDateConfig = new ConfigReader(
ConfigFactory.empty()
.withValue("defaultDateTimeZone", ConfigValueFactory.fromAnyRef("UTC")) // fallback to "obsolete"
.withValue("enceladus.defaultDateTimeZone.default", ConfigValueFactory.fromAnyRef("PST"))
.withValue("enceladus.defaultDateTimeZone.csv", ConfigValueFactory.fromAnyRef("JST"))
.withValue("enceladus.defaultDateTimeZone.parquet", ConfigValueFactory.fromAnyRef("Gibberish"))
.withValue("standardization.defaultDateTimeZone.default", ConfigValueFactory.fromAnyRef("PST"))
.withValue("standardization.defaultDateTimeZone.csv", ConfigValueFactory.fromAnyRef("JST"))
.withValue("standardization.defaultDateTimeZone.parquet", ConfigValueFactory.fromAnyRef("Gibberish"))
)

test("Format specific date time zone override exists") {
Expand Down