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

Refactor s3client ReadFile interface to return a channel. #52

Merged
merged 7 commits into from
Sep 15, 2023

Conversation

niedbalski
Copy link
Contributor

Refactor the ReadFiles interface method to be ReadFile and return a channel of []string instead
of passing the channel as a reference in the method.

Also, handles the case of dynamic buffer size configured to handle scanning errors for long lines
on files.

Log the error condition when scanning fails due to a shorter buffer to ensure user is aware
on debug mode.

Adds test to cover it.

@niedbalski niedbalski self-assigned this Sep 15, 2023
Signed-off-by: Jorge Niedbalski <[email protected]>
Signed-off-by: Jorge Niedbalski <[email protected]>
go.mod Show resolved Hide resolved
Signed-off-by: Jorge Niedbalski <[email protected]>
Signed-off-by: Jorge Niedbalski <[email protected]>
Signed-off-by: Jorge Niedbalski <[email protected]>
Signed-off-by: Jorge Niedbalski <[email protected]>
@niedbalski niedbalski merged commit 9147955 into main Sep 15, 2023
7 checks passed
@niedbalski niedbalski deleted the refactor-interface branch September 15, 2023 11:29
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.

2 participants