feat: Use ORJSONResponse for faster JSON serialization in feature server#5930
Open
ntkathole wants to merge 1 commit intofeast-dev:masterfrom
Open
feat: Use ORJSONResponse for faster JSON serialization in feature server#5930ntkathole wants to merge 1 commit intofeast-dev:masterfrom
ntkathole wants to merge 1 commit intofeast-dev:masterfrom
Conversation
franciscojavierarceo
approved these changes
Feb 1, 2026
Member
franciscojavierarceo
left a comment
There was a problem hiding this comment.
Need to get tests passing but approving to unblock
Member
Author
@franciscojavierarceo Test failures are due to transient dependency sqlglot, related to ibis-project/ibis#11882. I have handled it already in #5928 , will rebase this PR once it's merged. |
franciscojavierarceo
approved these changes
Feb 1, 2026
Signed-off-by: ntkathole <nikhilkathole2683@gmail.com>
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.
What this PR does / why we need it:
This PR improves the latency of the online feature server by using FastAPI's built-in ORJSONResponse instead of the default JSONResponse. This leverages orjson, a fast JSON library written in Rust, for response serialization.
Changes
When returning a dict from a FastAPI endpoint, FastAPI uses Python's standard json module for serialization. By using ORJSONResponse, we leverage orjson which is written in Rust and provides significantly faster JSON encoding.