stolostron / multicluster-global-hub

the main repository for the multicluster global hub
Apache License 2.0
21 stars 32 forks source link

:bug: initialize kafka #1066

Closed clyang82 closed 2 months ago

clyang82 commented 2 months ago

Summary

  1. Cannot create the kafka instance from scratch
  2. avoid to use wait.PollUntilContextTimeout in reconcile method, it will create multiple times with timeout.

Related issue(s)

Fixes #

sonarcloud[bot] commented 2 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
84.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

yanmxa commented 2 months ago

/lgtm

openshift-ci[bot] commented 2 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: clyang82, yanmxa

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/stolostron/multicluster-global-hub/blob/main/OWNERS)~~ [clyang82,yanmxa] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
yanmxa commented 2 months ago

If we async install the kafka, then the manager will throw the error like this:

2024-08-26T01:56:13.549Z        INFO    kafka-producer  Thransport producer client error        {"error": "ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)"}
%3|1724637403.552|FAIL|rdkafka#producer-1| [thrd:ssl://172.18.0.4:30095/bootstrap]: ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)
2024-08-26T01:56:43.552Z        INFO    kafka-producer  Thransport producer client error        {"error": "ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)"}
%3|1724637433.555|FAIL|rdkafka#producer-1| [thrd:ssl://172.18.0.4:30095/bootstrap]: ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)
2024-08-26T01:57:13.555Z        INFO    kafka-producer  Thransport producer client error        {"error": "ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)"}
%3|1724637463.560|FAIL|rdkafka#producer-1| [thrd:ssl://172.18.0.4:30095/bootstrap]: ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)
2024-08-26T01:57:43.560Z        INFO    kafka-producer  Thransport producer client error        {"error": "ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)"}
%3|1724637493.564|FAIL|rdkafka#producer-1| [thrd:ssl://172.18.0.4:30095/bootstrap]: ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)
2024-08-26T01:58:13.564Z        INFO    kafka-producer  Thransport producer client error        {"error": "ssl://172.18.0.4:30095/bootstrap: Connect to ipv4#172.18.0.4:30095 failed: Connection refused (after 0ms in state CONNECT, 30 identical error(s) suppressed)"}
yanmxa commented 2 months ago

It also introduces the issue:

if we modify the transport configuration in the mgh cr, it won't propagate to the transporter layer