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

#304: added toRedisByteHASHes function #306

Merged
merged 2 commits into from
Aug 25, 2021
Merged

Conversation

fe2s
Copy link
Collaborator

@fe2s fe2s commented May 17, 2021

No description provided.

@fe2s fe2s requested a review from gkorland May 17, 2021 15:39
.map { case (key, hashFields) =>
(redisConfig.getHost(key), (key, hashFields))
}
.toArray
Copy link
Contributor

@mayankasthana mayankasthana May 17, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We take in an Iterator, but here we are materializing it in one go with .toArray. This could cause OOM. Can we work in batches using .grouped(SOME_BATCH_SIZE) and do all the subsequent things per batch?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @mayankasthana ,
Thank you for the comment, good point. We do grouping when writing dataframe in RedisSourceRelation, but it's missing in all RDD write functions. I'll fix that.

@MartinsGabrielC
Copy link

MartinsGabrielC commented Jul 21, 2021

Hey guys, just wanted to check if these changes were reviewed and if it could be merged.

@gkorland gkorland merged commit 678c306 into master Aug 25, 2021
@gkorland gkorland deleted the issue-304-toRedisByteHASHes branch August 25, 2021 11:24
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

Successfully merging this pull request may close these issues.

4 participants