control: add comments

This commit is contained in:
Gyu-Ho Lee 2017-01-09 16:20:53 -08:00
parent 1c0bdbd745
commit 852748b16a
No known key found for this signature in database
GPG Key ID: 1DDD39C7EB70C24C
1 changed files with 3 additions and 1 deletions

View File

@ -69,7 +69,9 @@ func commandFunc(cmd *cobra.Command, args []string) error {
}
cfg.GoogleCloudStorageKey = string(bts)
cfg.PeerIPString = strings.Join(cfg.PeerIPs, "___") // protoc sorts the 'repeated' type data
// protoc sorts the 'repeated' type data
// encode in string to enforce ordering of IPs
cfg.PeerIPString = strings.Join(cfg.PeerIPs, "___")
cfg.AgentEndpoints = make([]string, len(cfg.PeerIPs))
cfg.DatabaseEndpoints = make([]string, len(cfg.PeerIPs))
for i := range cfg.PeerIPs {