Skip to content

Commit

Permalink
[SPARK-36257][SQL] Updated the version of TimestampNTZ related change…
Browse files Browse the repository at this point in the history
…s as 3.3.0

### What changes were proposed in this pull request?

As we decided to release TimestampNTZ type in Spark 3.3, we should update the versions of TimestampNTZ related changes as 3.3.0.

### Why are the changes needed?

Correct the versions in documentation/code comment.

### Does this PR introduce _any_ user-facing change?

No

### How was this patch tested?

Existing UT

Closes #33478 from gengliangwang/updateVersion.

Authored-by: Gengliang Wang <gengliang@apache.org>
Signed-off-by: Gengliang Wang <gengliang@apache.org>
  • Loading branch information
gengliangwang committed Jul 22, 2021
1 parent 13aefd6 commit ae9f612
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ object Encoders {
* Creates an encoder that serializes instances of the `java.time.LocalDateTime` class
* to the internal representation of nullable Catalyst's TimestampNTZType.
*
* @since 3.2.0
* @since 3.3.0
*/
def LOCALDATETIME: Encoder[java.time.LocalDateTime] = ExpressionEncoder()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ case class Now() extends CurrentTimestampLike {
2020-04-25 15:49:11.914
""",
group = "datetime_funcs",
since = "3.2.0")
since = "3.3.0")
case class LocalTimestamp(timeZoneId: Option[String] = None) extends LeafExpression
with TimeZoneAwareExpression with CodegenFallback {

Expand Down Expand Up @@ -1096,7 +1096,7 @@ case class GetTimestamp(
2016-12-31 00:00:00
""",
group = "datetime_funcs",
since = "3.2.0")
since = "3.3.0")
// scalastyle:on line.size.limit
case class ParseToTimestampNTZ(
left: Expression,
Expand Down Expand Up @@ -1143,7 +1143,7 @@ case class ParseToTimestampNTZ(
2016-12-31 00:00:00
""",
group = "datetime_funcs",
since = "3.2.0")
since = "3.3.0")
// scalastyle:on line.size.limit
case class ParseToTimestampLTZ(
left: Expression,
Expand Down Expand Up @@ -2381,7 +2381,7 @@ case class MakeDate(
NULL
""",
group = "datetime_funcs",
since = "3.2.0")
since = "3.3.0")
// scalastyle:on line.size.limit
case class MakeTimestampNTZ(
year: Expression,
Expand Down Expand Up @@ -2440,7 +2440,7 @@ case class MakeTimestampNTZ(
NULL
""",
group = "datetime_funcs",
since = "3.2.0")
since = "3.3.0")
// scalastyle:on line.size.limit
case class MakeTimestampLTZ(
year: Expression,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2892,9 +2892,9 @@ object SQLConf {
s"and type literal. Setting the configuration as ${TimestampTypes.TIMESTAMP_NTZ} will " +
"use TIMESTAMP WITHOUT TIME ZONE as the default type while putting it as " +
s"${TimestampTypes.TIMESTAMP_LTZ} will use TIMESTAMP WITH LOCAL TIME ZONE. " +
"Before the 3.2.0 release, Spark only supports the TIMESTAMP WITH " +
"Before the 3.3.0 release, Spark only supports the TIMESTAMP WITH " +
"LOCAL TIME ZONE type.")
.version("3.2.0")
.version("3.3.0")
.stringConf
.transform(_.toUpperCase(Locale.ROOT))
.checkValues(TimestampTypes.values.map(_.toString))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import org.apache.spark.annotation.Unstable
* To represent an absolute point in time, use `TimestampType` instead.
*
* Please use the singleton `DataTypes.TimestampNTZType` to refer the type.
* @since 3.2.0
* @since 3.3.0
*/
@Unstable
class TimestampNTZType private() extends AtomicType {
Expand Down Expand Up @@ -59,7 +59,7 @@ class TimestampNTZType private() extends AtomicType {
* "TimestampNTZType" in byte code. Defined with a private constructor so the companion
* object is the only possible instantiation.
*
* @since 3.2.0
* @since 3.3.0
*/
@Unstable
case object TimestampNTZType extends TimestampNTZType
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ abstract class SQLImplicits extends LowPrioritySQLImplicits {
/** @since 3.0.0 */
implicit def newLocalDateEncoder: Encoder[java.time.LocalDate] = Encoders.LOCALDATE

/** @since 3.2.0 */
/** @since 3.3.0 */
implicit def newLocalDateTimeEncoder: Encoder[java.time.LocalDateTime] = Encoders.LOCALDATETIME

/** @since 2.2.0 */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2981,7 +2981,7 @@ object functions {
* All calls of localtimestamp within the same query return the same value.
*
* @group datetime_funcs
* @since 3.2.0
* @since 3.3.0
*/
def localtimestamp(): Column = withExpr { LocalTimestamp() }

Expand Down

0 comments on commit ae9f612

Please sign in to comment.