Skip to content

Add missing CLI options for dab configure, add, and update#3409

Open
souvikghosh04 wants to merge 3 commits intomainfrom
Usr/sogh/grp1-dab-configure
Open

Add missing CLI options for dab configure, add, and update#3409
souvikghosh04 wants to merge 3 commits intomainfrom
Usr/sogh/grp1-dab-configure

Conversation

@souvikghosh04
Copy link
Copy Markdown
Contributor

@souvikghosh04 souvikghosh04 commented Apr 3, 2026

What

Adds missing CLI options and fixes schema issues for dab configure, dab add, and dab update commands.

Issues Fixed

Issue Description Fix Location
#3337 Missing runtime.pagination.max-page-size ConfigureOptions, ConfigGenerator
#3338 Missing runtime.pagination.default-page-size ConfigureOptions, ConfigGenerator
#3339 Missing runtime.pagination.next-link-relative ConfigureOptions, ConfigGenerator
#3340 Missing runtime.host.max-response-size-mb ConfigureOptions, ConfigGenerator
#3341 Missing runtime.health.* (enabled, cache-ttl-seconds, max-query-parallelism, roles) ConfigureOptions, ConfigGenerator
#3342 Missing data-source-files ConfigureOptions, ConfigGenerator
#3343 Missing runtime.telemetry.log-level ConfigureOptions, ConfigGenerator
#3377 --cache.ttl should be --cache.ttl-seconds EntityOptions
#3383 Missing data-source.user-delegated-auth.provider ConfigureOptions, ConfigGenerator
#3384 Missing data-source.health.threshold-ms ConfigureOptions, ConfigGenerator
#3385 Missing data-source.health.enabled ConfigureOptions, ConfigGenerator
#3386 Dup of #3339 (same fix)
#3387 Dup of #3340 (same fix)
#3388 Missing entity health.enabled EntityOptions, Utils, ConfigGenerator
#3389 Missing entity cache.level EntityOptions, Utils, ConfigGenerator
#3390 Schema object-description to description dab.draft.schema.json
#3395 cosmosdb_postgresql missing from help text ConfigureOptions
  • ConfigureOptions.cs - 15 new options
  • EntityOptions.cs - Renamed cache.ttl to cache.ttl-seconds; added cache.level, health.enabled
  • AddOptions.cs / UpdateOptions.cs - Pass new entity params
  • ConfigGenerator.cs - Processing for all new options in configure, add, update flows
  • Utils.cs - Updated ConstructCacheOptions; added ConstructEntityHealthOptions
  • dab.draft.schema.json - Renamed object-description to description

Tests

  • Unit tests
  • New tests added

Adds 15 new dab configure options (pagination, health, host max-response-size, data-source-files, data-source health, user-delegated-auth provider, telemetry log-level), renames cache.ttl to cache.ttl-seconds, adds entity-level cache.level and health.enabled options, renames schema source.object-description to source.description, and updates cosmosdb_postgresql in help text. Includes unit tests for all new options.
Fixes #3337 #3338 #3339 #3340 #3341 #3342 #3343 #3377 #3383 #3384 #3385 #3386 #3387 #3388 #3389 #3390 #3395
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR closes CLI coverage gaps by adding missing dab configure, dab add, and dab update options so more runtime/entity configuration can be set via CLI and correctly reflected in generated runtime config.

Changes:

  • Added new dab configure options for runtime pagination, runtime health, host max response size, telemetry log-level, data-source health, user-delegated-auth provider, and data-source-files.
  • Extended dab add/update entity options to support cache.level and health.enabled, and renamed cache.ttl to cache.ttl-seconds.
  • Updated config generation/merge logic and schema property naming (source.object-descriptionsource.description).

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/Cli/Utils.cs Extends entity cache option construction to include cache level; adds entity health option construction.
src/Cli/ConfigGenerator.cs Wires new CLI options into add/update/configure flows and merges them into RuntimeConfig.
src/Cli/Commands/ConfigureOptions.cs Adds new configure CLI options and updates database-type help text.
src/Cli/Commands/EntityOptions.cs Adds --cache.level, --health.enabled, renames --cache.ttl to --cache.ttl-seconds.
src/Cli/Commands/AddOptions.cs Plumbs new entity options into dab add.
src/Cli/Commands/UpdateOptions.cs Plumbs new entity options into dab update.
src/Cli.Tests/ConfigureOptionsTests.cs Adds test coverage for new configure options.
src/Cli.Tests/UpdateEntityTests.cs Adds test coverage for updating entity cache level and health enabled.
src/Cli.Tests/AddEntityTests.cs Updates test option construction for new entity option parameters.
schemas/dab.draft.schema.json Fixes schema property name under entity source object.

…, validate inputs

- Use EntityCacheOptions constructor instead of 'with' to set UserProvided* flags
- Preserve existing entity cache on update when no cache options provided
- Use PaginationOptions constructor for validation and UserProvided flags
- Auto-set health enabled=true when any health sub-option is provided
- Create new dictionary copy for telemetry log-level merge (immutability)
- Reject empty namespace keys in --runtime.telemetry.log-level input
- Add test for empty namespace rejection
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli config changes related to config

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

Missing CLI options for dab configure, add, and update

4 participants