You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replace legacy formatting with `DateTimeFormatter` for better compatibility
with the `java.time` package, providing more precise and predictable behavior
This refactor follows AWS Athena's date-type partition projection format
(https://docs.aws.amazon.com/athena/latest/ug/partition-projection-supported-types.html)
in the description.
Additionally, this commit replaces the error-prone Supplier<Instant>
with a direct Instant type for `leftBound` and `rightBound`.
@@ -1582,7 +1582,7 @@ public void testPartitionProjectionInvalidTableProperties()
1582
1582
" partition_projection_enabled=true " +
1583
1583
")"))
1584
1584
.hasMessage("Column projection for column 'short_name1' failed. Property: 'partition_projection_range' needs to be a list of 2 valid dates formatted as 'yyyy-MM-dd HH' " +
1585
-
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Unparseable date: \"2001-01-01\"");
1585
+
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Text '2001-01-01' could not be parsed at index 10");
@@ -1597,7 +1597,7 @@ public void testPartitionProjectionInvalidTableProperties()
1597
1597
" partition_projection_enabled=true " +
1598
1598
")"))
1599
1599
.hasMessage("Column projection for column 'short_name1' failed. Property: 'partition_projection_range' needs to be a list of 2 valid dates formatted as 'yyyy-MM-dd' " +
1600
-
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Unparseable date: \"NOW*3DAYS\"");
1600
+
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Text 'NOW*3DAYS' could not be parsed at index 0");
@@ -1703,7 +1703,7 @@ public void testPartitionProjectionIgnore()
1703
1703
// Expect invalid Partition Projection properties to fail
1704
1704
assertThatThrownBy(() -> getQueryRunner().execute("SELECT * FROM " + fullyQualifiedTestTableName))
1705
1705
.hasMessage("Column projection for column 'date_time' failed. Property: 'partition_projection_range' needs to be a list of 2 valid dates formatted as 'yyyy-MM-dd HH' " +
1706
-
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Unparseable date: \"2001-01-01\"");
1706
+
"or '^\\s*NOW\\s*(([+-])\\s*([0-9]+)\\s*(DAY|HOUR|MINUTE|SECOND)S?\\s*)?$' that are sequential: Text '2001-01-01' could not be parsed at index 10");
0 commit comments