Correct defdelegate for v0.9.0 unsupported features
MODIFY
lib/kafka_ex.ex
lib/kafka_ex.ex
@@ -24,7 +24,6 @@ defmodule KafkaEx do
alias KafkaEx.Protocol.SyncGroup.Response, as: SyncGroupResponse
alias KafkaEx.Protocol.CreateTopics.Request, as: CreateTopicsRequest
alias KafkaEx.Protocol.CreateTopics.Response, as: CreateTopicsResponse
- alias KafkaEx.Protocol.DeleteTopics.Request, as: DeleteTopicsRequest
alias KafkaEx.Protocol.DeleteTopics.Response, as: DeleteTopicsResponse
alias KafkaEx.Protocol.ApiVersions.Response, as: ApiVersionsResponse
alias KafkaEx.Server

MODIFY
lib/kafka_ex/server.ex
lib/kafka_ex/server.ex
@@ -18,7 +18,6 @@ defmodule KafkaEx.Server do
alias KafkaEx.Protocol.Produce.Request, as: ProduceRequest
alias KafkaEx.Protocol.SyncGroup.Request, as: SyncGroupRequest
alias KafkaEx.Protocol.CreateTopics.Request, as: CreateTopicsRequest
- alias KafkaEx.Protocol.DeleteTopics.Request, as: DeleteTopicsRequest
alias KafkaEx.Socket
defmodule State do

MODIFY
lib/kafka_ex/server_0_p_9_p_0.ex
lib/kafka_ex/server_0_p_9_p_0.ex
@@ -51,13 +51,15 @@ defmodule KafkaEx.Server0P9P0 do
defdelegate kafka_server_consumer_group_metadata(state), to: Server0P8P2
defdelegate kafka_server_update_consumer_metadata(state), to: Server0P8P2
- defdelegate kafka_api_versions(state), to: Server0P8P2
- defdelegate kafka_create_topics(requests, network_timeout, state),
- to: Server0P8P2
+ def kafka_api_versions(_state),
+ do: raise("ApiVersions is not supported in 0.9.0 version of kafka")
- defdelegate kafka_delete_topics(requests, network_timeout, state),
- to: Server0P8P2
+ def kafka_create_topics(_, _, _state),
+ do: raise("CreateTopic is not supported in 0.9.0 version of kafka")
+
+ def kafka_delete_topics(_, _, _state),
+ do: raise("DeleteTopic is not supported in 0.9.0 version of kafka")
def kafka_server_init([args]) do
kafka_server_init([args, self()])

Correct defdelegate for v0.9.0 unsupported features