I want to read data from kafka Topic through GCP Cloud Function, for which am importing below packeges
Imports inside my main.py file
from kafka import KafkaConsumer
from confluent_avro import AvroKeyValueSerde, SchemaRegistry
from confluent_avro.schema_registry import HTTPBasicAuth`
my requiremnts.txt file
kafka-python
pandas
confluent_avro
requests
But my test my cloud Function code it give me below error Error:
from confluent_avro import AvroKeyValueSerde, SchemaRegistry
File "/layers/google.python.pip/pip/lib/python3.10/site-packages/confluent_avro/__init__.py", line 8, in <module>
from confluent_avro.schema_registry import SchemaRegistry
File "/layers/google.python.pip/pip/lib/python3.10/site-packages/confluent_avro/schema_registry/__init__.py", line 1, in <module>
from confluent_avro.schema_registry import auth, client_http
File "/layers/google.python.pip/pip/lib/python3.10/site-packages/confluent_avro/schema_registry/client_http.py", line 29, in <module>
RETRY_POLICY = SchemaRegistryRetry(
TypeError: Retry.__init__() got an unexpected keyword argument 'method_whitelist'"
**Can somone please suggest what I am mssing here ? **
I tried with
confluent_avro
confluent_avro~=1.8.0
confluent-avero
but they all are giving me same error.