Skip to content

feat: Add versioning support to Milvus online store#6330

Merged
franciscojavierarceo merged 4 commits intofeast-dev:masterfrom
makinzm:feast/milvus-online-store-versioning
Apr 28, 2026
Merged

feat: Add versioning support to Milvus online store#6330
franciscojavierarceo merged 4 commits intofeast-dev:masterfrom
makinzm:feast/milvus-online-store-versioning

Conversation

@makinzm
Copy link
Copy Markdown
Contributor

@makinzm makinzm commented Apr 25, 2026

What this PR does / why we need it:

Adds feature view versioning support to the Milvus online store. When enable_online_feature_view_versioning is enabled in the registry config, the Milvus collection name now includes a version suffix (e.g. project_driver_stats_v2), allowing version-qualified feature references (e.g. driver_stats@v2:trips_today) to resolve to the correct versioned data.

Changes:

  • Updated _table_id() in milvus.py to accept enable_versioning and delegate to the shared compute_table_id() helper (same pattern as SQLite, Redis, PostgreSQL, etc.)
  • Updated all 5 call sites of _table_id to pass config.registry.enable_online_feature_view_versioning
  • Added MilvusOnlineStore to the supported types list in _check_versioned_read_support() so versioned reads no longer raise VersionedOnlineReadNotSupported
  • Added unit tests covering versioned/non-versioned table name generation and versioned read support

Which issue(s) this PR fixes:

Fixes #6177

Checks

  • I've made sure the tests are passing.
  • My commits are signed off (git commit -s)
  • My PR title follows conventional commits format

Testing Strategy

  • Unit tests

Misc

Implementation follows the existing pattern from sqlite.py and dynamodb.py. The compute_table_id() helper in helpers.py handles the version suffix logic, so no additional logic was needed in the Milvus store itself.


Open in Devin Review

@makinzm makinzm requested review from a team as code owners April 25, 2026 03:39
@makinzm makinzm requested review from HaoXuAI, nquinn408 and redhatHameed and removed request for a team April 25, 2026 03:39
Copy link
Copy Markdown
Contributor

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

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

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

View in Devin Review to see 3 additional findings.

Open in Devin Review

@ntkathole ntkathole changed the title feat: add versioning support to Milvus online store feat: Add versioning support to Milvus online store Apr 25, 2026
@ntkathole
Copy link
Copy Markdown
Member

@makinzm please fix the linting

self.client = self._connect(config)
for table in tables:
collection_name = _table_id(config.project, table)
collection_name = _table_id(
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.

No cleanup of old versioned collections, it needs to list all collections matching the base name pattern and drop them.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@ntkathole

Thank you for reviewing. I fixed it 161aab7

Summary of the change:

  • Added a _drop_all_version_collections helper that drops the base collection plus every _v{N} sibling, mirroring the _drop_all_version_tables helpers used by the MySQL and PostgreSQL online stores.
  • update and teardown now call this helper unconditionally (i.e. regardless of the current enable_online_feature_view_versioning flag), so repos that toggle versioning on and off across applies don't leave orphan collections behind in Milvus.
  • Added unit tests covering both teardown and update, including an unrelated collection that must not be dropped.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I forgot to check mypy so I will fix 🙇

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I've fixed 5fad6e8

@ntkathole ntkathole force-pushed the feast/milvus-online-store-versioning branch from 5fad6e8 to 3f2989a Compare April 28, 2026 11:26
@franciscojavierarceo franciscojavierarceo merged commit 3268ced into feast-dev:master Apr 28, 2026
33 of 35 checks passed
@makinzm makinzm deleted the feast/milvus-online-store-versioning branch April 29, 2026 10:34
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 Milvus online store

3 participants