Skip to content
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

Evenly Repartioning AlignmentRecordRDD fails with IllegalArgumentException on sorted RDD #2063

Open
pauldwolfe opened this issue Oct 11, 2018 · 1 comment

Comments

@pauldwolfe
Copy link
Contributor

Trying to repartition an AlignmentRecordRDD yields the following exception:

java.lang.IllegalArgumentException: requirement failed: Cannot evenly repartition an unsorted RDD.

This occurs even when the RDD is "sorted", as in one of the sortByReadsXxx methods or sort has just been called prior to the repartitioning.

Looking at the code, the sorting check is actually looking to see if optPartitionMap.isDefined. I was unable to figure out exactly where this property would be set, but its not in any of the sort methods, so at least this is a confusing error.

@heuermh
Copy link
Member

heuermh commented Jun 30, 2019

Hello @pauldwolfe, how are you attempting to repartition the AlignmentRecordRDD? It appears the partition map is recalculated only in some of the sort methods, and then only when bound to RDD instead of Dataset.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants