Unable to Inject custom KinesisClient [DBZ-3767]
- Dominant language
- HTML
- Stars
- 6
- Forks
- 9
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 1
Description
Migrated from [DBZ-3767](https://issues.redhat.com/browse/DBZ-3767)
This was posted in the [Google Group|https://groups.google.com/g/debezium/c/VPagWheg6DQ] and I was asked to create a ticket.
I am running Debezium via the supplied docker container (debezium/server). I created a jar to inject a custom {{KinesisClient}} into the {{KinesisChangeConsumer}} via a CDI producer.
I created a jar with the following class:
{code:java}
// Specifically not Debezium's package path
package com.example.thirdparty.pkg;
public class KinesisClientFactory {
@Produces
@CustomConsumerBuilder
public KinesisClient getKinesisClient() {
return KinesisClient.create();
}
public void close(@Disposes @CustomConsumerBuilder KinesisClient kinesisClient) {
kinesisClient.close();
}
}{code}
I also added an empty {{beans.xml}} and generated a Jandex index as per the Quarkus and Debezium documentation. I then added the jar to the {{lib/}} folder inside of the docker container.
Unfortunately this has not worked and Debezium continues to use the default client created inside of the {{KinesisChangeConsumer}}. I was told this may be a bug and to file a ticket.
Contributor guide
Research direction
Read KinesisChangeConsumer and the Quarkus and Debezium injection documentation first; inspect how the supplied debezium/server container loads jars from lib/, including beans.xml and the generated Jandex index. Done means the CDI-produced custom KinesisClient is selected instead of the default client.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, java
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 38/100