GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(dynamodb): Use ProjectionExpression when requested_features is set by Jwrede · Pull Request #6366 · feast-dev/feast

Conversation

@Jwrede

@Jwrede Jwrede commented May 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • online_read and online_read_async accept requested_features but ignored it -- DynamoDB always fetched all features from the values map
  • Added ProjectionExpression to BatchGetItem requests when requested_features is provided, so DynamoDB only returns entity_id, event_ts, and the requested feature attributes within values
  • Uses ExpressionAttributeNames to avoid conflicts with DynamoDB reserved words
  • Works for both single-batch (resource API) and multi-batch (client API / async) code paths

Fixes

Fixes #6058

Test plan

  • test_build_projection_expression -- verifies correct DynamoDB expression generation
  • test_build_projection_expression_none -- verifies None/empty returns None
  • test_dynamodb_online_store_online_read_with_requested_features -- verifies only requested features are returned (moto)
  • test_dynamodb_online_store_online_read_without_requested_features -- verifies all features returned when not specified (moto)
  • test_dynamodb_online_store_online_read_requested_features_parallel -- verifies filtering across parallel batches (moto)
  • All 39 existing + new DynamoDB unit tests pass

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Jwrede
Jwrede requested a review from a team as a code owner May 3, 2026 17:27
@ntkathole
ntkathole force-pushed the fix/dynamodb-projection-expression branch from 595a4bf to a872a88 Compare May 6, 2026 08:31
@Jwrede

Jwrede commented May 13, 2026

Copy link
Copy Markdown
Contributor Author

Friendly ping @franciscojavierarceo -- this has been open ~10 days. Let me know if anything needs adjusting.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

ntkathole
ntkathole approved these changes May 14, 2026
View reviewed changes
Jwrede added 2 commits May 14, 2026 12:13
@Jwrede @ntkathole
feat(dynamodb): Use ProjectionExpression when requested_features is set
7cb24c1
The requested_features parameter was accepted by online_read and
online_read_async but never used -- DynamoDB always fetched all
features stored in the values map regardless. Add a
ProjectionExpression to BatchGetItem requests when requested_features
is provided, reducing data transfer, latency, and read costs.

Fixes feast-dev#6058

Signed-off-by: Jonathan Wrede <[email protected]>
@Jwrede @ntkathole
fix(dynamodb): Fix mypy type for _build_projection_expression return
2500dd3
The return dict contains both str and Dict[str, str] values, so the
return type must be Dict[str, Any] not Dict[str, str].

Signed-off-by: Jonathan Wrede <[email protected]>
@ntkathole
ntkathole force-pushed the fix/dynamodb-projection-expression branch from e9d7e8a to 2500dd3 Compare May 14, 2026 06:43
@ntkathole ntkathole added the ok-to-test label May 14, 2026
@ntkathole
ntkathole merged commit 217b4da into feast-dev:master May 14, 2026
35 checks passed

Uh oh!

There was an error while loading. Please reload this page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@ntkathole ntkathole ntkathole approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

ok-to-test

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

DynamoDB online_read ignores requested_features parameter

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@Jwrede @ntkathole
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.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.