-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[FLINK-36865][cdc] Provide UNIX_TIMESTAMP series functions in YAML pipeline #3819
Conversation
flink-cdc-common/src/main/java/org/apache/flink/cdc/common/utils/DateTimeUtils.java
Outdated
Show resolved
Hide resolved
flink-cdc-common/src/main/java/org/apache/flink/cdc/common/utils/DateTimeUtils.java
Outdated
Show resolved
Hide resolved
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
flink-cdc-runtime/src/test/java/org/apache/flink/cdc/runtime/parser/TransformParserTest.java
Outdated
Show resolved
Hide resolved
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider adding cases in TransformE2eITCase#testTemporalFunctions
PTAL @yuxiqian |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for @aiwenmo's nice work, UT case seems comprehensive! Just left some trivial comments on typo.
Would @leonardBang like to take a further look?
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
...rc/test/java/org/apache/flink/cdc/runtime/operators/transform/PostTransformOperatorTest.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
It is reasonable to expect some functions like
FROM_UNIXTIME(numeric[, string])
,UNIX_TIMESTAMP()
andUNIX_TIMESTAMP(string1[, string2])
series functions to help manipulating timestamps without having to write any UDFs.If a time zone is specified in the date time string and parsed by UTC+X format such as “yyyy-MM-dd HH:mm:ss.SSS X”, this function will use the specified timezone in the date time string instead of the timezone in table config. If the date time string can not be parsed, the default value Long.MIN_VALUE(-9223372036854775808) will be returned.