Skip to content

[BUG] RLS should use 32MB GRPC payload size limit #5044

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

Conversation

Sicheng-Pan
Copy link
Contributor

@Sicheng-Pan Sicheng-Pan commented Jul 7, 2025

Description of changes

Summarize the changes made by this PR.

  • Improvements & Bug fixes
    • Rust Log Service did not configure the max payload size, which defaults to 4MB. We would like to use 32MB payload size (which is the default for GRPC log client right now).
    • We would like to bump the max frag size from 8MB to 64MB (2*GRPC max payload size)
  • New functionality
    • N/A

Test plan

Planning to perform data ingestion after config change

  • Tests pass locally with pytest for python, yarn test for js, cargo test for rust

Documentation Changes

Are all docstrings for user-facing APIs updated if required? Do we need to make documentation changes in the docs section?

Copy link

github-actions bot commented Jul 7, 2025

Reviewer Checklist

Please leverage this checklist to ensure your code review is thorough before approving

Testing, Bugs, Errors, Logs, Documentation

  • Can you think of any use case in which the code does not behave as intended? Have they been tested?
  • Can you think of any inputs or external events that could break the code? Is user input validated and safe? Have they been tested?
  • If appropriate, are there adequate property based tests?
  • If appropriate, are there adequate unit tests?
  • Should any logging, debugging, tracing information be added or removed?
  • Are error messages user-friendly?
  • Have all documentation changes needed been made?
  • Have all non-obvious changes been commented?

System Compatibility

  • Are there any potential impacts on other parts of the system or backward compatibility?
  • Does this change intersect with any items on our roadmap, and if so, is there a plan for fitting them together?

Quality

  • Is this code of a unexpectedly high quality (Readability, Modularity, Intuitiveness)

Copy link
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@Sicheng-Pan Sicheng-Pan marked this pull request as ready for review July 7, 2025 23:01
Copy link
Contributor

Increase GRPC Payload and Fragment Size Limits in Rust Log Service

This PR increases the GRPC message payload limit for the Rust Log Service (RLS) to 32MB, aligning it with the GRPC log client default, and adjusts configuration so the fragmentation (batch) limit is now 64MB (twice the GRPC payload limit). The changes ensure that both encoding/decoding message sizes in RLS are configurable and default to 32MB, and the WAL3 batching mechanism now defaults to 64MB fragment size.

Key Changes

• Added max_encoding_message_size and max_decoding_message_size fields to LogServerConfig with a 32MB default.
• Set GRPC server limits via .max_decoding_message_size() and .max_encoding_message_size() in LogServerWrapper::run.
• Increased WAL3's ThrottleOptions::batch_size_bytes default from 8MB to 64MB and updated config field comments.
• Updated all code paths using these config values to respect the new defaults.

Affected Areas

• rust/log-service/src/lib.rs
• rust/wal3/src/lib.rs
• Config loading and application
• GRPC server and WAL3 batch logic

This summary was automatically generated by @propel-code-bot

@Sicheng-Pan Sicheng-Pan requested review from rescrv and codetheweb July 7, 2025 23:02
@Sicheng-Pan Sicheng-Pan merged commit 6501edc into main Jul 8, 2025
60 checks passed
@Sicheng-Pan Sicheng-Pan deleted the 07-07-_bug_rls_should_use_32mb_grpc_payload_size_limit branch July 15, 2025 23:09
Inventrohyder pushed a commit to Inventrohyder/chroma that referenced this pull request Aug 5, 2025
## Description of changes

_Summarize the changes made by this PR._

- Improvements & Bug fixes
  - Rust Log Service did not configure the max payload size, which defaults to 4MB. We would like to use 32MB payload size (which is the default for GRPC log client right now).
  - We would like to bump the max frag size from 8MB to 64MB (2*GRPC max payload size)
- New functionality
  - N/A

## Test plan
Planning to perform data ingestion after config change

- [ ] Tests pass locally with `pytest` for python, `yarn test` for js, `cargo test` for rust

## Documentation Changes

_Are all docstrings for user-facing APIs updated if required? Do we need to make documentation changes in the [docs section](https://github.com/chroma-core/chroma/tree/main/docs/docs.trychroma.com)?_
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.

3 participants