zio / zio-kafka

A Kafka client for ZIO and ZIO Streams
https://zio.dev/zio-kafka
Apache License 2.0
336 stars 138 forks source link

Initialize Java Producer in blocking threadpool #1230

Closed kyri-petrou closed 5 months ago

kyri-petrou commented 5 months ago

As far as I understand, the initialization of the Java producer is side-effecting and blocking. It seems that while the Consumer initialization is wrapped in ZIO.blocking, the initialization of the Producer is not

erikvanoosten commented 5 months ago

Thanks @kyri-petrou . I am not sure if IO happens in the kafka producer constructor, but it for sure does a lot!