()
| 177 | } |
| 178 | |
| 179 | func (t *TopicConfig) assignments() []createtopics.RequestAssignment { |
| 180 | if len(t.ReplicaAssignments) == 0 { |
| 181 | return nil |
| 182 | } |
| 183 | assignments := make([]createtopics.RequestAssignment, len(t.ReplicaAssignments)) |
| 184 | for i, a := range t.ReplicaAssignments { |
| 185 | assignments[i] = createtopics.RequestAssignment{ |
| 186 | PartitionIndex: a.partitionIndex(), |
| 187 | BrokerIDs: a.brokerIDs(), |
| 188 | } |
| 189 | } |
| 190 | return assignments |
| 191 | } |
| 192 | |
| 193 | func (t *TopicConfig) configs() []createtopics.RequestConfig { |
| 194 | if len(t.ConfigEntries) == 0 { |
no test coverage detected