You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Hyukjin Kwon (Jira)" <ji...@apache.org> on 2021/04/11 03:32:00 UTC
[jira] [Commented] (SPARK-35008) Spark hangs after on doing
multiple unions
[ https://issues.apache.org/jira/browse/SPARK-35008?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17318629#comment-17318629 ]
Hyukjin Kwon commented on SPARK-35008:
--------------------------------------
Let's interact with mailing list for questions before filing it as an issue. I am sure you can have a better answer there.
> Spark hangs after on doing multiple unions
> ------------------------------------------
>
> Key: SPARK-35008
> URL: https://issues.apache.org/jira/browse/SPARK-35008
> Project: Spark
> Issue Type: Question
> Components: SQL
> Affects Versions: 3.1.1
> Reporter: Arthur
> Priority: Major
>
> I'm trying to union a list of {{Dataset<Rows>}} like so:
>
> {{}}
> {code:java}
> totalSet = sparkSession.emptyDataset(RowEncoder.apply(schema));
> for(var currentDataset : datasetList)
> totalSet = totalSet.union(currentDataset);
> totalSet.show(10000,false);
> {code}
> {{}}
> There's about 160 datasets in datasetList. totalSet should only have 1k rows at the end of the loop. However, spark gets stuck here in this loop. If I union just 1 dataset from datasetList it works just fine. I thought doing unions ought to be a O(1) operation, but that doesn't seem to be the case. Does anyone know why this code hangs?
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org