Skip to content

Commit

Permalink
Support for IPv6 (#140)
Browse files Browse the repository at this point in the history
* Support :extra_sock_opts

* Documentation
  • Loading branch information
vovayartsev authored Apr 21, 2024
1 parent d204d5f commit 17f624a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/broadway_kafka/brod_client.ex
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ defmodule BroadwayKafka.BrodClient do
:connect_timeout,
:request_timeout,
:client_id_prefix,
:query_api_versions
:query_api_versions,
:extra_sock_opts
]

@default_receive_interval 2000
Expand Down
3 changes: 3 additions & 0 deletions lib/broadway_kafka/producer.ex
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,9 @@ defmodule BroadwayKafka.Producer do
* `:request_timeout` - Optional. Time in milliseconds to be used as a timeout for waiting response from Kafka.
Default is to use `:brod`'s default timeout which is currently 240 seconds.
* `:extra_sock_opts` - Optional. `gen_tcp` socket options. [More info](https://www.erlang.org/doc/man/gen_tcp.html#type-option).
Set to `[:inet6]` if your Kafka broker uses IPv6.
> **Note**: Currently, Broadway does not support all options provided by `:brod`. If you
have a scenario where you need any extra option that is not listed above, please open an
issue, so we can consider adding it.
Expand Down

0 comments on commit 17f624a

Please sign in to comment.