confluentinc / confluentinc/confluent-kafka-python

Version 2.13.0 blocks in SerializingProducer constructor

Open
#2,164 5 comments 1 reaction 0 assignees View on GitHub
status:needs-more-info
Dominant language
Python
Stars
509
Forks
964
Avg merge
2d 2h
Merged PRs (30d)
14

Description

```
def oauth_cb(oauth_config):
region = os.getenv('AWS_REGION') or os.getenv('AWS_DEFAULT_REGION') or 'eu-west-1'
auth_token, expiry_ms = MSKAuthTokenProvider.generate_auth_token(region)
return auth_token, expiry_ms / 1000 - 60

...

conf = {
'bootstrap.servers': broker_url,
'security.protocol': 'SASL_SSL',
'sasl.mechanism': 'OAUTHBEARER',
'oauth_cb': oauth_cb,
"error_cb": error_cb,
'key.serializer': StringSerializer('utf_8'),
'value.serializer': json_serializer,
'socket.keepalive.enable': True,
}

return SerializingProducer(conf)
```
The same code works with 2.12.2.
Possible cause #2130 ?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.