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: avoid memory allocation during partition write requests #1208

Merged
merged 3 commits into from
Sep 18, 2023

Conversation

ShiKaiWi
Copy link
Member

Rationale

Some memory allocation during partitioning write request can be avoided.

Detailed Changes

Introduce an enum called PartitionedRows as the return type of PartitionRule.locate_partitions_for_write to avoid unnecessary memory allocation.

Test Plan

Existing test.

partition_table_engine/src/partition.rs Show resolved Hide resolved
table_engine/src/partition/rule/mod.rs Outdated Show resolved Hide resolved
table_engine/src/partition/rule/random.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@jiacai2050 jiacai2050 left a comment

Choose a reason for hiding this comment

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

LGTM

@jiacai2050 jiacai2050 merged commit ff6d27b into apache:main Sep 18, 2023
7 checks passed
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.

None yet

3 participants