Deprecate AiVdbProviderInterface::getVdbIds()

Created on 31 July 2025, 2 months ago

Problem/Motivation

Is only used in \Drupal\ai\Base\AiVdbProviderClientBase::deleteItems(). There may be better provider-specific ways of deleting multiple items, rather than doing a look up for entity ids to get vdb ids, to then delete them.

We should let the vdb provider handle deleting multiple items directly instead.

Steps to reproduce (required for bugs, but not feature requests)

Proposed resolution

Deprecate \Drupal\ai\AiVdbProviderInterface::getVdbIds() and let the vdb provider delete directly.

Remaining tasks

Optional: Other details as applicable (e.g., User interface changes, API changes, Data model changes)

πŸ“Œ Task
Status

Active

Version

1.2

Component

AI Search

Created by

πŸ‡¦πŸ‡ΊAustralia kim.pepper πŸ„β€β™‚οΈπŸ‡¦πŸ‡ΊSydney, Australia

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @kim.pepper
  • πŸ‡¦πŸ‡ΊAustralia kim.pepper πŸ„β€β™‚οΈπŸ‡¦πŸ‡ΊSydney, Australia
  • πŸ‡¬πŸ‡§United Kingdom scott_euser

    I think it depends on provider, in this case I think the problem was Milvus if I remember right (would have to check). Pinecone was fine for it. I suppose that could be a problem for Milvus specifically to sort then... Haven't checked others

  • πŸ‡¬πŸ‡§United Kingdom scott_euser

    Checked and this is doable, steps would be this I believe:

    1. Copy the current state of deleteItems() from AiVdbProviderClientBase into Milvus
    2. Remove the deleteItems() method from AiVdbProviderClientBase since its Milvus specific code that others currently override
    3. Remove getVdbIds() from AiVdbProviderInterface
    4. Do coordinated release (e.g. 2.0 branch) for Milvus

    Given its experimental I don't think we need to do an actual deprecation throw unless others disagree. We can just add to release notes. Currently AI module homepage does not list any supported VDB provider other than Milvus that would need coordinated update.

  • πŸ‡¬πŸ‡§United Kingdom scott_euser

    Hmm actually we may need this for πŸ“Œ Improve AI Search Module Indexing to Handle Long-Running Chunk Embedding Processes Needs work for the ChunkQueueWorker. Going to postpone to see where that goes

Production build 0.71.5 2024