-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-41097][CORE][SQL][SS][PROTOBUF] Remove redundant collection conversion base on Scala 2.13 code #38598
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
Changes from all commits
a92dcc4
77caccc
4748f0a
e026520
e9490e7
f7db485
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -555,7 +555,7 @@ object StructType extends AbstractDataType { | |
|
|
||
| def apply(fields: java.util.List[StructField]): StructType = { | ||
| import scala.collection.JavaConverters._ | ||
| StructType(fields.asScala.toSeq) | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This represents |
||
| StructType(fields.asScala.toArray) | ||
| } | ||
|
|
||
| private[sql] def fromAttributes(attributes: Seq[Attribute]): StructType = | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -939,7 +939,7 @@ case class ShowTablePropertiesCommand( | |
| } | ||
| case None => | ||
| properties.filterKeys(!_.startsWith(CatalogTable.VIEW_PREFIX)) | ||
| .toSeq.sortBy(_._1).map(p => Row(p._1, p._2)).toSeq | ||
| .toSeq.sortBy(_._1).map(p => Row(p._1, p._2)) | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| } | ||
| } | ||
| } | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -47,7 +47,7 @@ case class ShowTablePropertiesExec( | |
| } | ||
| case None => | ||
| properties.toSeq.sortBy(_._1).map(kv => | ||
| toCatalystRow(kv._1, kv._2)).toSeq | ||
| toCatalystRow(kv._1, kv._2)) | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| } | ||
| } | ||
| } | ||
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.
No need to
toSeqhere becauseexecutorIdsToBeRemoved(ArrayBuffer).mapfinally calls toArray