refactor(arrow): rename Record to RecordBatch and add deprecated alias#466
Merged
zeroshade merged 4 commits intoAug 13, 2025
Merged
Conversation
Rename the Record interface to RecordBatch for clarity, since Record commonly means a single row but this type represents a batch of rows. Add a deprecated type alias for backward compatibility to avoid breaking existing code and ease migration. Closes: apache#457
zeroshade
reviewed
Aug 11, 2025
zeroshade
left a comment
Member
There was a problem hiding this comment.
At a minimum we should update the examples to also use RecordBatch instead of Record. We can then incrementally update the rest of the library as we go
Contributor
Author
|
@zeroshade. I updated the examples to use RecordBatch instead of Record. For the incremental update, we can start with the non-critical leaf packages like internal utilities and specialized features and work our way up to the core packages like array and ipc. We can allow 3-4 days between each update to make sure previous changes did not break anything before moving to the next packages. Let me know what you think. Thanks |
zeroshade
reviewed
Aug 12, 2025
Comment on lines
+51
to
+53
| // Deprecated: Record is deprecated, use RecordBatch instead. | ||
| // Record represents a single row, but this type actually represents a batch of rows. | ||
| // This alias is provided for backwards compatibility. |
Member
There was a problem hiding this comment.
the convention for Go would be for the deprecated notice to be at the bottom. i.e.
Suggested change
| // Deprecated: Record is deprecated, use RecordBatch instead. | |
| // Record represents a single row, but this type actually represents a batch of rows. | |
| // This alias is provided for backwards compatibility. | |
| // Record as a term typically refers to a single row, but this type represents a batch of rows, known in Arrow parlance | |
| // as a RecordBatch. This alias is provided for backwards compatibility. | |
| // | |
| // Deprecated: This is deprecated to avoid the confusion of the terminology where Record refers to a single row, | |
| // use [RecordBatch] instead. |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Rationale for this change
Rename the Record interface to RecordBatch for clarity, since Record commonly means a single row but this type represents a batch of rows.
What changes are included in this PR?
code and ease migration
Are these changes tested?
All existing tests in ./arrow and ./arrow/array packages are passing.
Are there any user-facing changes?
Users can now use the semantically correct RecordBatch type name.