◐ Shell
reader mode source ↗
Skip to content

feat: Add feature view versioning support to Redis and DynamoDB online stores#6257

Merged
ntkathole merged 6 commits into
feast-dev:masterfrom
YassinNouh21:feat/redis-dynamodb-versioning
Apr 13, 2026
Merged

feat: Add feature view versioning support to Redis and DynamoDB online stores#6257
ntkathole merged 6 commits into
feast-dev:masterfrom
YassinNouh21:feat/redis-dynamodb-versioning

Conversation

@YassinNouh21

@YassinNouh21 YassinNouh21 commented Apr 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Redis: Adds _versioned_fv_name() helper that computes versioned feature view names (e.g., driver_stats_v2) used in Redis hash field keys (_ts: prefix and mmh3 feature hashes). This ensures version isolation within the same entity hash key — the Redis key itself (entity-based) does not change, only the hash field namespace.
  • DynamoDB: Modifies _get_table_name() to apply a version suffix before template formatting, so each version gets its own DynamoDB table (e.g., project.driver_stats_v2).
  • Both stores are registered in _check_versioned_read_support() and the error message in errors.py is updated.
  • Follows the established versioning pattern from SQLite (feat: Add version tracking to FeatureView #6101), PostgreSQL/MySQL (feat: Add feature view versioning support to PostgreSQL and MySQL online stores #6193).

Changes

File Change
sdk/python/feast/infra/online_stores/redis.py Add _versioned_fv_name(), update delete_table, online_write_batch, online_read, online_read_async, _generate_hset_keys_for_features
sdk/python/feast/infra/online_stores/dynamodb.py Modify _get_table_name() to apply version suffix
sdk/python/feast/infra/online_stores/online_store.py Add Redis and DynamoDB to _check_versioned_read_support()
sdk/python/feast/errors.py Update supported stores list in error message
tests/unit/.../test_redis_versioning.py 11 unit tests for _versioned_fv_name, hset key isolation, read support
tests/unit/.../test_dynamodb_versioning.py 9 unit tests for _get_table_name with versioning, templates, read support
tests/integration/.../test_redis_versioning.py 6 integration tests with real Redis (testcontainers)
tests/integration/.../test_dynamodb_versioning.py 6 integration tests with moto mock DynamoDB

Test plan

  • 20 unit tests pass (test_redis_versioning.py, test_dynamodb_versioning.py)
  • 6 Redis integration tests pass (real Redis via testcontainers)
  • 6 DynamoDB integration tests pass (moto mock)
  • Version isolation verified: data written under v1 is not returned when reading v2
  • projection.version_tag correctly routes reads to the right version
  • ruff check and ruff format --check pass on all changed files

Closes #6164, closes #6163


Open with Devin

…e stores

Redis: Add _versioned_fv_name() helper that computes versioned feature view
names (e.g. driver_stats_v2) used in hash field keys (_ts: and mmh3 feature
hashes). This ensures version isolation within the same entity hash key.

DynamoDB: Modify _get_table_name() to apply version suffix before template
formatting, so each version gets its own DynamoDB table.

Both stores are registered in _check_versioned_read_support() and the error
message is updated accordingly.

Closes feast-dev#6164, closes feast-dev#6163

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>
@YassinNouh21 YassinNouh21 requested review from a team as code owners April 10, 2026 11:25
@YassinNouh21 YassinNouh21 requested review from dmartinol, ejscribner and robhowley and removed request for a team April 10, 2026 11:25
Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hide comment

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 4 additional findings.

Open in Devin Review

@YassinNouh21 YassinNouh21 requested review from ntkathole and removed request for dmartinol, ejscribner and robhowley April 10, 2026 12:52
@YassinNouh21 YassinNouh21 self-assigned this Apr 10, 2026
…sioning gate

Redis and DynamoDB modules raise FeastExtrasDependencyImportError (not
ImportError) when their dependencies are missing. Use broad Exception
catch so environments without redis/boto3 don't break.

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>
Move version resolution logic into a shared compute_versioned_name()
in helpers.py, reused by Redis, DynamoDB, and compute_table_id().
Addresses reviewer feedback to avoid duplicating version logic.

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>
Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

@ntkathole ntkathole left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hide comment

looks good

Hide details View details @ntkathole ntkathole merged commit edf25af into feast-dev:master Apr 13, 2026
33 of 35 checks passed
korbonits pushed a commit to korbonits/feast that referenced this pull request Apr 13, 2026
…e stores (feast-dev#6257)

* feat: Add feature view versioning support to Redis and DynamoDB online stores

Redis: Add _versioned_fv_name() helper that computes versioned feature view
names (e.g. driver_stats_v2) used in hash field keys (_ts: and mmh3 feature
hashes). This ensures version isolation within the same entity hash key.

DynamoDB: Modify _get_table_name() to apply version suffix before template
formatting, so each version gets its own DynamoDB table.

Both stores are registered in _check_versioned_read_support() and the error
message is updated accordingly.

Closes feast-dev#6164, closes feast-dev#6163

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

* fix: Add pragma allowlist for dummy moto credentials in DynamoDB test

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

* fix: Catch Exception instead of ImportError for Redis/DynamoDB in versioning gate

Redis and DynamoDB modules raise FeastExtrasDependencyImportError (not
ImportError) when their dependencies are missing. Use broad Exception
catch so environments without redis/boto3 don't break.

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

* refactor: Extract shared compute_versioned_name helper to helpers.py

Move version resolution logic into a shared compute_versioned_name()
in helpers.py, reused by Redis, DynamoDB, and compute_table_id().
Addresses reviewer feedback to avoid duplicating version logic.

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>

---------

Signed-off-by: yassinnouh21 <yassinnouh21@gmail.com>
Signed-off-by: Alex Korbonits <alex@korbonits.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add feature view versioning support to Redis online store Add feature view versioning support to DynamoDB online store

2 participants