Repository navigation
Add connection diagnostics with step-by-step checks and reports - #1066
Merged
Guanzhou Song (guanzhousongmicrosoft) merged 101 commits intoNov 9, 2026
Merged
Guanzhou Song (guanzhousongmicrosoft) merged 101 commits into
Guanzhou Song (guanzhousongmicrosoft) merged 101 commits into
Conversation
…d disclosure motion Co-authored-by: Copilot <[email protected]>
…ter package Co-authored-by: Copilot <[email protected]>
…oken-free connection targets Co-authored-by: Copilot <[email protected]>
…nd the shell on every connection failure Co-authored-by: Copilot <[email protected]>
…n documents and shared version helpers Co-authored-by: Copilot <[email protected]>
… report and panel Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
… log and user manual Co-authored-by: Copilot <[email protected]>
Follow the renamed hostnameSuffix setting in diagnostics and fixtures, and consume the updated Azure host-cloud result without misclassifying conflicting hosts. Regenerate localization after resolving the rebase conflict. Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
…(WI-29) Adds the dns.mixedHostDomains warning to the Server address (DNS) step, for Microsoft Entra ID and managed identity connections only. It classifies the hosts the driver contacts (seeds, the SRV name and its resolved targets) with getAzureHostSuffix and the trusted documentDB.customEnvironment.hostnameSuffix, and warns when they span two built-in clouds, or one built-in cloud plus unrecognized names (IP literals included). Hosts that are all unrecognized do not warn. The package DNS check is wrapped, and the finding is attached once, to the first host DNS resolves. It only turns a pass into a warning, so blocking, the headline and later checks are unchanged. Finding data and telemetry carry counts and cloud enums only, and the panel shows the finding without a host. Reason: #1050 review finding E2. The resolver itself is unchanged. Co-authored-by: Copilot <[email protected]>
- `StatusListItem` gains an optional `aside`: a short value, such as a duration badge, at the end of the label line. It keeps its line while the label wraps and does not make the row taller. - `StatusList` gains `highlightRowsOnHover`: the row under the pointer, and the row whose control has keyboard focus, is shaded with the subtle `colorNeutralBackground2`, with an outline in high contrast. The layout does not move. Off by default. - README sections, changelog (folded into the unreleased 1.3.0) and tests. Co-authored-by: Copilot <[email protected]>
- srv-resolver: the new `SRV_FALLBACK_ELIGIBLE_ERROR_CODES` export is a feature, so the unreleased version is 1.1.0 rather than 1.0.1. The changelog names the export and the README lists it. - connectivity-troubleshooter: depends on srv-resolver ^1.1.0; its changelog describes the package as it is, not yet published. Co-authored-by: Copilot <[email protected]>
… Details (WI-30, WI-31, WI-33)
- Every settled row that ran shows its real duration in a squared outline
badge at the end of its label line, with no rating and no total; the
list shades the row under the pointer so the badge stays tied to it.
A row's duration is the wall-clock span of its checks, never a sum.
- Details give each host's time ("Took ...") only when a row has two or
more hosts, and each TCP address's connect time ("... in 31 ms",
"... after 2 ms") only when a host made two or more attempts.
- The Authentication line names the password mechanism
("Username and password · SCRAM-SHA-256 · user"); the Secure
connection line names no TLS version, Details show "TLS 1.3".
- The ping and durations are formatted for the locale.
- A Copy summary share item was built and reverted (WI-32).
- Decision 0050, design, README and implementation log updated.
Co-authored-by: Copilot <[email protected]>
Contributor
✅ CI passed: standard tier (ready PR)Commit
Full run: add the Code quality
Build sizeSizes that changed by 5% or 50 KiB or more against
Only each graph's 60 largest packages are tracked; the rest are counted as To find out why, compare the chunks ( Artifacts: VSIX | Bundle-reports-42645745434 | L1-manifest-report-42645745434 All graphs (exact bytes)
Packaged bytes. Shared chunks count in every graph that loads them, so rows do not add up. Updated in place on every run. |
…ration 03) Co-authored-by: Copilot <[email protected]>
…planation (RN-1) ConnectionDiagnosticsService and its providers become ErrorExplanationService and *ErrorExplainer, so the layer no longer shares a name with the connection diagnostics feature. Telemetry follows: errorExplanation.explained with explanationProviderId and explanationSource. Co-authored-by: Copilot <[email protected]>
…nostics (RN-2) Moves the package to packages/documentdb-js-connection-diagnostics (@documentdb-js/connection-diagnostics), src/troubleshooter to src/connectionDiagnostics, the webview to src/webviews/documentdb/connectionDiagnostics and the command to src/commands/diagnoseConnection. Paths and the package name only; identifiers, IDs and prose follow in later items. Co-authored-by: Copilot <[email protected]>
…(RN-3) runTroubleshooter becomes runDiagnostics and the Troubleshooter* types and errors become Diagnostics*. Consumers in the extension follow, including the error-name allowlist in the output trace. Co-authored-by: Copilot <[email protected]>
…ection diagnostics (RN-4) Renames the extension's own troubleshooter identifiers, comments, JSDoc and test titles (for example runConnectionDiagnostics, openConnectionDiagnostics, DiagnosticsOutputTrace, diagnoseConnection). Wire and persisted IDs are unchanged here. Co-authored-by: Copilot <[email protected]>
…agnostics (RN-5) Telemetry events become diagnoseConnection.run and diagnoseConnection.runStarted with diagnosticsSessionId and diagnosticsRunCorrelationId; the webview, router, panel view type, survey activation source, SRV surface and error-explanation source become connectionDiagnostics. The L2-dev harness, scenarios and fixtures follow. Co-authored-by: Copilot <[email protected]>
… names (RN-6) Co-authored-by: Copilot <[email protected]>
…ature (RN-7) Co-authored-by: Copilot <[email protected]>
…s (RN-1…RN-8) Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
…ks (iteration 03) Co-authored-by: Copilot <[email protected]>
…ation 04) Co-authored-by: Copilot <[email protected]>
…pied port (F4) A diagnosis joining an interactive start that chose "Use existing" now fails with LocalPortInUseError instead of inheriting externalAssumed. Adds a TDD contract test for the mixed-policy join. Co-authored-by: Copilot <[email protected]>
Regenerate the localization bundle and apply repository formatting so the diagnostics PR passes the static CI gate. Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
…ings Name Kubernetes port-forward outcomes and update the ready-state summary in Connection settings. Refs #1069 Co-authored-by: Copilot <[email protected]>
…be context Report Kubernetes forwarding details in diagnostics and redact kube context identifiers. Refs #1069 Co-authored-by: Copilot <[email protected]>
Document Kubernetes port-forward reporting and the related connection settings details. Refs #1069 Co-authored-by: Copilot <[email protected]>
Sync localized diagnostics strings for Kubernetes port-forward reporting. Refs #1069 Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Tomasz Naumowicz (tnaum-ms)
enabled auto-merge
November 9, 2026 15:32
Guanzhou Song (guanzhousongmicrosoft)
approved these changes
Nov 9, 2026
Guanzhou Song (guanzhousongmicrosoft)
approved these changes
Nov 9, 2026
Guanzhou Song (guanzhousongmicrosoft)
deleted the
dev/tnaum/connectivity-troubleshooter
branch
November 9, 2026 19:58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Add Diagnose connection so users can see which part of a connection fails, what was observed, and what to try next, rather than relying on a single driver error.
@documentdb-js/connection-diagnosticspackage for network checks, and the extension's real authentication path for non-interactive authentication and read-only server checks.ConnectionDiagnosticsServicetoErrorExplanationService(providers become*ErrorExplainer) so it no longer shares a name with this feature. Its telemetry follows:connectionDiagnostics.explainedbecomeserrorExplanation.explained, withexplanationProviderIdandexplanationSource(decision 0051; the old data was not yet evaluated). The feature's own events arediagnoseConnection.runanddiagnoseConnection.runStarted.Why
A connection failure can come from several layers, while a generic timeout or driver error rarely identifies which one. Ordered checks and a shareable evidence report help users and support engineers narrow down the cause. Successful connections can also be diagnosed.
Scope
This diagnoses one saved connection without changing its configuration or prompting for credentials/sign-in. It is not a configuration or permissions audit. Cloud-specific firewall configuration helpers and a standalone CLI are outside this PR.
Validation / remaining work
Case 2 handover (2026-11-06), run with
gpt-5.6-terraafter the review fixes:npm run l10n,npm run prettier-fix,npm run l10n:check,npm run lint, andnpm run build.npm run typecheck:tests.npx vitest run: 379 files and 7,406 tests passed; one test skipped.npm run package: 8.61 MB VSIX.UX review round (2026-11-06), iteration 05:
02923c9f:l10n,prettier-fix,l10n:check,lint,build,typecheck:tests,packagepassed; fullnpx vitest runpassed 7,478 tests (379 files, 1 skipped). Browser scenario unit tests (24) passed; the 84 L2-dev routes were not re-run in a browser.Kubernetes port forward follow-up (2026-11-09), from manual testing of the #1069 fixes: the panel did not make clear that the check used a Kubernetes port forward, why, or what it forwarded to.
prepare.sharedTunnelinfo finding is now titled "Kubernetes port forward stays open". It says whether this check started the port forward or reused an open one, why it is needed, and that it is shared and stays open; Next step: "It closes when you close or reload the VS Code window." (verified: extension disposal stops all tunnels). TheexternalAssumedoutcome uses cautious wording ("may be in use", not verified) and has no next step.kubeContext(placeholdercontext-N) in@documentdb-js/connection-diagnostics, because context names can embed account IDs (for example EKS ARNs); namespace and service were already redacted. Tests confirm no identifiers reach telemetry or the Output trace.3d5e18e6,ba52502f,6df3937f,13753953.npm run build,npm run l10n:check, and focused Vitest (75 files, 2,312 tests) passed. The full Case 2 suite has not been re-run since these commits.Links
Closes #100.
Feature overview, design, decisions, and implementation history