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

fix LOAD DATA 64K buffer limit #2709

Merged
merged 9 commits into from
Oct 18, 2024
Merged

fix LOAD DATA 64K buffer limit #2709

merged 9 commits into from
Oct 18, 2024

Conversation

jycor
Copy link
Contributor

@jycor jycor commented Oct 18, 2024

This PR increase the buffer size for bufio.Scanner to LongTextMax, so hopefully nobody attempts to load a single row larger than 4GB.
Other changes:

  • moves ignore lines logic to within the loadDataIter
  • drops extra scanner.Text() logic
  • use byte comparison instead of string cast and string comparison

benchmark: dolthub/dolt#8467
fixes: dolthub/dolt#8469

Copy link
Contributor

@max-hoffman max-hoffman left a comment

Choose a reason for hiding this comment

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

lgtm

@jycor jycor merged commit 63ed221 into main Oct 18, 2024
8 checks passed
@jycor jycor deleted the james/load branch October 18, 2024 22:07
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.

LOAD DATA LOCAL INFILE fails when row size exceeds 64K (65535 bytes) limit
2 participants