Explorar el Código

Merge pull request #1065 from Mongey/cm-create-partitions

Add CreatePartitions to Broker
Evan Huus hace 8 años
padre
commit
5983794945
Se han modificado 1 ficheros con 11 adiciones y 0 borrados
  1. 11 0
      broker.go

+ 11 - 0
broker.go

@@ -386,6 +386,17 @@ func (b *Broker) ApiVersions(request *ApiVersionsRequest) (*ApiVersionsResponse,
 	return response, nil
 }
 
+func (b *Broker) CreatePartitions(request *CreatePartitionsRequest) (*CreatePartitionsResponse, error) {
+	response := new(CreatePartitionsResponse)
+
+	err := b.sendAndReceive(request, response)
+	if err != nil {
+		return nil, err
+	}
+
+	return response, nil
+}
+
 func (b *Broker) CreateTopics(request *CreateTopicsRequest) (*CreateTopicsResponse, error) {
 	response := new(CreateTopicsResponse)