Skip to content

Add CI validation workflow and collection lifecycle#3

Closed
diberry wants to merge 2 commits into
article2/select-algorithmfrom
ci/workflow-and-lifecycle
Closed

Add CI validation workflow and collection lifecycle#3
diberry wants to merge 2 commits into
article2/select-algorithmfrom
ci/workflow-and-lifecycle

Conversation

@diberry

@diberry diberry commented Apr 30, 2026

Copy link
Copy Markdown
Owner

Summary

Adds a GitHub Actions workflow that validates all samples can build and run, plus standardizes collection lifecycle across all samples.

Changes

  • Workflow (.github/workflows/validate-samples.yml): Dual-mode (build-only on PR, full-run on manual trigger), serialized execution, secret masking
  • Lifecycle standardization: All samples now drop-if-exists at start and always-drop at end for clean CI runs
  • TypeScript type safety: MongoSearchResult interface, env validation, safe finally block

Depends on

Testing

  • Workflow runs serially to avoid collection name collisions
  • Each sample creates its own collections and cleans up after itself

diberry and others added 2 commits April 30, 2026 07:51
…rop at end

All 10 sample directories now follow the same pattern:
- START: conditionally drop collection only if it exists
- END: always drop collection for cleanup (in finally/defer block)

Languages updated: TypeScript, Python, Go, Java, .NET

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add validate-samples.yml workflow (dual-mode: build-only + full-run)
- Serialized execution: TS -> Py -> Go -> Java -> .NET
- Secret masking for all env vars
- Collection lifecycle: drop-if-exists at start, always drop at end
- TypeScript type safety improvements in compare-all.ts

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@diberry

diberry commented Apr 30, 2026

Copy link
Copy Markdown
Owner Author

Retargeting to upstream Azure-Samples/documentdb-samples

@diberry diberry closed this Apr 30, 2026
diberry added a commit that referenced this pull request May 20, 2026
- Create ai/includes/choosing-algorithm.md with enhanced content
- Add quick-reference decision table (IVF/DiskANN/HNSW by scenario)
- Elevate DiskANN-as-default recommendation with IMPORTANT callout
- Add operational benefits: easier backups, faster recovery
- Add dimension future-proofing context (models evolving past 8K)
- Replace duplicated sections in all 5 quickstarts with include ref
- Addresses Khelan Modi feedback points #3 and #4

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