cockroachdb / cockroachdb/cockroach
SHOW CHANGEFEED JOBS displays stale topics after ALTER EXTERNAL CONNECTION
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
**Describe the problem**
When a changefeed is configured to use an `external://` connection with a Kafka sink, and the external connection is subsequently updated via `ALTER EXTERNAL CONNECTION` to point to a different Kafka topic, `SHOW CHANGEFEED JOBS` continues to display the old topic in the topics column - even though the changefeed has already started emitting to the new topic. This mismatch persists even when the job is explicitly paused and resumed.
**To Reproduce**
1. Create an external connection pointing to a Kafka sink with a specific topic.
2. Create a changefeed using that external connection (`CREATE CHANGEFEED ... INTO 'external://my-conn'`).
3. Confirm `SHOW CHANGEFEED JOBS` shows the expected topic.
4. Update the external connection to use a different Kafka topic via `ALTER EXTERNAL CONNECTION`.
5. Observe that the changefeed begins emitting to the new topic.
6. Run `SHOW CHANGEFEED JOBS` - the topics column still shows the old topic.
7. Pause and resume the job - topics remains stale.
**Expected behavior**
`SHOW CHANGEFEED JOBS` should reflect the topic the changefeed is actually emitting to.
**Environment:**
- Tested on CockroachDB version 25.4.5 but likely affects other version.
**Additional context**
This makes it impossible to audit which Kafka topics are currently getting published to
Jira issue: CRDB-63356
Contributor guide
Assessment
This issue has not been assessed yet.