Github user sakky11 commented on a diff in the pull request:
https://github.com/apache/spark/pull/14402#discussion_r72886476
--- Diff:
core/src/main/java/org/apache/spark/api/java/JavaSparkContextVarargsWorkaround.java
---
@@ -52,11 +46,16 @@ public JavaDoubleRDD union(JavaDoubleRDD... rdds) {
if (rdds.length == 0) {
throw new IllegalArgumentException("Union called on empty list");
}
- List<JavaPairRDD<K, V>> rest = new ArrayList<>(rdds.length - 1);
+ rest = populateRDDList(rdds);
+ return union(rdds[0], rest);
+ }
+
+ public static final List<T> populateRDDList(T rdds) {
--- End diff --
I agree with making the method "private".But rdds is not any varargs so why
do we need ...??
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]