question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cp-kafka-connect - CONNECT_REST_PORT not read

See original GitHub issue

When using the following configuration inside a docker-compose.yml, the kafka-connect rest API is still on the default port (8083).

kafka-connect:
  image: confluentinc/cp-kafka-connect:7.0.1
  ports:
    - 28082:28082
    - 8083:8083
  depends_on:
    - kafka
  environment:
    CONNECT_BOOTSTRAP_SERVERS: 'kafka:9093'
    CONNECT_GROUP_ID: kafka-connect
    CONNECT_REST_PORT: 28082
    CONNECT_CONFIG_STORAGE_TOPIC: _connect-configs
    CONNECT_OFFSET_STORAGE_TOPIC: _connect-offsets
    CONNECT_STATUS_STORAGE_TOPIC: _connect-status
    CONNECT_KEY_CONVERTER: org.apache.kafka.connect.storage.StringConverter
    CONNECT_VALUE_CONVERTER: org.apache.kafka.connect.json.JsonConverter
    CONNECT_REST_ADVERTISED_HOST_NAME: kafka-connect
    CONNECT_CONFIG_STORAGE_REPLICATION_FACTOR: 1
    CONNECT_OFFSET_STORAGE_REPLICATION_FACTOR: 1
    CONNECT_STATUS_STORAGE_REPLICATION_FACTOR: 1

From the CONNECT_REST_PORT environment variable, shouldn’t it be reachable at 28082?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:1
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
andrewegelcommented, Feb 24, 2022

From https://github.com/confluentinc/cp-demo/blob/7.0.1-post/docker-compose.yml#L445

It looks like you want CONNECT_LISTENERS: https://0.0.0.0:28082

0reactions
tkornaicommented, Dec 9, 2022

My experience is that one needs to set both of these:

CONNECT_LISTENERS: "http://:28082"
CONNECT_REST_PORT: 28082
Read more comments on GitHub >

github_iconTop Results From Across the Web

Connect REST Interface - Confluent Documentation
Since Kafka Connect is intended to be run as a service, it also supports a REST API for managing connectors. By default this...
Read more >
confluentinc/cp-kafka-connect - Docker Image
Docker image for deploying and running Kafka Connect. Functionally, the cp-kafka-connect and the cp-kafka-connect-base images are identical.
Read more >
Re: Issues while running kafka connect in distributed mode
For the unsupported media type issue, try removing everything from the -H parameter other than the Content-Type. My guess would be that one...
Read more >
Connection timeout using local kafka-connect cluster to ...
You need to set correctly rest.advertised.host.name (or CONNECT_REST_ADVERTISED_HOST_NAME , if you're using Docker). This is how a Connect ...
Read more >
Kafka Developer Manual - Connectors - Kinetica Docs
Kafka Connect allows you to configure the Kinetica Kafka Connector exactly the ... it should have its own dedicated port set with the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found