Repository navigation
Commit f9e91fa
fix: Load Milvus collections once instead of on every query (#6882)
* fix: Make Milvus placeholder vectors valid on Milvus servers
Feature views without a vector field get a placeholder vector because
Milvus requires one per collection. The placeholder was 1-dimensional,
filled with NaN and left unindexed. Milvus Lite accepts all three, but
Milvus servers and Zilliz Cloud reject dim < 2 and non-finite values,
and refuse to load a collection with an unindexed vector field, so
these feature views could not be created or read.
The placeholder is now 2-dimensional, zero-filled and FLAT-indexed.
Vector fields without vector_index=True also get a FLAT index so the
collection can be loaded. Existing collections keep working because
the placeholder is filled to the dimension recorded in the collection.
Also fixes the Milvus docs page title and example config.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Simon Hearne <[email protected]>
* fix: Load Milvus collections once instead of on every query
online_read and retrieve_online_documents_v2 called load_collection on
every request, adding a round-trip to each read. The call also hid the
fact that newly created collections were never loaded on Milvus
servers, because indexes were created after the collection.
Collections are now created with their index params, which makes
Milvus load them straight away. Existing collections are loaded only
if their load state isn't Loaded, and only the first time a store
accesses them. The per-query load_collection calls are removed.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Simon Hearne <[email protected]>
---------
Signed-off-by: Simon Hearne <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>1 parent e2d7fe2 commit f9e91fa
5 files changed
Lines changed: 691 additions & 34 deletions
File tree
- docs/reference/online-stores
- sdk/python
- feast/infra/online_stores/milvus_online_store
- tests
- integration/online_store
- unit/infra/online_store
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
| 22 | + | |
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
26 | | - | |
| 26 | + | |
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
37 | 36 | | |
38 | 37 | | |
39 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
40 | 53 | | |
41 | 54 | | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
42 | 58 | | |
43 | 59 | | |
44 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
45 | 76 | | |
46 | 77 | | |
47 | 78 | | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
48 | 92 | | |
49 | 93 | | |
50 | 94 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
114 | 115 | | |
115 | 116 | | |
116 | 117 | | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
117 | 125 | | |
118 | 126 | | |
119 | 127 | | |
| |||
348 | 356 | | |
349 | 357 | | |
350 | 358 | | |
351 | | - | |
| 359 | + | |
352 | 360 | | |
353 | | - | |
| 361 | + | |
354 | 362 | | |
355 | 363 | | |
356 | 364 | | |
| |||
360 | 368 | | |
361 | 369 | | |
362 | 370 | | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | 371 | | |
369 | | - | |
370 | 372 | | |
371 | | - | |
372 | | - | |
373 | | - | |
374 | | - | |
375 | | - | |
376 | | - | |
377 | | - | |
378 | | - | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
379 | 379 | | |
380 | 380 | | |
381 | 381 | | |
| |||
387 | 387 | | |
388 | 388 | | |
389 | 389 | | |
390 | | - | |
391 | | - | |
392 | | - | |
393 | | - | |
394 | | - | |
395 | | - | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
396 | 412 | | |
397 | | - | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
398 | 416 | | |
399 | 417 | | |
400 | 418 | | |
401 | 419 | | |
402 | 420 | | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
403 | 428 | | |
404 | 429 | | |
405 | 430 | | |
| |||
423 | 448 | | |
424 | 449 | | |
425 | 450 | | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
426 | 460 | | |
427 | 461 | | |
428 | 462 | | |
| |||
472 | 506 | | |
473 | 507 | | |
474 | 508 | | |
475 | | - | |
476 | | - | |
| 509 | + | |
| 510 | + | |
477 | 511 | | |
478 | 512 | | |
479 | 513 | | |
| |||
533 | 567 | | |
534 | 568 | | |
535 | 569 | | |
536 | | - | |
537 | 570 | | |
538 | 571 | | |
539 | 572 | | |
| |||
746 | 779 | | |
747 | 780 | | |
748 | 781 | | |
749 | | - | |
750 | | - | |
751 | 782 | | |
752 | 783 | | |
753 | 784 | | |
| |||
0 commit comments