Skip to content

fix: drop collections at end of each sample#78

Open
diberry wants to merge 1 commit intoAzure-Samples:mainfrom
diberry:fix/drop-collections-at-end
Open

fix: drop collections at end of each sample#78
diberry wants to merge 1 commit intoAzure-Samples:mainfrom
diberry:fix/drop-collections-at-end

Conversation

@diberry
Copy link
Copy Markdown
Collaborator

@diberry diberry commented Apr 30, 2026

Each vector search sample now drops its collection after the search completes, ensuring no leftover collections accumulate between runs.

Changes (13 files):

  • TypeScript (ivf.ts, hnsw.ts, diskann.ts): Drop collection in finally block before closing connection
  • Python (ivf.py, hnsw.py, diskann.py): Drop collection in finally block before closing connection
  • Go (ivf.go, hnsw.go, diskann.go): Drop collection before final success message
  • Java (IVF.java, HNSW.java, DiskAnn.java): Drop collection after vector search completes
  • .NET (VectorSearchService.cs): Drop collection after printing search results

All changes are minimal — just adding the drop call at the appropriate cleanup point in each sample.

Each vector search sample now drops its collection in the finally/cleanup
block after the search completes. This ensures no leftover collections
accumulate between runs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant