[jira] [Updated] (SPARK-38620) Replace `value.formatted(formatString)` with `formatString.format(value)` to clean up compilation warning
[ https://issues.apache.org/jira/browse/SPARK-38620?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sean R. Owen updated SPARK-38620: - Priority: Trivial (was: Minor) > Replace `value.formatted(formatString)` with `formatString.format(value)` to > clean up compilation warning > - > > Key: SPARK-38620 > URL: https://issues.apache.org/jira/browse/SPARK-38620 > Project: Spark > Issue Type: Improvement > Components: SQL >Affects Versions: 3.4.0 >Reporter: Yang Jie >Assignee: Yang Jie >Priority: Trivial > Fix For: 3.4.0 > > > There are compile warnings as follows: > {code:java} > [WARNING] > /spark-source/streaming/src/main/scala/org/apache/spark/streaming/ui/StreamingPage.scala:67: > [deprecation @ > org.apache.spark.streaming.ui.RecordRateUIData.formattedAvg.$anonfun | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. > [WARNING] > /spark-source/sql/core/src/main/scala/org/apache/spark/sql/streaming/ui/StreamingQueryPage.scala:201: > [deprecation @ > org.apache.spark.sql.streaming.ui.StreamingQueryPagedTable.row | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. > [WARNING] > /spark-source/sql/core/src/main/scala/org/apache/spark/sql/streaming/ui/StreamingQueryPage.scala:202: > [deprecation @ > org.apache.spark.sql.streaming.ui.StreamingQueryPagedTable.row | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. {code} -- This message was sent by Atlassian Jira (v8.20.1#820001) - To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org
[jira] [Updated] (SPARK-38620) Replace `value.formatted(formatString)` with `formatString.format(value)` to clean up compilation warning
[ https://issues.apache.org/jira/browse/SPARK-38620?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yang Jie updated SPARK-38620: - Summary: Replace `value.formatted(formatString)` with `formatString.format(value)` to clean up compilation warning (was: Replace `value.formatted(formatString)` with `formatString.format(value)`) > Replace `value.formatted(formatString)` with `formatString.format(value)` to > clean up compilation warning > - > > Key: SPARK-38620 > URL: https://issues.apache.org/jira/browse/SPARK-38620 > Project: Spark > Issue Type: Improvement > Components: SQL >Affects Versions: 3.4.0 >Reporter: Yang Jie >Priority: Minor > > There are compile warnings as follows: > {code:java} > [WARNING] > /spark-source/streaming/src/main/scala/org/apache/spark/streaming/ui/StreamingPage.scala:67: > [deprecation @ > org.apache.spark.streaming.ui.RecordRateUIData.formattedAvg.$anonfun | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. > [WARNING] > /spark-source/sql/core/src/main/scala/org/apache/spark/sql/streaming/ui/StreamingQueryPage.scala:201: > [deprecation @ > org.apache.spark.sql.streaming.ui.StreamingQueryPagedTable.row | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. > [WARNING] > /spark-source/sql/core/src/main/scala/org/apache/spark/sql/streaming/ui/StreamingQueryPage.scala:202: > [deprecation @ > org.apache.spark.sql.streaming.ui.StreamingQueryPagedTable.row | > origin=scala.Predef.StringFormat.formatted | version=2.12.16] method > formatted in class StringFormat is deprecated (since 2.12.16): Use > `formatString.format(value)` instead of `value.formatted(formatString)`, > or use the `f""` string interpolator. In Java 15 and later, `formatted` > resolves to the new method in String which has reversed parameters. {code} -- This message was sent by Atlassian Jira (v8.20.1#820001) - To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org