dongjoon-hyun commented on a change in pull request #25335: [SPARK-28601][CORE]
Use StandardCharsets.UTF_8 instead of "UTF-8" string representation
URL: https://github.com/apache/spark/pull/25335#discussion_r310200095
##########
File path: repl/src/main/scala/org/apache/spark/repl/ExecutorClassLoader.scala
##########
@@ -234,7 +235,8 @@ class ExecutorClassLoader(
* URL-encode a string, preserving only slashes
*/
def urlEncode(str: String): String = {
- str.split('/').map(part => URLEncoder.encode(part, "UTF-8")).mkString("/")
+ str.split('/').map(part => URLEncoder.encode(part,
StandardCharsets.UTF_8.name()))
+ .mkString("/")
Review comment:
Ditto. Change `import` instead of splitting lines.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]