Skip to content

fix(api): preserve optional ClickPipe create fields - #753

Open
sdairs wants to merge 2 commits into
stack/569-clickpipe-updatefrom
stack/595-create-omission-api
Open

fix(api): preserve optional ClickPipe create fields#753
sdairs wants to merge 2 commits into
stack/569-clickpipe-updatefrom
stack/595-create-omission-api

Conversation

@sdairs

@sdairs sdairs commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

ClickPipeSettings.kafka_read_committed and ClickPipePostSource.validate_samples were modeled as required booleans, which forced callers to serialize false when those source-conditional create fields were unset. On 2026-09-05, a live object-storage create that omitted source.validateSamples succeeded; the same request with settings.kafka_read_committed:false failed with Setting 'kafka_read_committed' is only supported for Kafka ClickPipes, and omitting that setting succeeded.

This changes both request fields to Option<bool> with absent values omitted from JSON. Explicit Some(false) remains serialized. Narrow analyzer exemptions document the observed control-plane behavior, and model tests cover omitted and explicit-false payloads. The CLI receives compile-only Some(...) adaptations in this prerequisite commit, so its wire behavior remains unchanged until the follow-up CLI commit.

Validation:

  • cargo fmt --all
  • cargo clippy -p clickhouse-cloud-api -p clickhouse-openapi-analyzer --all-targets -- -D warnings
  • cargo test -p clickhouse-cloud-api -p clickhouse-openapi-analyzer
  • python3 -m unittest discover -s scripts/tests -p 'test_*.py' (91 passed with commit signing disabled for the temporary-repository test)
  • cargo check --workspace --all-features

The prerequisite also adapts three CLI unit assertions to the new types. Its no-default all-target Clippy, affected unit tests and full CLI test compilation pass before the behavior-changing follow-up.

Prerequisite for #595.

@sdairs sdairs added this to the v0.5.0 milestone Sep 5, 2026
@sdairs sdairs added the run-cloud-integration Run live Cloud integration tests for this PR head label Sep 5, 2026
@sdairs sdairs added run-cloud-integration Run live Cloud integration tests for this PR head and removed run-cloud-integration Run live Cloud integration tests for this PR head labels Sep 5, 2026
@sdairs
sdairs temporarily deployed to cloud-integration September 5, 2026 14:20 — with GitHub Actions Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

run-cloud-integration Run live Cloud integration tests for this PR head

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose cross-source clickpipe create request fields: scaling, settings, field mappings, validate-samples

1 participant