-
Notifications
You must be signed in to change notification settings - Fork 2.1k
[Improve][Connector-file] Add configurable binary chunk size support to BinaryReadStrategy #9391
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
Merged
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
2b65190
[Improve][Connector-file] Add Configurable Binary Chunk Size Support …
CosmosNi 37d368b
[Improve][Connector-file] Add Configurable Binary Chunk Size Support …
CosmosNi 92dc18e
[Improve][Connector-file] Add Configurable Binary Chunk Size Support …
CosmosNi b87a162
[Improve][Connector-file] Add Configurable Binary Chunk Size Support …
CosmosNi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -72,6 +72,8 @@ To use this connector you need put hadoop-cos-{hadoop.version}-{version}.jar and | |
| | compress_codec | string | no | none | | ||
| | archive_compress_codec | string | no | none | | ||
| | encoding | string | no | UTF-8 | | ||
| | binary_chunk_size | int | no | 1024 | | ||
| | binary_complete_file_mode | boolean | no | false | | ||
| | common-options | | no | - | | ||
|
|
||
| ### path [string] | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add description too? |
||
|
|
@@ -365,6 +367,18 @@ Note: gz compressed excel file needs to compress the original file or specify th | |
| Only used when file_format_type is json,text,csv,xml. | ||
| The encoding of the file to read. This param will be parsed by `Charset.forName(encoding)`. | ||
|
|
||
| ### binary_chunk_size [int] | ||
|
|
||
| Only used when file_format_type is binary. | ||
|
|
||
| The chunk size (in bytes) for reading binary files. Default is 1024 bytes. Larger values may improve performance for large files but use more memory. | ||
|
|
||
| ### binary_complete_file_mode [boolean] | ||
|
|
||
| Only used when file_format_type is binary. | ||
|
|
||
| Whether to read the complete file as a single chunk instead of splitting into chunks. When enabled, the entire file content will be read into memory at once. Default is false. | ||
|
|
||
| ### common options | ||
|
|
||
| Source plugin common parameters, please refer to [Source Common Options](../source-common-options.md) for details. | ||
|
|
@@ -420,6 +434,8 @@ source { | |
| region = "ap-chengdu" | ||
| path = "/seatunnel/read/binary/" | ||
| file_format_type = "binary" | ||
| binary_chunk_size = 2048 | ||
| binary_complete_file_mode = false | ||
| } | ||
| } | ||
| sink { | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why delete this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I accidentally deleted it.