tsonglew opened a new issue, #12131: URL: https://github.com/apache/skywalking/issues/12131
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/skywalking/issues?q=is%3Aissue) and found no similar issues. ### Apache SkyWalking Component Python Agent (apache/skywalking-python) ### What happened SkyWalking agent failed to start if using kafka protocol with sasl_mechanism=PLAIN. ### What you expected to happen SkyWalking agent starts successfully when using kafka protocol with sasl_mechanism=PLAIN. ### How to reproduce run a gunicorn app with a command like ```sh SW_AGENT_PROTOCOL=kafka \ SW_KAFKA_BOOTSTRAP_SERVERS=localhost:9092 \ SW_KAFKA_REPORTER_CONFIG_security_protocol=SASL_PLAINTEXT \ SW_KAFKA_REPORTER_CONFIG_sasl_mechanism=PLAIN \ SW_KAFKA_REPORTER_CONFIG_sasl_plain_username=************ \ SW_KAFKA_REPORTER_CONFIG_sasl_plain_password=************ \ SW_AGENT_NAME=demo::gunicorn \ sw-python -d run -p gunicorn main:app ``` ### Anything else The agent failed to start with AttributeError: 'SkyWalkingAgent' object has no attribute '_SkyWalkingAgent__log_queue' Using kafka protocol with sasl_mechanism=PLAIN leads to "log.warning('%s: Sending username and password in the clear', self)". https://github.com/dpkp/kafka-python/blob/a6d0579d3cadd3826dd364b01bc12a2173139abc/kafka/conn.py#L624 the logging module was replaced by sw_logging, but __log_queue was not initialized yet ### Are you willing to submit a pull request to fix on your own? - [X] Yes I am willing to submit a pull request on my own! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
