code: func (t *Topic) marshalPartitions(partitions PartitionList) ([]byte, error) {
  	tm := topicMetadata{Version: 1, Partitions: make(map[string][]int32, len(partitions))}
  	for _, part := range partitions {
  		tm.Partitions[fmt.Sprintf("%d", part.ID)] = part.Replicas
  	}
  	return json.Marshal(tm)
  }
docs: // marshalPartitions turns a PartitionList into the JSON representation
  // to be stored in Zookeeper.