cockroachdb / cockroachdb/cockroach

changefeedccl: add randomized testing

Open
#124,146 1 comment 0 reactions 0 assignees View on GitHub
A-cdc C-bug P-1 T-cdc
Dominant language
Go
Stars
32.5k
Forks
4.1k
PR merge metrics
PR metrics pending

Description

Add a randomized test that creates a random table, does random inserts/updates/deletes, then compares the output to the original table. This could be done with and without an initial scan on initial data. This should have correctness validation for ordering and table content.

Our current direction is to integrate sqlsmith into the nemeses test (see `TestChangefeedNemeses`), which already supports all sinks and introduces some chaos.

We should make sure the randomized testing covers:
- [x] All sink types
- [x] Fingerprint validation for all data types: https://github.com/cockroachdb/cockroach/issues/134159
- [x] Before/After validation for all data types: https://github.com/cockroachdb/cockroach/issues/134158
- [ ] Column families
- [ ] Tables with secondary indexes
- [ ] Multiple watched tables: https://github.com/cockroachdb/cockroach/issues/134118
- [ ] All [options](https://www.cockroachlabs.com/docs/v23.2/create-changefeed#options) with full range of possible values: https://github.com/cockroachdb/cockroach/issues/134119
- [ ] CDC Queries: https://github.com/cockroachdb/cockroach/issues/134253
- [ ] Schema changes (FK both on and to table, add column with and without default value, drop column, add index)

Jira issue: CRDB-38724

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.