v0.2.0: multi-result-set support, truncation reporting, retries, secret redaction, and test suite - #17
Merged
Merged
Conversation
…lation, env-var secrets, schema escape hatch, dep bumps
- Add Adomd.Cli.Tests xUnit project (24 tests) covering settings validation, connection-string resolution, query resolution, and rowset truncation
- ExecuteTabular now iterates NextResult() so multi-statement query batches return all result sets instead of silently dropping all but the first
- Every JSON rowset now reports { rowCount, truncated, rows } so callers can tell when --limit cut off data
- query/dmv now return a resultSets array (breaking change, pre-1.0)
- Wire CancellationToken into query execution (command.Cancel()); distinct exit code 130 for cancellation vs 2 for errors
- Support ADOMD_CONNECTION_STRING env var as an alternative to --connection-string to avoid secrets in shell history/process args
- Add --rowset <GUID> escape hatch to schema command for arbitrary schema rowsets
- Release workflow verifies tag version matches csproj VersionPrefix before publishing
- Bump Microsoft.AnalysisServices.AdomdClient to 19.114.8, Spectre.Console to 0.57.2, .NET SDK pin to 10.0.301
- Update README and add CHANGELOG.md documenting the above
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
…et GUID docs - CommonSettings: --retries/--retry-delay-ms options; OpenConnection retries via new cancellable RetryHelper (unit tested independently of ADOMD) - SecretRedactor: scrubs password/pwd/secret/client secret/access token fragments from exception messages before they hit stderr or the JSON error payload, in case a provider echoes the connection string - release.yml: generates and publishes a SHA256 checksum file alongside the zip - README: documents --retries/--retry-delay-ms, checksum verification, redaction behavior, and a table of common schema --rowset GUIDs sourced from AdomdSchemaGuid - 18 new tests (RetryHelper, SecretRedactor, retry option validation); 42/42 passing - Verified live against FinHubAS/KPILakeRevenue: retries observably extend connection attempts on failure, normal probe/schema/query paths unaffected Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
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.
Summary
This release addresses a critical review of the CLI covering correctness, security, and reliability, adds a full test suite, and bumps dependencies to their latest versions.
Fixes
ExecuteTabularnow reads all result sets from a query (previously silently dropped everything after the first).catalogs/schema/query/dmvoutput now reportsrowCountandtruncatedso callers can tell when--limithas cut off rows.CancellationTokenis now wired end-to-end (Ctrl+C now cancels in-flight operations, exits with code 130).ADOMD_CONNECTION_STRINGenv var instead of only--connection-string, reducing secret exposure in shell history/process listings.schemacommand gained a repeatable--rowset <GUID>escape hatch for arbitrary schema rowsets, plus README docs for common rowset GUIDs.--retries/--retry-delay-msoptions with backoff for connection opening.0success,2error,130cancelled.Dependencies
Microsoft.AnalysisServices.AdomdClient19.114.0 -> 19.114.8Spectre.Console0.57.1 -> 0.57.2global.json) 10.0.300 -> 10.0.301dependabot.ymlnow also covers the new test projectTests
src/Adomd.Cli.TestsxUnit project, 42 tests covering settings validation, retry/backoff (including cancellation), secret redaction, and truncation/rowset logic.Release process
release.ymlnow verifies the pushed tag matches the csprojVersionPrefix, and publishes a SHA256 checksum alongside the release zip.Breaking change
JSON output shape changed:
catalogs/schemarows are now wrapped:{ "rowCount": n, "truncated": bool, "rows": [...] }instead of a bare array.query/dmvno longer return top-levelrows/rowCount- they returnresultSets: [ { rowCount, truncated, rows }, ... ]since a query can produce multiple result sets.Documented in
CHANGELOG.mdunder[0.2.0].Manual verification
Tested live against a real Analysis Services instance (
FinHubAS/KPILakeRevenuecatalog) via Windows Integrated auth: probe, schema --limit, query/dmv with DAX, ADOMD_CONNECTION_STRING env var path, schema --rowset (valid + invalid GUID), retry/backoff against a bad host, and error paths - all behaved as expected. This can't be run in CI since it requires a live AS server.Co-authored-by: Copilot App 223556219+Copilot@users.noreply.github.com