Add optional admin port to volume server, to seperate admin operations from normal file operations.

This commit is contained in:
Chris Lu
2015-01-18 17:03:38 -08:00
parent 7b10d62096
commit 7b4a53b2c1
12 changed files with 74 additions and 24 deletions

View File

@@ -14,7 +14,7 @@ It has these top-level messages:
*/
package operation
import "github.com/golang/protobuf/proto"
import proto "code.google.com/p/goprotobuf/proto"
import math "math"
// Reference imports to suppress errors if they are not otherwise used.
@@ -121,6 +121,7 @@ type JoinMessage struct {
DataCenter *string `protobuf:"bytes,7,opt,name=data_center" json:"data_center,omitempty"`
Rack *string `protobuf:"bytes,8,opt,name=rack" json:"rack,omitempty"`
Volumes []*VolumeInformationMessage `protobuf:"bytes,9,rep,name=volumes" json:"volumes,omitempty"`
AdminPort *uint32 `protobuf:"varint,10,opt,name=admin_port" json:"admin_port,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
@@ -191,5 +192,12 @@ func (m *JoinMessage) GetVolumes() []*VolumeInformationMessage {
return nil
}
func (m *JoinMessage) GetAdminPort() uint32 {
if m != nil && m.AdminPort != nil {
return *m.AdminPort
}
return 0
}
func init() {
}