diff --git a/rpc/cloudagent/cloud/cluster/moc_cloudagent_cluster.proto b/rpc/cloudagent/cloud/cluster/moc_cloudagent_cluster.proto deleted file mode 100644 index 5266d797..00000000 --- a/rpc/cloudagent/cloud/cluster/moc_cloudagent_cluster.proto +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.cluster; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; -import "moc_cloudagent_node.proto"; - -message ClusterResponse { - repeated Cluster Clusters = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message Cluster { - string name = 1; - string id = 2; - string fqdn = 3; - Status status = 4; - bool UserOwned = 5; - bool IsLocalCluster = 6; - string domain = 7; - repeated moc.cloudagent.node.Node Nodes = 8; - string locationName = 9; - Tags tags = 10; -} - - -service ClusterAgent { - rpc LoadCluster(Cluster) returns (ClusterResponse) {} - rpc UnloadCluster(Cluster) returns (ClusterResponse) {} - rpc GetCluster(Cluster) returns (ClusterResponse) {} - rpc GetNodes(Cluster) returns (moc.cloudagent.node.NodeResponse) {} -} - diff --git a/rpc/cloudagent/cloud/controlplane/moc_cloudagent_controlplane.proto b/rpc/cloudagent/cloud/controlplane/moc_cloudagent_controlplane.proto deleted file mode 100644 index 1d7e120b..00000000 --- a/rpc/cloudagent/cloud/controlplane/moc_cloudagent_controlplane.proto +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.controlplane; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - -message ControlPlaneRequest { - repeated ControlPlane ControlPlanes = 1; - Operation OperationType = 2; -} - -message ControlPlaneResponse { - repeated ControlPlane ControlPlanes = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -enum ControlPlaneState { - NotLeader = 0; - Leader = 1; -} - -// There is a ControlPlane entity for every CloudAgent -// participating to provide high availability without -// FailoverCluster -message ControlPlane { - // id is an internal value required for all entities - string id = 1; - // name is an identifier provided during ControlPlane creation - string name = 2; - // locationName is the name of the Location entity this ControlPlane belongs to - string locationName = 3; - // fqdn is the fqdn, hostname, or ip address that this ControlPlane will use as part of the leadership election - string fqdn = 4; - // port is the port that this ControlPlane will use as part of the leadership election - int32 port = 5; - // status is a standard entity status - Status status = 6; - // state stores the last known election status of this ControlPlane - ControlPlaneState state = 7; -} - -service ControlPlaneAgent { - rpc Invoke(ControlPlaneRequest) returns (ControlPlaneResponse) {} -} - diff --git a/rpc/cloudagent/cloud/etcdcluster/etcdserver/moc_cloudagent_etcdserver.proto b/rpc/cloudagent/cloud/etcdcluster/etcdserver/moc_cloudagent_etcdserver.proto deleted file mode 100644 index 36c682cc..00000000 --- a/rpc/cloudagent/cloud/etcdcluster/etcdserver/moc_cloudagent_etcdserver.proto +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.etcd; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - -message EtcdServerRequest { - repeated EtcdServer EtcdServers = 1; - Operation OperationType = 2; -} - -message EtcdServerResponse { - repeated EtcdServer EtcdServers = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message EtcdServer { - string id = 1; - string name = 2; - string etcdClusterName = 3; - string clusterId = 4; - string locationName = 5; - string groupName = 6; - // fqdn is the fqdn, hostname, or ip address that this EtcdServer will - // advertise on - string fqdn = 7; - // etcd client port to listen on - uint32 clientPort = 8; - Status status = 9; -} - -service EtcdServerAgent { - rpc Invoke(EtcdServerRequest) returns (EtcdServerResponse) {} -} - diff --git a/rpc/cloudagent/cloud/etcdcluster/moc_cloudagent_etcdcluster.proto b/rpc/cloudagent/cloud/etcdcluster/moc_cloudagent_etcdcluster.proto deleted file mode 100644 index bb0a4b77..00000000 --- a/rpc/cloudagent/cloud/etcdcluster/moc_cloudagent_etcdcluster.proto +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.etcd; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - -message EtcdClusterRequest { - repeated EtcdCluster EtcdClusters = 1; - Operation OperationType = 2; -} - -message EtcdClusterResponse { - repeated EtcdCluster EtcdClusters = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message EtcdCluster { - string id = 1; - string name = 2; - string locationName = 3; - string groupName = 4; - // etcd ca certificate that works as RoT for client and peer connections - string caCertificate = 5 [(sensitive) = true]; - // etcd ca key associated with the ca certificate - string caKey = 6 [(sensitive) = true]; - Status status = 7; -} - -service EtcdClusterAgent { - rpc Invoke(EtcdClusterRequest) returns (EtcdClusterResponse) {} -} - diff --git a/rpc/cloudagent/cloud/kubernetes/moc_cloudagent_kubernetes.proto b/rpc/cloudagent/cloud/kubernetes/moc_cloudagent_kubernetes.proto deleted file mode 100644 index 933ba4cc..00000000 --- a/rpc/cloudagent/cloud/kubernetes/moc_cloudagent_kubernetes.proto +++ /dev/null @@ -1,105 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.kubernetes; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - -message KubernetesRequest { - repeated Kubernetes Kubernetess = 1; - Operation OperationType = 2; -} - -message KubernetesResponse { - repeated Kubernetes Kubernetess = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message StorageConfiguration { - string csi = 1; -} - -message NetworkConfiguration { - string cni = 1; - string podCidr = 2; - string clusterCidr = 3; - // TODO: merge controlplane cidr and network - string controlPlaneCidr = 4; - string virtualnetwork = 5; - string loadBalancerVip = 6; - string loadBalancerMac = 7; -} - -enum NodeType { - ControlPlane = 0; - LinuxWorker = 1; - WindowsWorker = 2; - LoadBalancer = 3; -} - -enum ManagementStrategyType { - Pivoted = 0; - Distinct = 1; -} - -message NodePoolConfiguration { - NodeType NodeType = 1; - string imagereference = 2; - int32 replicas = 3; - string VMSize = 4; -} - -message SSHPublicKey { - string keyData = 1 [(sensitive) = true]; -} - -message ComputeConfiguration { - string cri = 1; - SSHPublicKey publicKey = 2; - repeated NodePoolConfiguration NodePools = 3; -} - -message ClusterConfiguration { - string version = 1; -} - -message ClusterAPIConfiguration { - string ConfigurationEndpoint = 1; - string InfrastructureProviderVersion = 2; - string BootstrapProviderVersion = 3; - string ControlPlaneProviderVersion = 4; - string CoreProviderVersion = 5; -} - -message ContainerRegistry { - string Name = 1; - string Username = 2 [(sensitive) = true]; - string Password = 3 [(sensitive) = true]; -} - -message Kubernetes { - string name = 1; - string id = 2; - Status status = 4; - ClusterConfiguration cluster = 5; - NetworkConfiguration network = 6; - StorageConfiguration storage = 7; - ComputeConfiguration compute = 8; - string groupName = 9; - ManagementStrategyType managementStrategy = 10; - string locationName = 11; - bytes kubeConfig = 12; - ClusterAPIConfiguration capiConfig = 13; - ContainerRegistry containerRegistry = 14; - bytes deploymentManifest = 15; - Tags tags = 16; -} - -service KubernetesAgent { - rpc Invoke(KubernetesRequest) returns (KubernetesResponse) {} -} - diff --git a/rpc/cloudagent/cloud/moc_cloudagent_cluster.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_cluster.pb.go deleted file mode 100644 index 5af39089..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_cluster.pb.go +++ /dev/null @@ -1,422 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_cluster.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type ClusterResponse struct { - Clusters []*Cluster `protobuf:"bytes,1,rep,name=Clusters,proto3" json:"Clusters,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ClusterResponse) Reset() { *m = ClusterResponse{} } -func (m *ClusterResponse) String() string { return proto.CompactTextString(m) } -func (*ClusterResponse) ProtoMessage() {} -func (*ClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cf76b1466679011, []int{0} -} - -func (m *ClusterResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ClusterResponse.Unmarshal(m, b) -} -func (m *ClusterResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ClusterResponse.Marshal(b, m, deterministic) -} -func (m *ClusterResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterResponse.Merge(m, src) -} -func (m *ClusterResponse) XXX_Size() int { - return xxx_messageInfo_ClusterResponse.Size(m) -} -func (m *ClusterResponse) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterResponse proto.InternalMessageInfo - -func (m *ClusterResponse) GetClusters() []*Cluster { - if m != nil { - return m.Clusters - } - return nil -} - -func (m *ClusterResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *ClusterResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type Cluster struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` - Fqdn string `protobuf:"bytes,3,opt,name=fqdn,proto3" json:"fqdn,omitempty"` - Status *common.Status `protobuf:"bytes,4,opt,name=status,proto3" json:"status,omitempty"` - UserOwned bool `protobuf:"varint,5,opt,name=UserOwned,proto3" json:"UserOwned,omitempty"` - IsLocalCluster bool `protobuf:"varint,6,opt,name=IsLocalCluster,proto3" json:"IsLocalCluster,omitempty"` - Domain string `protobuf:"bytes,7,opt,name=domain,proto3" json:"domain,omitempty"` - Nodes []*Node `protobuf:"bytes,8,rep,name=Nodes,proto3" json:"Nodes,omitempty"` - LocationName string `protobuf:"bytes,9,opt,name=locationName,proto3" json:"locationName,omitempty"` - Tags *common.Tags `protobuf:"bytes,10,opt,name=tags,proto3" json:"tags,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Cluster) Reset() { *m = Cluster{} } -func (m *Cluster) String() string { return proto.CompactTextString(m) } -func (*Cluster) ProtoMessage() {} -func (*Cluster) Descriptor() ([]byte, []int) { - return fileDescriptor_3cf76b1466679011, []int{1} -} - -func (m *Cluster) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Cluster.Unmarshal(m, b) -} -func (m *Cluster) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Cluster.Marshal(b, m, deterministic) -} -func (m *Cluster) XXX_Merge(src proto.Message) { - xxx_messageInfo_Cluster.Merge(m, src) -} -func (m *Cluster) XXX_Size() int { - return xxx_messageInfo_Cluster.Size(m) -} -func (m *Cluster) XXX_DiscardUnknown() { - xxx_messageInfo_Cluster.DiscardUnknown(m) -} - -var xxx_messageInfo_Cluster proto.InternalMessageInfo - -func (m *Cluster) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *Cluster) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *Cluster) GetFqdn() string { - if m != nil { - return m.Fqdn - } - return "" -} - -func (m *Cluster) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func (m *Cluster) GetUserOwned() bool { - if m != nil { - return m.UserOwned - } - return false -} - -func (m *Cluster) GetIsLocalCluster() bool { - if m != nil { - return m.IsLocalCluster - } - return false -} - -func (m *Cluster) GetDomain() string { - if m != nil { - return m.Domain - } - return "" -} - -func (m *Cluster) GetNodes() []*Node { - if m != nil { - return m.Nodes - } - return nil -} - -func (m *Cluster) GetLocationName() string { - if m != nil { - return m.LocationName - } - return "" -} - -func (m *Cluster) GetTags() *common.Tags { - if m != nil { - return m.Tags - } - return nil -} - -func init() { - proto.RegisterType((*ClusterResponse)(nil), "moc.cloudagent.cluster.ClusterResponse") - proto.RegisterType((*Cluster)(nil), "moc.cloudagent.cluster.Cluster") -} - -func init() { proto.RegisterFile("moc_cloudagent_cluster.proto", fileDescriptor_3cf76b1466679011) } - -var fileDescriptor_3cf76b1466679011 = []byte{ - // 468 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x53, 0xcd, 0x6e, 0xd3, 0x40, - 0x10, 0xc6, 0x6e, 0xe2, 0xc6, 0x93, 0x52, 0xa4, 0x15, 0x2a, 0xdb, 0xa8, 0x40, 0x08, 0x12, 0xe4, - 0x82, 0x2d, 0x85, 0x23, 0x27, 0x8a, 0x50, 0x85, 0x54, 0x15, 0x64, 0x28, 0xe2, 0xe7, 0x50, 0x6d, - 0xd6, 0x1b, 0x63, 0xc9, 0xde, 0x31, 0xbb, 0x6b, 0xf5, 0x55, 0x78, 0x14, 0x9e, 0x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 0xb4, 0xf3, 0x44, 0x62, - 0x9d, 0xd6, 0xa5, 0x34, 0x68, 0x71, 0xe1, 0xd2, 0x1a, 0x65, 0x6a, 0x1a, 0x99, 0xae, 0xcb, 0xbb, - 0x70, 0x1e, 0xd1, 0x27, 0xf1, 0xf2, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x08, 0xfb, 0x97, 0xb8, - 0x0e, 0x04, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// ClusterAgentClient is the client API for ClusterAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type ClusterAgentClient interface { - LoadCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) - UnloadCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) - GetCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) - GetNodes(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*NodeResponse, error) -} - -type clusterAgentClient struct { - cc *grpc.ClientConn -} - -func NewClusterAgentClient(cc *grpc.ClientConn) ClusterAgentClient { - return &clusterAgentClient{cc} -} - -func (c *clusterAgentClient) LoadCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) { - out := new(ClusterResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.cluster.ClusterAgent/LoadCluster", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *clusterAgentClient) UnloadCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) { - out := new(ClusterResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.cluster.ClusterAgent/UnloadCluster", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *clusterAgentClient) GetCluster(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*ClusterResponse, error) { - out := new(ClusterResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.cluster.ClusterAgent/GetCluster", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *clusterAgentClient) GetNodes(ctx context.Context, in *Cluster, opts ...grpc.CallOption) (*NodeResponse, error) { - out := new(NodeResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.cluster.ClusterAgent/GetNodes", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// ClusterAgentServer is the server API for ClusterAgent service. -type ClusterAgentServer interface { - LoadCluster(context.Context, *Cluster) (*ClusterResponse, error) - UnloadCluster(context.Context, *Cluster) (*ClusterResponse, error) - GetCluster(context.Context, *Cluster) (*ClusterResponse, error) - GetNodes(context.Context, *Cluster) (*NodeResponse, error) -} - -// UnimplementedClusterAgentServer can be embedded to have forward compatible implementations. -type UnimplementedClusterAgentServer struct { -} - -func (*UnimplementedClusterAgentServer) LoadCluster(ctx context.Context, req *Cluster) (*ClusterResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method LoadCluster not implemented") -} -func (*UnimplementedClusterAgentServer) UnloadCluster(ctx context.Context, req *Cluster) (*ClusterResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method UnloadCluster not implemented") -} -func (*UnimplementedClusterAgentServer) GetCluster(ctx context.Context, req *Cluster) (*ClusterResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetCluster not implemented") -} -func (*UnimplementedClusterAgentServer) GetNodes(ctx context.Context, req *Cluster) (*NodeResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNodes not implemented") -} - -func RegisterClusterAgentServer(s *grpc.Server, srv ClusterAgentServer) { - s.RegisterService(&_ClusterAgent_serviceDesc, srv) -} - -func _ClusterAgent_LoadCluster_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Cluster) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ClusterAgentServer).LoadCluster(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.cluster.ClusterAgent/LoadCluster", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ClusterAgentServer).LoadCluster(ctx, req.(*Cluster)) - } - return interceptor(ctx, in, info, handler) -} - -func _ClusterAgent_UnloadCluster_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Cluster) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ClusterAgentServer).UnloadCluster(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.cluster.ClusterAgent/UnloadCluster", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ClusterAgentServer).UnloadCluster(ctx, req.(*Cluster)) - } - return interceptor(ctx, in, info, handler) -} - -func _ClusterAgent_GetCluster_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Cluster) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ClusterAgentServer).GetCluster(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.cluster.ClusterAgent/GetCluster", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ClusterAgentServer).GetCluster(ctx, req.(*Cluster)) - } - return interceptor(ctx, in, info, handler) -} - -func _ClusterAgent_GetNodes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Cluster) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ClusterAgentServer).GetNodes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.cluster.ClusterAgent/GetNodes", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ClusterAgentServer).GetNodes(ctx, req.(*Cluster)) - } - return interceptor(ctx, in, info, handler) -} - -var _ClusterAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.cluster.ClusterAgent", - HandlerType: (*ClusterAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "LoadCluster", - Handler: _ClusterAgent_LoadCluster_Handler, - }, - { - MethodName: "UnloadCluster", - Handler: _ClusterAgent_UnloadCluster_Handler, - }, - { - MethodName: "GetCluster", - Handler: _ClusterAgent_GetCluster_Handler, - }, - { - MethodName: "GetNodes", - Handler: _ClusterAgent_GetNodes_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_cluster.proto", -} diff --git a/rpc/cloudagent/cloud/moc_cloudagent_controlplane.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_controlplane.pb.go deleted file mode 100644 index 5483c264..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_controlplane.pb.go +++ /dev/null @@ -1,372 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_controlplane.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type ControlPlaneState int32 - -const ( - ControlPlaneState_NotLeader ControlPlaneState = 0 - ControlPlaneState_Leader ControlPlaneState = 1 -) - -var ControlPlaneState_name = map[int32]string{ - 0: "NotLeader", - 1: "Leader", -} - -var ControlPlaneState_value = map[string]int32{ - "NotLeader": 0, - "Leader": 1, -} - -func (x ControlPlaneState) String() string { - return proto.EnumName(ControlPlaneState_name, int32(x)) -} - -func (ControlPlaneState) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_690e71c673ae0745, []int{0} -} - -type ControlPlaneRequest struct { - ControlPlanes []*ControlPlane `protobuf:"bytes,1,rep,name=ControlPlanes,proto3" json:"ControlPlanes,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ControlPlaneRequest) Reset() { *m = ControlPlaneRequest{} } -func (m *ControlPlaneRequest) String() string { return proto.CompactTextString(m) } -func (*ControlPlaneRequest) ProtoMessage() {} -func (*ControlPlaneRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_690e71c673ae0745, []int{0} -} - -func (m *ControlPlaneRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ControlPlaneRequest.Unmarshal(m, b) -} -func (m *ControlPlaneRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ControlPlaneRequest.Marshal(b, m, deterministic) -} -func (m *ControlPlaneRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_ControlPlaneRequest.Merge(m, src) -} -func (m *ControlPlaneRequest) XXX_Size() int { - return xxx_messageInfo_ControlPlaneRequest.Size(m) -} -func (m *ControlPlaneRequest) XXX_DiscardUnknown() { - xxx_messageInfo_ControlPlaneRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_ControlPlaneRequest proto.InternalMessageInfo - -func (m *ControlPlaneRequest) GetControlPlanes() []*ControlPlane { - if m != nil { - return m.ControlPlanes - } - return nil -} - -func (m *ControlPlaneRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type ControlPlaneResponse struct { - ControlPlanes []*ControlPlane `protobuf:"bytes,1,rep,name=ControlPlanes,proto3" json:"ControlPlanes,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ControlPlaneResponse) Reset() { *m = ControlPlaneResponse{} } -func (m *ControlPlaneResponse) String() string { return proto.CompactTextString(m) } -func (*ControlPlaneResponse) ProtoMessage() {} -func (*ControlPlaneResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_690e71c673ae0745, []int{1} -} - -func (m *ControlPlaneResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ControlPlaneResponse.Unmarshal(m, b) -} -func (m *ControlPlaneResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ControlPlaneResponse.Marshal(b, m, deterministic) -} -func (m *ControlPlaneResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_ControlPlaneResponse.Merge(m, src) -} -func (m *ControlPlaneResponse) XXX_Size() int { - return xxx_messageInfo_ControlPlaneResponse.Size(m) -} -func (m *ControlPlaneResponse) XXX_DiscardUnknown() { - xxx_messageInfo_ControlPlaneResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_ControlPlaneResponse proto.InternalMessageInfo - -func (m *ControlPlaneResponse) GetControlPlanes() []*ControlPlane { - if m != nil { - return m.ControlPlanes - } - return nil -} - -func (m *ControlPlaneResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *ControlPlaneResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -// There is a ControlPlane entity for every CloudAgent -// participating to provide high availability without -// FailoverCluster -type ControlPlane struct { - // id is an internal value required for all entities - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - // name is an identifier provided during ControlPlane creation - Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` - // locationName is the name of the Location entity this ControlPlane belongs to - LocationName string `protobuf:"bytes,3,opt,name=locationName,proto3" json:"locationName,omitempty"` - // fqdn is the fqdn, hostname, or ip address that this ControlPlane will use as part of the leadership election - Fqdn string `protobuf:"bytes,4,opt,name=fqdn,proto3" json:"fqdn,omitempty"` - // port is the port that this ControlPlane will use as part of the leadership election - Port int32 `protobuf:"varint,5,opt,name=port,proto3" json:"port,omitempty"` - // status is a standard entity status - Status *common.Status `protobuf:"bytes,6,opt,name=status,proto3" json:"status,omitempty"` - // state stores the last known election status of this ControlPlane - State ControlPlaneState `protobuf:"varint,7,opt,name=state,proto3,enum=moc.cloudagent.controlplane.ControlPlaneState" json:"state,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ControlPlane) Reset() { *m = ControlPlane{} } -func (m *ControlPlane) String() string { return proto.CompactTextString(m) } -func (*ControlPlane) ProtoMessage() {} -func (*ControlPlane) Descriptor() ([]byte, []int) { - return fileDescriptor_690e71c673ae0745, []int{2} -} - -func (m *ControlPlane) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ControlPlane.Unmarshal(m, b) -} -func (m *ControlPlane) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ControlPlane.Marshal(b, m, deterministic) -} -func (m *ControlPlane) XXX_Merge(src proto.Message) { - xxx_messageInfo_ControlPlane.Merge(m, src) -} -func (m *ControlPlane) XXX_Size() int { - return xxx_messageInfo_ControlPlane.Size(m) -} -func (m *ControlPlane) XXX_DiscardUnknown() { - xxx_messageInfo_ControlPlane.DiscardUnknown(m) -} - -var xxx_messageInfo_ControlPlane proto.InternalMessageInfo - -func (m *ControlPlane) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *ControlPlane) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *ControlPlane) GetLocationName() string { - if m != nil { - return m.LocationName - } - return "" -} - -func (m *ControlPlane) GetFqdn() string { - if m != nil { - return m.Fqdn - } - return "" -} - -func (m *ControlPlane) GetPort() int32 { - if m != nil { - return m.Port - } - return 0 -} - -func (m *ControlPlane) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func (m *ControlPlane) GetState() ControlPlaneState { - if m != nil { - return m.State - } - return ControlPlaneState_NotLeader -} - -func init() { - proto.RegisterEnum("moc.cloudagent.controlplane.ControlPlaneState", ControlPlaneState_name, ControlPlaneState_value) - proto.RegisterType((*ControlPlaneRequest)(nil), "moc.cloudagent.controlplane.ControlPlaneRequest") - proto.RegisterType((*ControlPlaneResponse)(nil), "moc.cloudagent.controlplane.ControlPlaneResponse") - proto.RegisterType((*ControlPlane)(nil), "moc.cloudagent.controlplane.ControlPlane") -} - -func init() { proto.RegisterFile("moc_cloudagent_controlplane.proto", fileDescriptor_690e71c673ae0745) } - -var fileDescriptor_690e71c673ae0745 = []byte{ - // 441 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x52, 0xd1, 0x6e, 0xd3, 0x30, - 0x14, 0x9d, 0xbb, 0x35, 0xa8, 0xb7, 0x6b, 0x05, 0x66, 0x12, 0x51, 0x91, 0x50, 0x09, 0x2f, 0x05, - 0x09, 0x07, 0x02, 0x3f, 0xc0, 0x80, 0x07, 0x24, 0xb4, 0x21, 0x83, 0x78, 0xe0, 0x65, 0x4a, 0x1d, - 0xb7, 0x44, 0x24, 0xbe, 0x9e, 0xed, 0x80, 0x78, 0xe7, 0x33, 0xf8, 0x09, 0x3e, 0x8b, 0xbf, 0x40, - 0xb6, 0x03, 0x6b, 0x84, 0x84, 0x86, 0xb4, 0xa7, 0x9c, 0xdc, 0x7b, 0xce, 0xf1, 0x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0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// ControlPlaneAgentClient is the client API for ControlPlaneAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type ControlPlaneAgentClient interface { - Invoke(ctx context.Context, in *ControlPlaneRequest, opts ...grpc.CallOption) (*ControlPlaneResponse, error) -} - -type controlPlaneAgentClient struct { - cc *grpc.ClientConn -} - -func NewControlPlaneAgentClient(cc *grpc.ClientConn) ControlPlaneAgentClient { - return &controlPlaneAgentClient{cc} -} - -func (c *controlPlaneAgentClient) Invoke(ctx context.Context, in *ControlPlaneRequest, opts ...grpc.CallOption) (*ControlPlaneResponse, error) { - out := new(ControlPlaneResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.controlplane.ControlPlaneAgent/Invoke", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// ControlPlaneAgentServer is the server API for ControlPlaneAgent service. -type ControlPlaneAgentServer interface { - Invoke(context.Context, *ControlPlaneRequest) (*ControlPlaneResponse, error) -} - -// UnimplementedControlPlaneAgentServer can be embedded to have forward compatible implementations. -type UnimplementedControlPlaneAgentServer struct { -} - -func (*UnimplementedControlPlaneAgentServer) Invoke(ctx context.Context, req *ControlPlaneRequest) (*ControlPlaneResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") -} - -func RegisterControlPlaneAgentServer(s *grpc.Server, srv ControlPlaneAgentServer) { - s.RegisterService(&_ControlPlaneAgent_serviceDesc, srv) -} - -func _ControlPlaneAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ControlPlaneRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ControlPlaneAgentServer).Invoke(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.controlplane.ControlPlaneAgent/Invoke", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ControlPlaneAgentServer).Invoke(ctx, req.(*ControlPlaneRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _ControlPlaneAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.controlplane.ControlPlaneAgent", - HandlerType: (*ControlPlaneAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Invoke", - Handler: _ControlPlaneAgent_Invoke_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_controlplane.proto", -} diff --git a/rpc/cloudagent/cloud/moc_cloudagent_etcdcluster.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_etcdcluster.pb.go deleted file mode 100644 index c2bd4ea6..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_etcdcluster.pb.go +++ /dev/null @@ -1,337 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_etcdcluster.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type EtcdClusterRequest struct { - EtcdClusters []*EtcdCluster `protobuf:"bytes,1,rep,name=EtcdClusters,proto3" json:"EtcdClusters,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdClusterRequest) Reset() { *m = EtcdClusterRequest{} } -func (m *EtcdClusterRequest) String() string { return proto.CompactTextString(m) } -func (*EtcdClusterRequest) ProtoMessage() {} -func (*EtcdClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_8d73c226ba9892c4, []int{0} -} - -func (m *EtcdClusterRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdClusterRequest.Unmarshal(m, b) -} -func (m *EtcdClusterRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdClusterRequest.Marshal(b, m, deterministic) -} -func (m *EtcdClusterRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdClusterRequest.Merge(m, src) -} -func (m *EtcdClusterRequest) XXX_Size() int { - return xxx_messageInfo_EtcdClusterRequest.Size(m) -} -func (m *EtcdClusterRequest) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdClusterRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdClusterRequest proto.InternalMessageInfo - -func (m *EtcdClusterRequest) GetEtcdClusters() []*EtcdCluster { - if m != nil { - return m.EtcdClusters - } - return nil -} - -func (m *EtcdClusterRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type EtcdClusterResponse struct { - EtcdClusters []*EtcdCluster `protobuf:"bytes,1,rep,name=EtcdClusters,proto3" json:"EtcdClusters,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdClusterResponse) Reset() { *m = EtcdClusterResponse{} } -func (m *EtcdClusterResponse) String() string { return proto.CompactTextString(m) } -func (*EtcdClusterResponse) ProtoMessage() {} -func (*EtcdClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_8d73c226ba9892c4, []int{1} -} - -func (m *EtcdClusterResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdClusterResponse.Unmarshal(m, b) -} -func (m *EtcdClusterResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdClusterResponse.Marshal(b, m, deterministic) -} -func (m *EtcdClusterResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdClusterResponse.Merge(m, src) -} -func (m *EtcdClusterResponse) XXX_Size() int { - return xxx_messageInfo_EtcdClusterResponse.Size(m) -} -func (m *EtcdClusterResponse) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdClusterResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdClusterResponse proto.InternalMessageInfo - -func (m *EtcdClusterResponse) GetEtcdClusters() []*EtcdCluster { - if m != nil { - return m.EtcdClusters - } - return nil -} - -func (m *EtcdClusterResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *EtcdClusterResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type EtcdCluster struct { - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` - LocationName string `protobuf:"bytes,3,opt,name=locationName,proto3" json:"locationName,omitempty"` - GroupName string `protobuf:"bytes,4,opt,name=groupName,proto3" json:"groupName,omitempty"` - // etcd ca certificate that works as RoT for client and peer connections - CaCertificate string `protobuf:"bytes,5,opt,name=caCertificate,proto3" json:"caCertificate,omitempty"` - // etcd ca key associated with the ca certificate - CaKey string `protobuf:"bytes,6,opt,name=caKey,proto3" json:"caKey,omitempty"` - Status *common.Status `protobuf:"bytes,7,opt,name=status,proto3" json:"status,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdCluster) Reset() { *m = EtcdCluster{} } -func (m *EtcdCluster) String() string { return proto.CompactTextString(m) } -func (*EtcdCluster) ProtoMessage() {} -func (*EtcdCluster) Descriptor() ([]byte, []int) { - return fileDescriptor_8d73c226ba9892c4, []int{2} -} - -func (m *EtcdCluster) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdCluster.Unmarshal(m, b) -} -func (m *EtcdCluster) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdCluster.Marshal(b, m, deterministic) -} -func (m *EtcdCluster) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdCluster.Merge(m, src) -} -func (m *EtcdCluster) XXX_Size() int { - return xxx_messageInfo_EtcdCluster.Size(m) -} -func (m *EtcdCluster) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdCluster.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdCluster proto.InternalMessageInfo - -func (m *EtcdCluster) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *EtcdCluster) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *EtcdCluster) GetLocationName() string { - if m != nil { - return m.LocationName - } - return "" -} - -func (m *EtcdCluster) GetGroupName() string { - if m != nil { - return m.GroupName - } - return "" -} - -func (m *EtcdCluster) GetCaCertificate() string { - if m != nil { - return m.CaCertificate - } - return "" -} - -func (m *EtcdCluster) GetCaKey() string { - if m != nil { - return m.CaKey - } - return "" -} - -func (m *EtcdCluster) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func init() { - proto.RegisterType((*EtcdClusterRequest)(nil), "moc.cloudagent.etcd.EtcdClusterRequest") - proto.RegisterType((*EtcdClusterResponse)(nil), "moc.cloudagent.etcd.EtcdClusterResponse") - proto.RegisterType((*EtcdCluster)(nil), "moc.cloudagent.etcd.EtcdCluster") -} - -func init() { proto.RegisterFile("moc_cloudagent_etcdcluster.proto", fileDescriptor_8d73c226ba9892c4) } - -var fileDescriptor_8d73c226ba9892c4 = []byte{ - // 430 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x92, 0xdf, 0x8a, 0xd3, 0x40, - 0x14, 0xc6, 0x4d, 0xb7, 0x8d, 0xf4, 0x74, 0xb7, 0xc8, 0xac, 0x60, 0x08, 0x22, 0x21, 0x5e, 0x58, - 0x04, 0x27, 0x10, 0x7d, 0x01, 0xbb, 0xee, 0x85, 0x08, 0x0a, 0x51, 0xbc, 0x10, 0x64, 0x99, 0x4e, - 0x4e, 0x63, 0x30, 0xc9, 0xc9, 0xce, 0x1f, 0x65, 0xdf, 0xc0, 0x4b, 0x5f, 0xc2, 0x47, 0xf0, 0x7d, - 0x7c, 0x14, 0xe9, 0x4c, 0xb5, 0x09, 0x08, 0xbd, 0xf1, 0xaa, 0xd3, 0xf3, 0xfd, 0xce, 0x37, 0xe7, - 0x7c, 0x13, 0x48, 0x5a, 0x92, 0x57, 0xb2, 0x21, 0x5b, 0x8a, 0x0a, 0x3b, 0x73, 0x85, 0x46, 0x96, - 0xb2, 0xb1, 0xda, 0xa0, 0xe2, 0xbd, 0x22, 0x43, 0xec, 0xbc, 0x25, 0xc9, 0x0f, 0x04, 0xdf, 0x11, - 0xf1, 0x83, 0x8a, 0xa8, 0x6a, 0x30, 0x73, 0xc8, 0xc6, 0x6e, 0xb3, 0xaf, 0x4a, 0xf4, 0x3d, 0x2a, - 0xed, 0x9b, 0xe2, 0x7b, 0xce, 0x96, 0xda, 0x96, 0xba, 0xfd, 0x8f, 0x17, 0xd2, 0xef, 0x01, 0xb0, - 0x4b, 0x23, 0xcb, 0x0b, 0x7f, 0x47, 0x81, 0xd7, 0x16, 0xb5, 0x61, 0x2f, 0xe0, 0x74, 0x50, 0xd5, - 0x51, 0x90, 0x9c, 0xac, 0x16, 0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2, 0xe5, 0xf8, 0xd6, 0x95, 0x8a, - 0xbd, 0x94, 0x5f, 0xc3, 0x9d, 0xc1, 0x86, 0xcf, 0x77, 0xf9, 0xb2, 0x8f, 0x10, 0xbe, 0xec, 0xbe, - 0xd0, 0x67, 0x64, 0x8f, 0x8e, 0x46, 0xef, 0xbf, 0xa6, 0x78, 0x75, 0x1c, 0xf4, 0x6f, 0x9c, 0xde, - 0x5a, 0x67, 0x1f, 0x9e, 0x54, 0xb5, 0xf9, 0x64, 0x37, 0x5c, 0x52, 0x9b, 0xb5, 0xb5, 0x54, 0xa4, - 0x69, 0x6b, 0xb2, 0x96, 0x64, 0xa6, 0x7a, 0x99, 0x1d, 0x5c, 0xfc, 0x71, 0x13, 0xba, 0x87, 0x7b, - 0xfa, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x41, 0xe7, 0xd5, 0xeb, 0x3a, 0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// EtcdClusterAgentClient is the client API for EtcdClusterAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type EtcdClusterAgentClient interface { - Invoke(ctx context.Context, in *EtcdClusterRequest, opts ...grpc.CallOption) (*EtcdClusterResponse, error) -} - -type etcdClusterAgentClient struct { - cc *grpc.ClientConn -} - -func NewEtcdClusterAgentClient(cc *grpc.ClientConn) EtcdClusterAgentClient { - return &etcdClusterAgentClient{cc} -} - -func (c *etcdClusterAgentClient) Invoke(ctx context.Context, in *EtcdClusterRequest, opts ...grpc.CallOption) (*EtcdClusterResponse, error) { - out := new(EtcdClusterResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.etcd.EtcdClusterAgent/Invoke", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// EtcdClusterAgentServer is the server API for EtcdClusterAgent service. -type EtcdClusterAgentServer interface { - Invoke(context.Context, *EtcdClusterRequest) (*EtcdClusterResponse, error) -} - -// UnimplementedEtcdClusterAgentServer can be embedded to have forward compatible implementations. -type UnimplementedEtcdClusterAgentServer struct { -} - -func (*UnimplementedEtcdClusterAgentServer) Invoke(ctx context.Context, req *EtcdClusterRequest) (*EtcdClusterResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") -} - -func RegisterEtcdClusterAgentServer(s *grpc.Server, srv EtcdClusterAgentServer) { - s.RegisterService(&_EtcdClusterAgent_serviceDesc, srv) -} - -func _EtcdClusterAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(EtcdClusterRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(EtcdClusterAgentServer).Invoke(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.etcd.EtcdClusterAgent/Invoke", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EtcdClusterAgentServer).Invoke(ctx, req.(*EtcdClusterRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _EtcdClusterAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.etcd.EtcdClusterAgent", - HandlerType: (*EtcdClusterAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Invoke", - Handler: _EtcdClusterAgent_Invoke_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_etcdcluster.proto", -} diff --git a/rpc/cloudagent/cloud/moc_cloudagent_etcdserver.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_etcdserver.pb.go deleted file mode 100644 index d52a0c8c..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_etcdserver.pb.go +++ /dev/null @@ -1,355 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_etcdserver.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type EtcdServerRequest struct { - EtcdServers []*EtcdServer `protobuf:"bytes,1,rep,name=EtcdServers,proto3" json:"EtcdServers,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdServerRequest) Reset() { *m = EtcdServerRequest{} } -func (m *EtcdServerRequest) String() string { return proto.CompactTextString(m) } -func (*EtcdServerRequest) ProtoMessage() {} -func (*EtcdServerRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_d0ace618052d3694, []int{0} -} - -func (m *EtcdServerRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdServerRequest.Unmarshal(m, b) -} -func (m *EtcdServerRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdServerRequest.Marshal(b, m, deterministic) -} -func (m *EtcdServerRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdServerRequest.Merge(m, src) -} -func (m *EtcdServerRequest) XXX_Size() int { - return xxx_messageInfo_EtcdServerRequest.Size(m) -} -func (m *EtcdServerRequest) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdServerRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdServerRequest proto.InternalMessageInfo - -func (m *EtcdServerRequest) GetEtcdServers() []*EtcdServer { - if m != nil { - return m.EtcdServers - } - return nil -} - -func (m *EtcdServerRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type EtcdServerResponse struct { - EtcdServers []*EtcdServer `protobuf:"bytes,1,rep,name=EtcdServers,proto3" json:"EtcdServers,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdServerResponse) Reset() { *m = EtcdServerResponse{} } -func (m *EtcdServerResponse) String() string { return proto.CompactTextString(m) } -func (*EtcdServerResponse) ProtoMessage() {} -func (*EtcdServerResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_d0ace618052d3694, []int{1} -} - -func (m *EtcdServerResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdServerResponse.Unmarshal(m, b) -} -func (m *EtcdServerResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdServerResponse.Marshal(b, m, deterministic) -} -func (m *EtcdServerResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdServerResponse.Merge(m, src) -} -func (m *EtcdServerResponse) XXX_Size() int { - return xxx_messageInfo_EtcdServerResponse.Size(m) -} -func (m *EtcdServerResponse) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdServerResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdServerResponse proto.InternalMessageInfo - -func (m *EtcdServerResponse) GetEtcdServers() []*EtcdServer { - if m != nil { - return m.EtcdServers - } - return nil -} - -func (m *EtcdServerResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *EtcdServerResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type EtcdServer struct { - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` - EtcdClusterName string `protobuf:"bytes,3,opt,name=etcdClusterName,proto3" json:"etcdClusterName,omitempty"` - ClusterId string `protobuf:"bytes,4,opt,name=clusterId,proto3" json:"clusterId,omitempty"` - LocationName string `protobuf:"bytes,5,opt,name=locationName,proto3" json:"locationName,omitempty"` - GroupName string `protobuf:"bytes,6,opt,name=groupName,proto3" json:"groupName,omitempty"` - // fqdn is the fqdn, hostname, or ip address that this EtcdServer will - // advertise on - Fqdn string `protobuf:"bytes,7,opt,name=fqdn,proto3" json:"fqdn,omitempty"` - // etcd client port to listen on - ClientPort uint32 `protobuf:"varint,8,opt,name=clientPort,proto3" json:"clientPort,omitempty"` - Status *common.Status `protobuf:"bytes,9,opt,name=status,proto3" json:"status,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *EtcdServer) Reset() { *m = EtcdServer{} } -func (m *EtcdServer) String() string { return proto.CompactTextString(m) } -func (*EtcdServer) ProtoMessage() {} -func (*EtcdServer) Descriptor() ([]byte, []int) { - return fileDescriptor_d0ace618052d3694, []int{2} -} - -func (m *EtcdServer) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EtcdServer.Unmarshal(m, b) -} -func (m *EtcdServer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EtcdServer.Marshal(b, m, deterministic) -} -func (m *EtcdServer) XXX_Merge(src proto.Message) { - xxx_messageInfo_EtcdServer.Merge(m, src) -} -func (m *EtcdServer) XXX_Size() int { - return xxx_messageInfo_EtcdServer.Size(m) -} -func (m *EtcdServer) XXX_DiscardUnknown() { - xxx_messageInfo_EtcdServer.DiscardUnknown(m) -} - -var xxx_messageInfo_EtcdServer proto.InternalMessageInfo - -func (m *EtcdServer) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *EtcdServer) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *EtcdServer) GetEtcdClusterName() string { - if m != nil { - return m.EtcdClusterName - } - return "" -} - -func (m *EtcdServer) GetClusterId() string { - if m != nil { - return m.ClusterId - } - return "" -} - -func (m *EtcdServer) GetLocationName() string { - if m != nil { - return m.LocationName - } - return "" -} - -func (m *EtcdServer) GetGroupName() string { - if m != nil { - return m.GroupName - } - return "" -} - -func (m *EtcdServer) GetFqdn() string { - if m != nil { - return m.Fqdn - } - return "" -} - -func (m *EtcdServer) GetClientPort() uint32 { - if m != nil { - return m.ClientPort - } - return 0 -} - -func (m *EtcdServer) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func init() { - proto.RegisterType((*EtcdServerRequest)(nil), "moc.cloudagent.etcd.EtcdServerRequest") - proto.RegisterType((*EtcdServerResponse)(nil), "moc.cloudagent.etcd.EtcdServerResponse") - proto.RegisterType((*EtcdServer)(nil), "moc.cloudagent.etcd.EtcdServer") -} - -func init() { proto.RegisterFile("moc_cloudagent_etcdserver.proto", fileDescriptor_d0ace618052d3694) } - -var fileDescriptor_d0ace618052d3694 = []byte{ - // 445 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x52, 0x4d, 0x6f, 0xd4, 0x30, - 0x10, 0x25, 0xdb, 0x36, 0xb0, 0xb3, 0x74, 0x2b, 0x0c, 0x12, 0xd1, 0x0a, 0xb5, 0xab, 0x20, 0x41, - 0x2e, 0x38, 0x52, 0xe0, 0x0f, 0xb4, 0xa8, 0x87, 0x5e, 0x00, 0xa5, 0x88, 0x03, 0x1c, 0xaa, 0xac, - 0xe3, 0x0d, 0x11, 0x89, 0xc7, 0xf5, 0x47, 0x11, 0xff, 0x81, 0x1b, 0xbf, 0x80, 0x7f, 0x8a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xa1, 0x5c, 0xc5, 0xb4, 0xe8, 0xd7, 0x7f, - 0x02, 0x00, 0x00, 0xff, 0xff, 0x10, 0xa8, 0x36, 0x47, 0x61, 0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// EtcdServerAgentClient is the client API for EtcdServerAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type EtcdServerAgentClient interface { - Invoke(ctx context.Context, in *EtcdServerRequest, opts ...grpc.CallOption) (*EtcdServerResponse, error) -} - -type etcdServerAgentClient struct { - cc *grpc.ClientConn -} - -func NewEtcdServerAgentClient(cc *grpc.ClientConn) EtcdServerAgentClient { - return &etcdServerAgentClient{cc} -} - -func (c *etcdServerAgentClient) Invoke(ctx context.Context, in *EtcdServerRequest, opts ...grpc.CallOption) (*EtcdServerResponse, error) { - out := new(EtcdServerResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.etcd.EtcdServerAgent/Invoke", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// EtcdServerAgentServer is the server API for EtcdServerAgent service. -type EtcdServerAgentServer interface { - Invoke(context.Context, *EtcdServerRequest) (*EtcdServerResponse, error) -} - -// UnimplementedEtcdServerAgentServer can be embedded to have forward compatible implementations. -type UnimplementedEtcdServerAgentServer struct { -} - -func (*UnimplementedEtcdServerAgentServer) Invoke(ctx context.Context, req *EtcdServerRequest) (*EtcdServerResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") -} - -func RegisterEtcdServerAgentServer(s *grpc.Server, srv EtcdServerAgentServer) { - s.RegisterService(&_EtcdServerAgent_serviceDesc, srv) -} - -func _EtcdServerAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(EtcdServerRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(EtcdServerAgentServer).Invoke(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.etcd.EtcdServerAgent/Invoke", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EtcdServerAgentServer).Invoke(ctx, req.(*EtcdServerRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _EtcdServerAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.etcd.EtcdServerAgent", - HandlerType: (*EtcdServerAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Invoke", - Handler: _EtcdServerAgent_Invoke_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_etcdserver.proto", -} diff --git a/rpc/cloudagent/cloud/moc_cloudagent_kubernetes.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_kubernetes.pb.go deleted file mode 100644 index 2fd31a0d..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_kubernetes.pb.go +++ /dev/null @@ -1,956 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_kubernetes.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type NodeType int32 - -const ( - NodeType_ControlPlane NodeType = 0 - NodeType_LinuxWorker NodeType = 1 - NodeType_WindowsWorker NodeType = 2 - NodeType_LoadBalancer NodeType = 3 -) - -var NodeType_name = map[int32]string{ - 0: "ControlPlane", - 1: "LinuxWorker", - 2: "WindowsWorker", - 3: "LoadBalancer", -} - -var NodeType_value = map[string]int32{ - "ControlPlane": 0, - "LinuxWorker": 1, - "WindowsWorker": 2, - "LoadBalancer": 3, -} - -func (x NodeType) String() string { - return proto.EnumName(NodeType_name, int32(x)) -} - -func (NodeType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{0} -} - -type ManagementStrategyType int32 - -const ( - ManagementStrategyType_Pivoted ManagementStrategyType = 0 - ManagementStrategyType_Distinct ManagementStrategyType = 1 -) - -var ManagementStrategyType_name = map[int32]string{ - 0: "Pivoted", - 1: "Distinct", -} - -var ManagementStrategyType_value = map[string]int32{ - "Pivoted": 0, - "Distinct": 1, -} - -func (x ManagementStrategyType) String() string { - return proto.EnumName(ManagementStrategyType_name, int32(x)) -} - -func (ManagementStrategyType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{1} -} - -type KubernetesRequest struct { - Kubernetess []*Kubernetes `protobuf:"bytes,1,rep,name=Kubernetess,proto3" json:"Kubernetess,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *KubernetesRequest) Reset() { *m = KubernetesRequest{} } -func (m *KubernetesRequest) String() string { return proto.CompactTextString(m) } -func (*KubernetesRequest) ProtoMessage() {} -func (*KubernetesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{0} -} - -func (m *KubernetesRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_KubernetesRequest.Unmarshal(m, b) -} -func (m *KubernetesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_KubernetesRequest.Marshal(b, m, deterministic) -} -func (m *KubernetesRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_KubernetesRequest.Merge(m, src) -} -func (m *KubernetesRequest) XXX_Size() int { - return xxx_messageInfo_KubernetesRequest.Size(m) -} -func (m *KubernetesRequest) XXX_DiscardUnknown() { - xxx_messageInfo_KubernetesRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_KubernetesRequest proto.InternalMessageInfo - -func (m *KubernetesRequest) GetKubernetess() []*Kubernetes { - if m != nil { - return m.Kubernetess - } - return nil -} - -func (m *KubernetesRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type KubernetesResponse struct { - Kubernetess []*Kubernetes `protobuf:"bytes,1,rep,name=Kubernetess,proto3" json:"Kubernetess,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *KubernetesResponse) Reset() { *m = KubernetesResponse{} } -func (m *KubernetesResponse) String() string { return proto.CompactTextString(m) } -func (*KubernetesResponse) ProtoMessage() {} -func (*KubernetesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{1} -} - -func (m *KubernetesResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_KubernetesResponse.Unmarshal(m, b) -} -func (m *KubernetesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_KubernetesResponse.Marshal(b, m, deterministic) -} -func (m *KubernetesResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_KubernetesResponse.Merge(m, src) -} -func (m *KubernetesResponse) XXX_Size() int { - return xxx_messageInfo_KubernetesResponse.Size(m) -} -func (m *KubernetesResponse) XXX_DiscardUnknown() { - xxx_messageInfo_KubernetesResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_KubernetesResponse proto.InternalMessageInfo - -func (m *KubernetesResponse) GetKubernetess() []*Kubernetes { - if m != nil { - return m.Kubernetess - } - return nil -} - -func (m *KubernetesResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *KubernetesResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type StorageConfiguration struct { - Csi string `protobuf:"bytes,1,opt,name=csi,proto3" json:"csi,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *StorageConfiguration) Reset() { *m = StorageConfiguration{} } -func (m *StorageConfiguration) String() string { return proto.CompactTextString(m) } -func (*StorageConfiguration) ProtoMessage() {} -func (*StorageConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{2} -} - -func (m *StorageConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_StorageConfiguration.Unmarshal(m, b) -} -func (m *StorageConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_StorageConfiguration.Marshal(b, m, deterministic) -} -func (m *StorageConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_StorageConfiguration.Merge(m, src) -} -func (m *StorageConfiguration) XXX_Size() int { - return xxx_messageInfo_StorageConfiguration.Size(m) -} -func (m *StorageConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_StorageConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_StorageConfiguration proto.InternalMessageInfo - -func (m *StorageConfiguration) GetCsi() string { - if m != nil { - return m.Csi - } - return "" -} - -type NetworkConfiguration struct { - Cni string `protobuf:"bytes,1,opt,name=cni,proto3" json:"cni,omitempty"` - PodCidr string `protobuf:"bytes,2,opt,name=podCidr,proto3" json:"podCidr,omitempty"` - ClusterCidr string `protobuf:"bytes,3,opt,name=clusterCidr,proto3" json:"clusterCidr,omitempty"` - // TODO: merge controlplane cidr and network - ControlPlaneCidr string `protobuf:"bytes,4,opt,name=controlPlaneCidr,proto3" json:"controlPlaneCidr,omitempty"` - Virtualnetwork string `protobuf:"bytes,5,opt,name=virtualnetwork,proto3" json:"virtualnetwork,omitempty"` - LoadBalancerVip string `protobuf:"bytes,6,opt,name=loadBalancerVip,proto3" json:"loadBalancerVip,omitempty"` - LoadBalancerMac string `protobuf:"bytes,7,opt,name=loadBalancerMac,proto3" json:"loadBalancerMac,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *NetworkConfiguration) Reset() { *m = NetworkConfiguration{} } -func (m *NetworkConfiguration) String() string { return proto.CompactTextString(m) } -func (*NetworkConfiguration) ProtoMessage() {} -func (*NetworkConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{3} -} - -func (m *NetworkConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_NetworkConfiguration.Unmarshal(m, b) -} -func (m *NetworkConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_NetworkConfiguration.Marshal(b, m, deterministic) -} -func (m *NetworkConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_NetworkConfiguration.Merge(m, src) -} -func (m *NetworkConfiguration) XXX_Size() int { - return xxx_messageInfo_NetworkConfiguration.Size(m) -} -func (m *NetworkConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_NetworkConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_NetworkConfiguration proto.InternalMessageInfo - -func (m *NetworkConfiguration) GetCni() string { - if m != nil { - return m.Cni - } - return "" -} - -func (m *NetworkConfiguration) GetPodCidr() string { - if m != nil { - return m.PodCidr - } - return "" -} - -func (m *NetworkConfiguration) GetClusterCidr() string { - if m != nil { - return m.ClusterCidr - } - return "" -} - -func (m *NetworkConfiguration) GetControlPlaneCidr() string { - if m != nil { - return m.ControlPlaneCidr - } - return "" -} - -func (m *NetworkConfiguration) GetVirtualnetwork() string { - if m != nil { - return m.Virtualnetwork - } - return "" -} - -func (m *NetworkConfiguration) GetLoadBalancerVip() string { - if m != nil { - return m.LoadBalancerVip - } - return "" -} - -func (m *NetworkConfiguration) GetLoadBalancerMac() string { - if m != nil { - return m.LoadBalancerMac - } - return "" -} - -type NodePoolConfiguration struct { - NodeType NodeType `protobuf:"varint,1,opt,name=NodeType,proto3,enum=moc.cloudagent.kubernetes.NodeType" json:"NodeType,omitempty"` - Imagereference string `protobuf:"bytes,2,opt,name=imagereference,proto3" json:"imagereference,omitempty"` - Replicas int32 `protobuf:"varint,3,opt,name=replicas,proto3" json:"replicas,omitempty"` - VMSize string `protobuf:"bytes,4,opt,name=VMSize,proto3" json:"VMSize,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *NodePoolConfiguration) Reset() { *m = NodePoolConfiguration{} } -func (m *NodePoolConfiguration) String() string { return proto.CompactTextString(m) } -func (*NodePoolConfiguration) ProtoMessage() {} -func (*NodePoolConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{4} -} - -func (m *NodePoolConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_NodePoolConfiguration.Unmarshal(m, b) -} -func (m *NodePoolConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_NodePoolConfiguration.Marshal(b, m, deterministic) -} -func (m *NodePoolConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_NodePoolConfiguration.Merge(m, src) -} -func (m *NodePoolConfiguration) XXX_Size() int { - return xxx_messageInfo_NodePoolConfiguration.Size(m) -} -func (m *NodePoolConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_NodePoolConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_NodePoolConfiguration proto.InternalMessageInfo - -func (m *NodePoolConfiguration) GetNodeType() NodeType { - if m != nil { - return m.NodeType - } - return NodeType_ControlPlane -} - -func (m *NodePoolConfiguration) GetImagereference() string { - if m != nil { - return m.Imagereference - } - return "" -} - -func (m *NodePoolConfiguration) GetReplicas() int32 { - if m != nil { - return m.Replicas - } - return 0 -} - -func (m *NodePoolConfiguration) GetVMSize() string { - if m != nil { - return m.VMSize - } - return "" -} - -type SSHPublicKey struct { - KeyData string `protobuf:"bytes,1,opt,name=keyData,proto3" json:"keyData,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *SSHPublicKey) Reset() { *m = SSHPublicKey{} } -func (m *SSHPublicKey) String() string { return proto.CompactTextString(m) } -func (*SSHPublicKey) ProtoMessage() {} -func (*SSHPublicKey) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{5} -} - -func (m *SSHPublicKey) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_SSHPublicKey.Unmarshal(m, b) -} -func (m *SSHPublicKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_SSHPublicKey.Marshal(b, m, deterministic) -} -func (m *SSHPublicKey) XXX_Merge(src proto.Message) { - xxx_messageInfo_SSHPublicKey.Merge(m, src) -} -func (m *SSHPublicKey) XXX_Size() int { - return xxx_messageInfo_SSHPublicKey.Size(m) -} -func (m *SSHPublicKey) XXX_DiscardUnknown() { - xxx_messageInfo_SSHPublicKey.DiscardUnknown(m) -} - -var xxx_messageInfo_SSHPublicKey proto.InternalMessageInfo - -func (m *SSHPublicKey) GetKeyData() string { - if m != nil { - return m.KeyData - } - return "" -} - -type ComputeConfiguration struct { - Cri string `protobuf:"bytes,1,opt,name=cri,proto3" json:"cri,omitempty"` - PublicKey *SSHPublicKey `protobuf:"bytes,2,opt,name=publicKey,proto3" json:"publicKey,omitempty"` - NodePools []*NodePoolConfiguration `protobuf:"bytes,3,rep,name=NodePools,proto3" json:"NodePools,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ComputeConfiguration) Reset() { *m = ComputeConfiguration{} } -func (m *ComputeConfiguration) String() string { return proto.CompactTextString(m) } -func (*ComputeConfiguration) ProtoMessage() {} -func (*ComputeConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{6} -} - -func (m *ComputeConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ComputeConfiguration.Unmarshal(m, b) -} -func (m *ComputeConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ComputeConfiguration.Marshal(b, m, deterministic) -} -func (m *ComputeConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_ComputeConfiguration.Merge(m, src) -} -func (m *ComputeConfiguration) XXX_Size() int { - return xxx_messageInfo_ComputeConfiguration.Size(m) -} -func (m *ComputeConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_ComputeConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_ComputeConfiguration proto.InternalMessageInfo - -func (m *ComputeConfiguration) GetCri() string { - if m != nil { - return m.Cri - } - return "" -} - -func (m *ComputeConfiguration) GetPublicKey() *SSHPublicKey { - if m != nil { - return m.PublicKey - } - return nil -} - -func (m *ComputeConfiguration) GetNodePools() []*NodePoolConfiguration { - if m != nil { - return m.NodePools - } - return nil -} - -type ClusterConfiguration struct { - Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ClusterConfiguration) Reset() { *m = ClusterConfiguration{} } -func (m *ClusterConfiguration) String() string { return proto.CompactTextString(m) } -func (*ClusterConfiguration) ProtoMessage() {} -func (*ClusterConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{7} -} - -func (m *ClusterConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ClusterConfiguration.Unmarshal(m, b) -} -func (m *ClusterConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ClusterConfiguration.Marshal(b, m, deterministic) -} -func (m *ClusterConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterConfiguration.Merge(m, src) -} -func (m *ClusterConfiguration) XXX_Size() int { - return xxx_messageInfo_ClusterConfiguration.Size(m) -} -func (m *ClusterConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterConfiguration proto.InternalMessageInfo - -func (m *ClusterConfiguration) GetVersion() string { - if m != nil { - return m.Version - } - return "" -} - -type ClusterAPIConfiguration struct { - ConfigurationEndpoint string `protobuf:"bytes,1,opt,name=ConfigurationEndpoint,proto3" json:"ConfigurationEndpoint,omitempty"` - InfrastructureProviderVersion string `protobuf:"bytes,2,opt,name=InfrastructureProviderVersion,proto3" json:"InfrastructureProviderVersion,omitempty"` - BootstrapProviderVersion string `protobuf:"bytes,3,opt,name=BootstrapProviderVersion,proto3" json:"BootstrapProviderVersion,omitempty"` - ControlPlaneProviderVersion string `protobuf:"bytes,4,opt,name=ControlPlaneProviderVersion,proto3" json:"ControlPlaneProviderVersion,omitempty"` - CoreProviderVersion string `protobuf:"bytes,5,opt,name=CoreProviderVersion,proto3" json:"CoreProviderVersion,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ClusterAPIConfiguration) Reset() { *m = ClusterAPIConfiguration{} } -func (m *ClusterAPIConfiguration) String() string { return proto.CompactTextString(m) } -func (*ClusterAPIConfiguration) ProtoMessage() {} -func (*ClusterAPIConfiguration) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{8} -} - -func (m *ClusterAPIConfiguration) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ClusterAPIConfiguration.Unmarshal(m, b) -} -func (m *ClusterAPIConfiguration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ClusterAPIConfiguration.Marshal(b, m, deterministic) -} -func (m *ClusterAPIConfiguration) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterAPIConfiguration.Merge(m, src) -} -func (m *ClusterAPIConfiguration) XXX_Size() int { - return xxx_messageInfo_ClusterAPIConfiguration.Size(m) -} -func (m *ClusterAPIConfiguration) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterAPIConfiguration.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterAPIConfiguration proto.InternalMessageInfo - -func (m *ClusterAPIConfiguration) GetConfigurationEndpoint() string { - if m != nil { - return m.ConfigurationEndpoint - } - return "" -} - -func (m *ClusterAPIConfiguration) GetInfrastructureProviderVersion() string { - if m != nil { - return m.InfrastructureProviderVersion - } - return "" -} - -func (m *ClusterAPIConfiguration) GetBootstrapProviderVersion() string { - if m != nil { - return m.BootstrapProviderVersion - } - return "" -} - -func (m *ClusterAPIConfiguration) GetControlPlaneProviderVersion() string { - if m != nil { - return m.ControlPlaneProviderVersion - } - return "" -} - -func (m *ClusterAPIConfiguration) GetCoreProviderVersion() string { - if m != nil { - return m.CoreProviderVersion - } - return "" -} - -type ContainerRegistry struct { - Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` - Username string `protobuf:"bytes,2,opt,name=Username,proto3" json:"Username,omitempty"` - Password string `protobuf:"bytes,3,opt,name=Password,proto3" json:"Password,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ContainerRegistry) Reset() { *m = ContainerRegistry{} } -func (m *ContainerRegistry) String() string { return proto.CompactTextString(m) } -func (*ContainerRegistry) ProtoMessage() {} -func (*ContainerRegistry) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{9} -} - -func (m *ContainerRegistry) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ContainerRegistry.Unmarshal(m, b) -} -func (m *ContainerRegistry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ContainerRegistry.Marshal(b, m, deterministic) -} -func (m *ContainerRegistry) XXX_Merge(src proto.Message) { - xxx_messageInfo_ContainerRegistry.Merge(m, src) -} -func (m *ContainerRegistry) XXX_Size() int { - return xxx_messageInfo_ContainerRegistry.Size(m) -} -func (m *ContainerRegistry) XXX_DiscardUnknown() { - xxx_messageInfo_ContainerRegistry.DiscardUnknown(m) -} - -var xxx_messageInfo_ContainerRegistry proto.InternalMessageInfo - -func (m *ContainerRegistry) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *ContainerRegistry) GetUsername() string { - if m != nil { - return m.Username - } - return "" -} - -func (m *ContainerRegistry) GetPassword() string { - if m != nil { - return m.Password - } - return "" -} - -type Kubernetes struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` - Status *common.Status `protobuf:"bytes,4,opt,name=status,proto3" json:"status,omitempty"` - Cluster *ClusterConfiguration `protobuf:"bytes,5,opt,name=cluster,proto3" json:"cluster,omitempty"` - Network *NetworkConfiguration `protobuf:"bytes,6,opt,name=network,proto3" json:"network,omitempty"` - Storage *StorageConfiguration `protobuf:"bytes,7,opt,name=storage,proto3" json:"storage,omitempty"` - Compute *ComputeConfiguration `protobuf:"bytes,8,opt,name=compute,proto3" json:"compute,omitempty"` - GroupName string `protobuf:"bytes,9,opt,name=groupName,proto3" json:"groupName,omitempty"` - ManagementStrategy ManagementStrategyType `protobuf:"varint,10,opt,name=managementStrategy,proto3,enum=moc.cloudagent.kubernetes.ManagementStrategyType" json:"managementStrategy,omitempty"` - LocationName string `protobuf:"bytes,11,opt,name=locationName,proto3" json:"locationName,omitempty"` - KubeConfig []byte `protobuf:"bytes,12,opt,name=kubeConfig,proto3" json:"kubeConfig,omitempty"` - CapiConfig *ClusterAPIConfiguration `protobuf:"bytes,13,opt,name=capiConfig,proto3" json:"capiConfig,omitempty"` - ContainerRegistry *ContainerRegistry `protobuf:"bytes,14,opt,name=containerRegistry,proto3" json:"containerRegistry,omitempty"` - DeploymentManifest []byte `protobuf:"bytes,15,opt,name=deploymentManifest,proto3" json:"deploymentManifest,omitempty"` - Tags *common.Tags `protobuf:"bytes,16,opt,name=tags,proto3" json:"tags,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Kubernetes) Reset() { *m = Kubernetes{} } -func (m *Kubernetes) String() string { return proto.CompactTextString(m) } -func (*Kubernetes) ProtoMessage() {} -func (*Kubernetes) Descriptor() ([]byte, []int) { - return fileDescriptor_fbe617ed62e63e04, []int{10} -} - -func (m *Kubernetes) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Kubernetes.Unmarshal(m, b) -} -func (m *Kubernetes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Kubernetes.Marshal(b, m, deterministic) -} -func (m *Kubernetes) XXX_Merge(src proto.Message) { - xxx_messageInfo_Kubernetes.Merge(m, src) -} -func (m *Kubernetes) XXX_Size() int { - return xxx_messageInfo_Kubernetes.Size(m) -} -func (m *Kubernetes) XXX_DiscardUnknown() { - xxx_messageInfo_Kubernetes.DiscardUnknown(m) -} - -var xxx_messageInfo_Kubernetes proto.InternalMessageInfo - -func (m *Kubernetes) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *Kubernetes) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *Kubernetes) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func (m *Kubernetes) GetCluster() *ClusterConfiguration { - if m != nil { - return m.Cluster - } - return nil -} - -func (m *Kubernetes) GetNetwork() *NetworkConfiguration { - if m != nil { - return m.Network - } - return nil -} - -func (m *Kubernetes) GetStorage() *StorageConfiguration { - if m != nil { - return m.Storage - } - return nil -} - -func (m *Kubernetes) GetCompute() *ComputeConfiguration { - if m != nil { - return m.Compute - } - return nil -} - -func (m *Kubernetes) GetGroupName() string { - if m != nil { - return m.GroupName - } - return "" -} - -func (m *Kubernetes) GetManagementStrategy() ManagementStrategyType { - if m != nil { - return m.ManagementStrategy - } - return ManagementStrategyType_Pivoted -} - -func (m *Kubernetes) GetLocationName() string { - if m != nil { - return m.LocationName - } - return "" -} - -func (m *Kubernetes) GetKubeConfig() []byte { - if m != nil { - return m.KubeConfig - } - return nil -} - -func (m *Kubernetes) GetCapiConfig() *ClusterAPIConfiguration { - if m != nil { - return m.CapiConfig - } - return nil -} - -func (m *Kubernetes) GetContainerRegistry() *ContainerRegistry { - if m != nil { - return m.ContainerRegistry - } - return nil -} - -func (m *Kubernetes) GetDeploymentManifest() []byte { - if m != nil { - return m.DeploymentManifest - } - return nil -} - -func (m *Kubernetes) GetTags() *common.Tags { - if m != nil { - return m.Tags - } - return nil -} - -func init() { - proto.RegisterEnum("moc.cloudagent.kubernetes.NodeType", NodeType_name, NodeType_value) - proto.RegisterEnum("moc.cloudagent.kubernetes.ManagementStrategyType", ManagementStrategyType_name, ManagementStrategyType_value) - proto.RegisterType((*KubernetesRequest)(nil), "moc.cloudagent.kubernetes.KubernetesRequest") - proto.RegisterType((*KubernetesResponse)(nil), "moc.cloudagent.kubernetes.KubernetesResponse") - proto.RegisterType((*StorageConfiguration)(nil), "moc.cloudagent.kubernetes.StorageConfiguration") - proto.RegisterType((*NetworkConfiguration)(nil), "moc.cloudagent.kubernetes.NetworkConfiguration") - proto.RegisterType((*NodePoolConfiguration)(nil), "moc.cloudagent.kubernetes.NodePoolConfiguration") - proto.RegisterType((*SSHPublicKey)(nil), "moc.cloudagent.kubernetes.SSHPublicKey") - proto.RegisterType((*ComputeConfiguration)(nil), "moc.cloudagent.kubernetes.ComputeConfiguration") - proto.RegisterType((*ClusterConfiguration)(nil), "moc.cloudagent.kubernetes.ClusterConfiguration") - proto.RegisterType((*ClusterAPIConfiguration)(nil), "moc.cloudagent.kubernetes.ClusterAPIConfiguration") - proto.RegisterType((*ContainerRegistry)(nil), "moc.cloudagent.kubernetes.ContainerRegistry") - proto.RegisterType((*Kubernetes)(nil), "moc.cloudagent.kubernetes.Kubernetes") -} - -func init() { proto.RegisterFile("moc_cloudagent_kubernetes.proto", fileDescriptor_fbe617ed62e63e04) } - -var fileDescriptor_fbe617ed62e63e04 = []byte{ - // 1100 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0xcd, 0x72, 0xdb, 0x36, - 0x10, 0x0e, 0x65, 0x47, 0xb2, 0x56, 0xb2, 0x2d, 0xa3, 0x4e, 0xc2, 0xba, 0x8d, 0xab, 0x61, 0xa6, - 0xad, 0xc6, 0x93, 0x48, 0xae, 0x92, 0x53, 0x2f, 0x6d, 0x2c, 0x7b, 0x5a, 0x4f, 0x62, 0x57, 0x03, - 0xa5, 0xce, 0x4c, 0x2e, 0x19, 0x98, 0x84, 0x58, 0x8c, 0x48, 0x80, 0x05, 0x40, 0xbb, 0xca, 0x13, - 0xf4, 0xd0, 0x53, 0x5f, 0xa2, 0x2f, 0xd0, 0x9e, 0x7b, 0xca, 0x7b, 0x75, 0x08, 0x92, 0x26, 0xf5, - 0x13, 0x39, 0x87, 0x9e, 0x44, 0x7c, 0xfb, 0xed, 0x87, 0xdd, 0xc5, 0x62, 0x05, 0xf8, 0x22, 0x14, - 0xee, 0x5b, 0x37, 0x10, 0xb1, 0x47, 0x7c, 0xca, 0xf5, 0xdb, 0x49, 0x7c, 0x49, 0x25, 0xa7, 0x9a, - 0xaa, 0x6e, 0x24, 0x85, 0x16, 0xe8, 0xd3, 0x50, 0xb8, 0xdd, 0x82, 0xd0, 0x2d, 0x08, 0x7b, 0xfb, - 0xbe, 0x10, 0x7e, 0x40, 0x7b, 0x86, 0x78, 0x19, 0x8f, 0x7b, 0xd7, 0x92, 0x44, 0x11, 0x95, 0x99, - 0xeb, 0xde, 0x03, 0xa3, 0x2d, 0xc2, 0x50, 0xf0, 0xec, 0x27, 0x35, 0x38, 0x7f, 0x5a, 0xb0, 0xf3, - 0xe2, 0x46, 0x07, 0xd3, 0x5f, 0x63, 0xaa, 0x34, 0xfa, 0x01, 0x1a, 0x05, 0xa8, 0x6c, 0xab, 0xbd, - 0xd6, 0x69, 0xf4, 0xbf, 0xec, 0x7e, 0x70, 0xff, 0x6e, 0x49, 0xa2, 0xec, 0x89, 0x9e, 0xc1, 0xe6, - 0x4f, 0x11, 0x95, 0x44, 0x33, 0xc1, 0x5f, 0x4d, 0x23, 0x6a, 0x57, 0xda, 0x56, 0x67, 0xab, 0xbf, - 0x65, 0xa4, 0x6e, 0x2c, 0x78, 0x96, 0xe4, 0xfc, 0x65, 0x01, 0x2a, 0x07, 0xa5, 0x22, 0xc1, 0x15, - 0xfd, 0xff, 0xa2, 0xea, 0x43, 0x15, 0x53, 0x15, 0x07, 0xda, 0x84, 0xd3, 0xe8, 0xef, 0x75, 0xd3, - 0xf2, 0x75, 0xf3, 0xf2, 0x75, 0x8f, 0x84, 0x08, 0x2e, 0x48, 0x10, 0x53, 0x9c, 0x31, 0xd1, 0x2e, - 0xdc, 0x3d, 0x91, 0x52, 0x48, 0x7b, 0xad, 0x6d, 0x75, 0xea, 0x38, 0x5d, 0x38, 0x1d, 0xd8, 0x1d, - 0x69, 0x21, 0x89, 0x4f, 0x07, 0x82, 0x8f, 0x99, 0x1f, 0xa7, 0x59, 0xa0, 0x16, 0xac, 0xb9, 0x8a, - 0xd9, 0x96, 0xe1, 0x26, 0x9f, 0xce, 0x1f, 0x15, 0xd8, 0x3d, 0xa7, 0xfa, 0x5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0xe8, 0xf4, 0x98, 0x68, 0x92, 0x1e, 0xe0, 0xd1, 0xfa, 0xef, 0xff, 0xd8, - 0x16, 0xce, 0x41, 0xe7, 0x5f, 0x0b, 0x76, 0x07, 0x22, 0x8c, 0x62, 0xbd, 0xa4, 0x41, 0x64, 0x71, - 0xea, 0x92, 0xa1, 0x13, 0xa8, 0x47, 0xb9, 0x6e, 0xd6, 0x97, 0x5f, 0xaf, 0x48, 0xbc, 0x1c, 0x06, - 0x2e, 0x3c, 0xd1, 0x39, 0xd4, 0xf3, 0xba, 0x26, 0x69, 0x25, 0x57, 0xe4, 0xf0, 0x96, 0xfa, 0x2d, - 0x9c, 0x01, 0x2e, 0x24, 0x9c, 0x43, 0xd8, 0x1d, 0x64, 0xfd, 0x35, 0x93, 0x80, 0x0d, 0xb5, 0x2b, - 0x2a, 0x15, 0x13, 0x3c, 0x4b, 0x22, 0x5f, 0x3a, 0xef, 0x2b, 0xf0, 0x20, 0x73, 0x79, 0x3e, 0x3c, - 0x9d, 0xf5, 0x7a, 0x06, 0xf7, 0x66, 0x80, 0x13, 0xee, 0x45, 0x82, 0x71, 0x9d, 0x69, 0x2c, 0x37, - 0xa2, 0x63, 0x78, 0x78, 0xca, 0xc7, 0x92, 0x28, 0x2d, 0x63, 0x57, 0xc7, 0x92, 0x0e, 0xa5, 0xb8, - 0x62, 0x1e, 0x95, 0x17, 0x59, 0x04, 0xe9, 0x01, 0xaf, 0x26, 0xa1, 0x6f, 0xc1, 0x3e, 0x12, 0x42, - 0x2b, 0x2d, 0x49, 0x34, 0x2f, 0x90, 0xde, 0xa4, 0x0f, 0xda, 0xd1, 0xf7, 0xf0, 0xd9, 0xa0, 0x74, - 0x7d, 0xe6, 0xdd, 0xd3, 0x26, 0x59, 0x45, 0x41, 0x87, 0xf0, 0xc9, 0x40, 0x2c, 0x46, 0x9e, 0xde, - 0xb8, 0x65, 0x26, 0x67, 0x02, 0x3b, 0x89, 0x20, 0x61, 0x9c, 0x4a, 0x4c, 0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, 0xc4, 0x84, 0xa2, 0xc7, 0x1f, 0xf7, 0x68, 0x4a, - 0x5f, 0x83, 0x7b, 0x4f, 0x3e, 0x92, 0x9d, 0x3e, 0xd3, 0x9c, 0x3b, 0x47, 0xbd, 0x37, 0x4f, 0x7c, - 0xa6, 0x7f, 0x89, 0x2f, 0xbb, 0xae, 0x08, 0x7b, 0x21, 0x73, 0xa5, 0x50, 0x62, 0xac, 0x7b, 0xa1, - 0x70, 0x7b, 0x32, 0x72, 0x7b, 0x85, 0x54, 0xfa, 0x79, 0x59, 0x35, 0x0f, 0xaf, 0xa7, 0xff, 0x05, - 0x00, 0x00, 0xff, 0xff, 0x74, 0xae, 0xbd, 0xbf, 0x03, 0x0b, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// KubernetesAgentClient is the client API for KubernetesAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type KubernetesAgentClient interface { - Invoke(ctx context.Context, in *KubernetesRequest, opts ...grpc.CallOption) (*KubernetesResponse, error) -} - -type kubernetesAgentClient struct { - cc *grpc.ClientConn -} - -func NewKubernetesAgentClient(cc *grpc.ClientConn) KubernetesAgentClient { - return &kubernetesAgentClient{cc} -} - -func (c *kubernetesAgentClient) Invoke(ctx context.Context, in *KubernetesRequest, opts ...grpc.CallOption) (*KubernetesResponse, error) { - out := new(KubernetesResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.kubernetes.KubernetesAgent/Invoke", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// KubernetesAgentServer is the server API for KubernetesAgent service. -type KubernetesAgentServer interface { - Invoke(context.Context, *KubernetesRequest) (*KubernetesResponse, error) -} - -// UnimplementedKubernetesAgentServer can be embedded to have forward compatible implementations. -type UnimplementedKubernetesAgentServer struct { -} - -func (*UnimplementedKubernetesAgentServer) Invoke(ctx context.Context, req *KubernetesRequest) (*KubernetesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") -} - -func RegisterKubernetesAgentServer(s *grpc.Server, srv KubernetesAgentServer) { - s.RegisterService(&_KubernetesAgent_serviceDesc, srv) -} - -func _KubernetesAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(KubernetesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(KubernetesAgentServer).Invoke(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.kubernetes.KubernetesAgent/Invoke", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(KubernetesAgentServer).Invoke(ctx, req.(*KubernetesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _KubernetesAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.kubernetes.KubernetesAgent", - HandlerType: (*KubernetesAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Invoke", - Handler: _KubernetesAgent_Invoke_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_kubernetes.proto", -} diff --git a/rpc/cloudagent/cloud/moc_cloudagent_subscription.pb.go b/rpc/cloudagent/cloud/moc_cloudagent_subscription.pb.go deleted file mode 100644 index 9c7d06b5..00000000 --- a/rpc/cloudagent/cloud/moc_cloudagent_subscription.pb.go +++ /dev/null @@ -1,308 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_cloudagent_subscription.proto - -package cloud - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type SubscriptionRequest struct { - Subscriptions []*Subscription `protobuf:"bytes,1,rep,name=Subscriptions,proto3" json:"Subscriptions,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *SubscriptionRequest) Reset() { *m = SubscriptionRequest{} } -func (m *SubscriptionRequest) String() string { return proto.CompactTextString(m) } -func (*SubscriptionRequest) ProtoMessage() {} -func (*SubscriptionRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_c65b5bbaa8b83702, []int{0} -} - -func (m *SubscriptionRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_SubscriptionRequest.Unmarshal(m, b) -} -func (m *SubscriptionRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_SubscriptionRequest.Marshal(b, m, deterministic) -} -func (m *SubscriptionRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionRequest.Merge(m, src) -} -func (m *SubscriptionRequest) XXX_Size() int { - return xxx_messageInfo_SubscriptionRequest.Size(m) -} -func (m *SubscriptionRequest) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_SubscriptionRequest proto.InternalMessageInfo - -func (m *SubscriptionRequest) GetSubscriptions() []*Subscription { - if m != nil { - return m.Subscriptions - } - return nil -} - -func (m *SubscriptionRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type SubscriptionResponse struct { - Subscriptions []*Subscription `protobuf:"bytes,1,rep,name=Subscriptions,proto3" json:"Subscriptions,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *SubscriptionResponse) Reset() { *m = SubscriptionResponse{} } -func (m *SubscriptionResponse) String() string { return proto.CompactTextString(m) } -func (*SubscriptionResponse) ProtoMessage() {} -func (*SubscriptionResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_c65b5bbaa8b83702, []int{1} -} - -func (m *SubscriptionResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_SubscriptionResponse.Unmarshal(m, b) -} -func (m *SubscriptionResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_SubscriptionResponse.Marshal(b, m, deterministic) -} -func (m *SubscriptionResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionResponse.Merge(m, src) -} -func (m *SubscriptionResponse) XXX_Size() int { - return xxx_messageInfo_SubscriptionResponse.Size(m) -} -func (m *SubscriptionResponse) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_SubscriptionResponse proto.InternalMessageInfo - -func (m *SubscriptionResponse) GetSubscriptions() []*Subscription { - if m != nil { - return m.Subscriptions - } - return nil -} - -func (m *SubscriptionResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *SubscriptionResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type Subscription struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` - Status *common.Status `protobuf:"bytes,3,opt,name=status,proto3" json:"status,omitempty"` - Tags *common.Tags `protobuf:"bytes,4,opt,name=tags,proto3" json:"tags,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Subscription) Reset() { *m = Subscription{} } -func (m *Subscription) String() string { return proto.CompactTextString(m) } -func (*Subscription) ProtoMessage() {} -func (*Subscription) Descriptor() ([]byte, []int) { - return fileDescriptor_c65b5bbaa8b83702, []int{2} -} - -func (m *Subscription) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Subscription.Unmarshal(m, b) -} -func (m *Subscription) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Subscription.Marshal(b, m, deterministic) -} -func (m *Subscription) XXX_Merge(src proto.Message) { - xxx_messageInfo_Subscription.Merge(m, src) -} -func (m *Subscription) XXX_Size() int { - return xxx_messageInfo_Subscription.Size(m) -} -func (m *Subscription) XXX_DiscardUnknown() { - xxx_messageInfo_Subscription.DiscardUnknown(m) -} - -var xxx_messageInfo_Subscription proto.InternalMessageInfo - -func (m *Subscription) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *Subscription) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *Subscription) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func (m *Subscription) GetTags() *common.Tags { - if m != nil { - return m.Tags - } - return nil -} - -func init() { - proto.RegisterType((*SubscriptionRequest)(nil), "moc.cloudagent.subscription.SubscriptionRequest") - proto.RegisterType((*SubscriptionResponse)(nil), "moc.cloudagent.subscription.SubscriptionResponse") - proto.RegisterType((*Subscription)(nil), "moc.cloudagent.subscription.Subscription") -} - -func init() { proto.RegisterFile("moc_cloudagent_subscription.proto", fileDescriptor_c65b5bbaa8b83702) } - -var fileDescriptor_c65b5bbaa8b83702 = []byte{ - // 381 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 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2f, 0xb1, 0x26, 0x04, 0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// SubscriptionAgentClient is the client API for SubscriptionAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type SubscriptionAgentClient interface { - Invoke(ctx context.Context, in *SubscriptionRequest, opts ...grpc.CallOption) (*SubscriptionResponse, error) -} - -type subscriptionAgentClient struct { - cc *grpc.ClientConn -} - -func NewSubscriptionAgentClient(cc *grpc.ClientConn) SubscriptionAgentClient { - return &subscriptionAgentClient{cc} -} - -func (c *subscriptionAgentClient) Invoke(ctx context.Context, in *SubscriptionRequest, opts ...grpc.CallOption) (*SubscriptionResponse, error) { - out := new(SubscriptionResponse) - err := c.cc.Invoke(ctx, "/moc.cloudagent.subscription.SubscriptionAgent/Invoke", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// SubscriptionAgentServer is the server API for SubscriptionAgent service. -type SubscriptionAgentServer interface { - Invoke(context.Context, *SubscriptionRequest) (*SubscriptionResponse, error) -} - -// UnimplementedSubscriptionAgentServer can be embedded to have forward compatible implementations. -type UnimplementedSubscriptionAgentServer struct { -} - -func (*UnimplementedSubscriptionAgentServer) Invoke(ctx context.Context, req *SubscriptionRequest) (*SubscriptionResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Invoke not implemented") -} - -func RegisterSubscriptionAgentServer(s *grpc.Server, srv SubscriptionAgentServer) { - s.RegisterService(&_SubscriptionAgent_serviceDesc, srv) -} - -func _SubscriptionAgent_Invoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SubscriptionRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(SubscriptionAgentServer).Invoke(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.cloudagent.subscription.SubscriptionAgent/Invoke", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(SubscriptionAgentServer).Invoke(ctx, req.(*SubscriptionRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _SubscriptionAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.cloudagent.subscription.SubscriptionAgent", - HandlerType: (*SubscriptionAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Invoke", - Handler: _SubscriptionAgent_Invoke_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_cloudagent_subscription.proto", -} diff --git a/rpc/cloudagent/cloud/subscription/moc_cloudagent_subscription.proto b/rpc/cloudagent/cloud/subscription/moc_cloudagent_subscription.proto deleted file mode 100644 index 542147fa..00000000 --- a/rpc/cloudagent/cloud/subscription/moc_cloudagent_subscription.proto +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud"; -package moc.cloudagent.subscription; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - -message SubscriptionRequest { - repeated Subscription Subscriptions = 1; - Operation OperationType = 2; - // SubPostOperation PostOperationType = 3; -} - -message SubscriptionResponse { - repeated Subscription Subscriptions = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message Subscription { - string name = 1; - string id = 2; - Status status = 3; - Tags tags = 4; -} - -service SubscriptionAgent { - rpc Invoke(SubscriptionRequest) returns (SubscriptionResponse) {} -} - diff --git a/rpc/gen_proto.sh b/rpc/gen_proto.sh index 18d0e003..ffc37b51 100755 --- a/rpc/gen_proto.sh +++ b/rpc/gen_proto.sh @@ -85,17 +85,6 @@ protoc -I $Agent/$Module -I ./common $Agent/$Module/moc_baremetalhostagent.proto #### -Agent="ipamagent" -echo "Generating Protoc for $Agent" -Module="ipaddressmanager" -echo "Generating $Module protoc" -protoc -I $Agent/$Module -I ./common $Agent/$Module/moc_ipaddress_${Module}.proto --go_out=plugins=grpc:../bld/gen/ -ChildModule="ipaddress" -echo "Generating $Module/$ChildModule protoc" -protoc -I $Agent/$Module -I ./common $Agent/$Module/$ChildModule/moc_ipaddress_${ChildModule}.proto --go_out=plugins=grpc:../bld/gen/ - -#### - Agent="mochostagent" echo "Generating Protoc for $Agent" @@ -178,13 +167,7 @@ Module="cloud" echo "Generating $Agent/$Module protoc" protoc -I $Agent/$Module/group -I ./common $Agent/$Module/group/moc_cloudagent_group.proto --go_out=plugins=grpc:../bld/gen/ protoc -I $Agent/$Module/node -I ./common $Agent/$Module/node/moc_cloudagent_node.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/kubernetes -I ./common $Agent/$Module/kubernetes/moc_cloudagent_kubernetes.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/cluster -I $Agent/$Module/node -I ./common $Agent/$Module/cluster/moc_cloudagent_cluster.proto --go_out=plugins=grpc:../bld/gen/ protoc -I $Agent/$Module/location -I ./common $Agent/$Module/location/moc_cloudagent_location.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/subscription -I ./common $Agent/$Module/subscription/moc_cloudagent_subscription.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/controlplane -I ./common $Agent/$Module/controlplane/moc_cloudagent_controlplane.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/etcdcluster/etcdserver -I ./common $Agent/$Module/etcdcluster/etcdserver/moc_cloudagent_etcdserver.proto --go_out=plugins=grpc:../bld/gen/ -protoc -I $Agent/$Module/etcdcluster -I ./common -I $Agent/$Module/etcdcluster/etcdserver $Agent/$Module/etcdcluster/moc_cloudagent_etcdcluster.proto --go_out=plugins=grpc:../bld/gen/ protoc -I $Agent/$Module/zone -I ./common -I $Agent/$Module/zone $Agent/$Module/zone/moc_cloudagent_zone.proto --go_out=plugins=grpc:../bld/gen/ Module="security" diff --git a/rpc/ipamagent/ipaddressmanager/ipaddress/moc_ipaddress_ipaddress.proto b/rpc/ipamagent/ipaddressmanager/ipaddress/moc_ipaddress_ipaddress.proto deleted file mode 100644 index e821906c..00000000 --- a/rpc/ipamagent/ipaddressmanager/ipaddress/moc_ipaddress_ipaddress.proto +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/ipamagent"; -package moc.ipaddress; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - - -message IPAddressRequest { - repeated IPAddress IPAddresss = 1; - Operation OperationType = 2; -} - -message IPAddressResponse { - repeated IPAddress IPAddresss = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -enum IPAddressFamily { - IPV4 = 0; - IPV6 = 1; -} - -message IPAddress { - string name = 1; - string id = 2; - string address = 3; - string cidr = 4; - int32 prefixLength = 5; - Status status = 8; -} - - -service IPAddressAgent { - rpc Get(IPAddressRequest) returns (IPAddressResponse) {} - rpc Create(IPAddressRequest) returns (IPAddressResponse) {} - rpc Delete(IPAddressRequest) returns (IPAddressResponse) {} -} - diff --git a/rpc/ipamagent/ipaddressmanager/moc_ipaddress_ipaddressmanager.proto b/rpc/ipamagent/ipaddressmanager/moc_ipaddress_ipaddressmanager.proto deleted file mode 100644 index 773f0655..00000000 --- a/rpc/ipamagent/ipaddressmanager/moc_ipaddress_ipaddressmanager.proto +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the Apache v2.0 license. - -syntax = "proto3"; -option go_package = "github.com/microsoft/moc/rpc/ipamagent"; -package moc.ipaddressmanager; - -import "google/protobuf/wrappers.proto"; -import "moc_common_common.proto"; - - -message IPAddressManagerRequest { - repeated IPAddressManager IPAddressManagers = 1; - Operation OperationType = 2; -} - -message IPAddressManagerResponse { - repeated IPAddressManager IPAddressManagers = 1; - google.protobuf.BoolValue Result = 2; - string Error = 3; -} - -message IPAddressManager { - string name = 1; - string id = 2; - Status status = 8; -} - -service IPAddressManagerAgent { - rpc Get(IPAddressManagerRequest) returns (IPAddressManagerResponse) {} - rpc Create(IPAddressManagerRequest) returns (IPAddressManagerResponse) {} - rpc Delete(IPAddressManagerRequest) returns (IPAddressManagerResponse) {} -} - diff --git a/rpc/ipamagent/moc_ipaddress_ipaddress.pb.go b/rpc/ipamagent/moc_ipaddress_ipaddress.pb.go deleted file mode 100644 index b62c1d3f..00000000 --- a/rpc/ipamagent/moc_ipaddress_ipaddress.pb.go +++ /dev/null @@ -1,428 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: ipaddress/moc_ipaddress_ipaddress.proto - -package ipamagent - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type IPAddressFamily int32 - -const ( - IPAddressFamily_IPV4 IPAddressFamily = 0 - IPAddressFamily_IPV6 IPAddressFamily = 1 -) - -var IPAddressFamily_name = map[int32]string{ - 0: "IPV4", - 1: "IPV6", -} - -var IPAddressFamily_value = map[string]int32{ - "IPV4": 0, - "IPV6": 1, -} - -func (x IPAddressFamily) String() string { - return proto.EnumName(IPAddressFamily_name, int32(x)) -} - -func (IPAddressFamily) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_be2c955786c58534, []int{0} -} - -type IPAddressRequest struct { - IPAddresss []*IPAddress `protobuf:"bytes,1,rep,name=IPAddresss,proto3" json:"IPAddresss,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddressRequest) Reset() { *m = IPAddressRequest{} } -func (m *IPAddressRequest) String() string { return proto.CompactTextString(m) } -func (*IPAddressRequest) ProtoMessage() {} -func (*IPAddressRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_be2c955786c58534, []int{0} -} - -func (m *IPAddressRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddressRequest.Unmarshal(m, b) -} -func (m *IPAddressRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddressRequest.Marshal(b, m, deterministic) -} -func (m *IPAddressRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddressRequest.Merge(m, src) -} -func (m *IPAddressRequest) XXX_Size() int { - return xxx_messageInfo_IPAddressRequest.Size(m) -} -func (m *IPAddressRequest) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddressRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddressRequest proto.InternalMessageInfo - -func (m *IPAddressRequest) GetIPAddresss() []*IPAddress { - if m != nil { - return m.IPAddresss - } - return nil -} - -func (m *IPAddressRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type IPAddressResponse struct { - IPAddresss []*IPAddress `protobuf:"bytes,1,rep,name=IPAddresss,proto3" json:"IPAddresss,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddressResponse) Reset() { *m = IPAddressResponse{} } -func (m *IPAddressResponse) String() string { return proto.CompactTextString(m) } -func (*IPAddressResponse) ProtoMessage() {} -func (*IPAddressResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_be2c955786c58534, []int{1} -} - -func (m *IPAddressResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddressResponse.Unmarshal(m, b) -} -func (m *IPAddressResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddressResponse.Marshal(b, m, deterministic) -} -func (m *IPAddressResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddressResponse.Merge(m, src) -} -func (m *IPAddressResponse) XXX_Size() int { - return xxx_messageInfo_IPAddressResponse.Size(m) -} -func (m *IPAddressResponse) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddressResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddressResponse proto.InternalMessageInfo - -func (m *IPAddressResponse) GetIPAddresss() []*IPAddress { - if m != nil { - return m.IPAddresss - } - return nil -} - -func (m *IPAddressResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *IPAddressResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type IPAddress struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` - Address string `protobuf:"bytes,3,opt,name=address,proto3" json:"address,omitempty"` - Cidr string `protobuf:"bytes,4,opt,name=cidr,proto3" json:"cidr,omitempty"` - PrefixLength int32 `protobuf:"varint,5,opt,name=prefixLength,proto3" json:"prefixLength,omitempty"` - Status *common.Status `protobuf:"bytes,8,opt,name=status,proto3" json:"status,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddress) Reset() { *m = IPAddress{} } -func (m *IPAddress) String() string { return proto.CompactTextString(m) } -func (*IPAddress) ProtoMessage() {} -func (*IPAddress) Descriptor() ([]byte, []int) { - return fileDescriptor_be2c955786c58534, []int{2} -} - -func (m *IPAddress) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddress.Unmarshal(m, b) -} -func (m *IPAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddress.Marshal(b, m, deterministic) -} -func (m *IPAddress) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddress.Merge(m, src) -} -func (m *IPAddress) XXX_Size() int { - return xxx_messageInfo_IPAddress.Size(m) -} -func (m *IPAddress) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddress.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddress proto.InternalMessageInfo - -func (m *IPAddress) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *IPAddress) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *IPAddress) GetAddress() string { - if m != nil { - return m.Address - } - return "" -} - -func (m *IPAddress) GetCidr() string { - if m != nil { - return m.Cidr - } - return "" -} - -func (m *IPAddress) GetPrefixLength() int32 { - if m != nil { - return m.PrefixLength - } - return 0 -} - -func (m *IPAddress) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func init() { - proto.RegisterEnum("moc.ipaddress.IPAddressFamily", IPAddressFamily_name, IPAddressFamily_value) - proto.RegisterType((*IPAddressRequest)(nil), "moc.ipaddress.IPAddressRequest") - proto.RegisterType((*IPAddressResponse)(nil), "moc.ipaddress.IPAddressResponse") - proto.RegisterType((*IPAddress)(nil), "moc.ipaddress.IPAddress") -} - -func init() { - proto.RegisterFile("ipaddress/moc_ipaddress_ipaddress.proto", fileDescriptor_be2c955786c58534) -} - -var fileDescriptor_be2c955786c58534 = []byte{ - // 437 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x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fd, 0x08, 0xd3, 0x57, 0x06, 0xb9, 0xc3, 0x1b, 0xa3, 0x7b, - 0x8d, 0x15, 0xde, 0x10, 0xdd, 0x51, 0xf4, 0xf5, 0x49, 0x29, 0xdc, 0x59, 0xb3, 0x8e, 0x73, 0x25, - 0x13, 0x29, 0x72, 0xa3, 0xac, 0xda, 0xb8, 0xf6, 0x4f, 0x4b, 0x8c, 0xce, 0x13, 0xa1, 0xb9, 0xe4, - 0xad, 0x27, 0xeb, 0xa9, 0x3f, 0x94, 0xe7, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0xe1, 0x1e, 0x05, - 0x70, 0x8f, 0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// IPAddressAgentClient is the client API for IPAddressAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type IPAddressAgentClient interface { - Get(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) - Create(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) - Delete(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) -} - -type iPAddressAgentClient struct { - cc *grpc.ClientConn -} - -func NewIPAddressAgentClient(cc *grpc.ClientConn) IPAddressAgentClient { - return &iPAddressAgentClient{cc} -} - -func (c *iPAddressAgentClient) Get(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) { - out := new(IPAddressResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddress.IPAddressAgent/Get", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *iPAddressAgentClient) Create(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) { - out := new(IPAddressResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddress.IPAddressAgent/Create", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *iPAddressAgentClient) Delete(ctx context.Context, in *IPAddressRequest, opts ...grpc.CallOption) (*IPAddressResponse, error) { - out := new(IPAddressResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddress.IPAddressAgent/Delete", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// IPAddressAgentServer is the server API for IPAddressAgent service. -type IPAddressAgentServer interface { - Get(context.Context, *IPAddressRequest) (*IPAddressResponse, error) - Create(context.Context, *IPAddressRequest) (*IPAddressResponse, error) - Delete(context.Context, *IPAddressRequest) (*IPAddressResponse, error) -} - -// UnimplementedIPAddressAgentServer can be embedded to have forward compatible implementations. -type UnimplementedIPAddressAgentServer struct { -} - -func (*UnimplementedIPAddressAgentServer) Get(ctx context.Context, req *IPAddressRequest) (*IPAddressResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Get not implemented") -} -func (*UnimplementedIPAddressAgentServer) Create(ctx context.Context, req *IPAddressRequest) (*IPAddressResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Create not implemented") -} -func (*UnimplementedIPAddressAgentServer) Delete(ctx context.Context, req *IPAddressRequest) (*IPAddressResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Delete not implemented") -} - -func RegisterIPAddressAgentServer(s *grpc.Server, srv IPAddressAgentServer) { - s.RegisterService(&_IPAddressAgent_serviceDesc, srv) -} - -func _IPAddressAgent_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressAgentServer).Get(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddress.IPAddressAgent/Get", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressAgentServer).Get(ctx, req.(*IPAddressRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IPAddressAgent_Create_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressAgentServer).Create(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddress.IPAddressAgent/Create", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressAgentServer).Create(ctx, req.(*IPAddressRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IPAddressAgent_Delete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressAgentServer).Delete(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddress.IPAddressAgent/Delete", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressAgentServer).Delete(ctx, req.(*IPAddressRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _IPAddressAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.ipaddress.IPAddressAgent", - HandlerType: (*IPAddressAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Get", - Handler: _IPAddressAgent_Get_Handler, - }, - { - MethodName: "Create", - Handler: _IPAddressAgent_Create_Handler, - }, - { - MethodName: "Delete", - Handler: _IPAddressAgent_Delete_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "ipaddress/moc_ipaddress_ipaddress.proto", -} diff --git a/rpc/ipamagent/moc_ipaddress_ipaddressmanager.pb.go b/rpc/ipamagent/moc_ipaddress_ipaddressmanager.pb.go deleted file mode 100644 index 346104eb..00000000 --- a/rpc/ipamagent/moc_ipaddress_ipaddressmanager.pb.go +++ /dev/null @@ -1,374 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: moc_ipaddress_ipaddressmanager.proto - -package ipamagent - -import ( - context "context" - fmt "fmt" - proto "github.com/golang/protobuf/proto" - wrappers "github.com/golang/protobuf/ptypes/wrappers" - common "github.com/microsoft/moc/rpc/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -type IPAddressManagerRequest struct { - IPAddressManagers []*IPAddressManager `protobuf:"bytes,1,rep,name=IPAddressManagers,proto3" json:"IPAddressManagers,omitempty"` - OperationType common.Operation `protobuf:"varint,2,opt,name=OperationType,proto3,enum=moc.Operation" json:"OperationType,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddressManagerRequest) Reset() { *m = IPAddressManagerRequest{} } -func (m *IPAddressManagerRequest) String() string { return proto.CompactTextString(m) } -func (*IPAddressManagerRequest) ProtoMessage() {} -func (*IPAddressManagerRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_be34917742d325d7, []int{0} -} - -func (m *IPAddressManagerRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddressManagerRequest.Unmarshal(m, b) -} -func (m *IPAddressManagerRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddressManagerRequest.Marshal(b, m, deterministic) -} -func (m *IPAddressManagerRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddressManagerRequest.Merge(m, src) -} -func (m *IPAddressManagerRequest) XXX_Size() int { - return xxx_messageInfo_IPAddressManagerRequest.Size(m) -} -func (m *IPAddressManagerRequest) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddressManagerRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddressManagerRequest proto.InternalMessageInfo - -func (m *IPAddressManagerRequest) GetIPAddressManagers() []*IPAddressManager { - if m != nil { - return m.IPAddressManagers - } - return nil -} - -func (m *IPAddressManagerRequest) GetOperationType() common.Operation { - if m != nil { - return m.OperationType - } - return common.Operation_GET -} - -type IPAddressManagerResponse struct { - IPAddressManagers []*IPAddressManager `protobuf:"bytes,1,rep,name=IPAddressManagers,proto3" json:"IPAddressManagers,omitempty"` - Result *wrappers.BoolValue `protobuf:"bytes,2,opt,name=Result,proto3" json:"Result,omitempty"` - Error string `protobuf:"bytes,3,opt,name=Error,proto3" json:"Error,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddressManagerResponse) Reset() { *m = IPAddressManagerResponse{} } -func (m *IPAddressManagerResponse) String() string { return proto.CompactTextString(m) } -func (*IPAddressManagerResponse) ProtoMessage() {} -func (*IPAddressManagerResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_be34917742d325d7, []int{1} -} - -func (m *IPAddressManagerResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddressManagerResponse.Unmarshal(m, b) -} -func (m *IPAddressManagerResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddressManagerResponse.Marshal(b, m, deterministic) -} -func (m *IPAddressManagerResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddressManagerResponse.Merge(m, src) -} -func (m *IPAddressManagerResponse) XXX_Size() int { - return xxx_messageInfo_IPAddressManagerResponse.Size(m) -} -func (m *IPAddressManagerResponse) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddressManagerResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddressManagerResponse proto.InternalMessageInfo - -func (m *IPAddressManagerResponse) GetIPAddressManagers() []*IPAddressManager { - if m != nil { - return m.IPAddressManagers - } - return nil -} - -func (m *IPAddressManagerResponse) GetResult() *wrappers.BoolValue { - if m != nil { - return m.Result - } - return nil -} - -func (m *IPAddressManagerResponse) GetError() string { - if m != nil { - return m.Error - } - return "" -} - -type IPAddressManager struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` - Status *common.Status `protobuf:"bytes,8,opt,name=status,proto3" json:"status,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IPAddressManager) Reset() { *m = IPAddressManager{} } -func (m *IPAddressManager) String() string { return proto.CompactTextString(m) } -func (*IPAddressManager) ProtoMessage() {} -func (*IPAddressManager) Descriptor() ([]byte, []int) { - return fileDescriptor_be34917742d325d7, []int{2} -} - -func (m *IPAddressManager) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IPAddressManager.Unmarshal(m, b) -} -func (m *IPAddressManager) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IPAddressManager.Marshal(b, m, deterministic) -} -func (m *IPAddressManager) XXX_Merge(src proto.Message) { - xxx_messageInfo_IPAddressManager.Merge(m, src) -} -func (m *IPAddressManager) XXX_Size() int { - return xxx_messageInfo_IPAddressManager.Size(m) -} -func (m *IPAddressManager) XXX_DiscardUnknown() { - xxx_messageInfo_IPAddressManager.DiscardUnknown(m) -} - -var xxx_messageInfo_IPAddressManager proto.InternalMessageInfo - -func (m *IPAddressManager) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *IPAddressManager) GetId() string { - if m != nil { - return m.Id - } - return "" -} - -func (m *IPAddressManager) GetStatus() *common.Status { - if m != nil { - return m.Status - } - return nil -} - -func init() { - proto.RegisterType((*IPAddressManagerRequest)(nil), "moc.ipaddressmanager.IPAddressManagerRequest") - proto.RegisterType((*IPAddressManagerResponse)(nil), "moc.ipaddressmanager.IPAddressManagerResponse") - proto.RegisterType((*IPAddressManager)(nil), "moc.ipaddressmanager.IPAddressManager") -} - -func init() { - proto.RegisterFile("moc_ipaddress_ipaddressmanager.proto", fileDescriptor_be34917742d325d7) -} - -var fileDescriptor_be34917742d325d7 = []byte{ - // 381 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x92, 0x41, 0x8e, 0xd3, 0x30, - 0x14, 0x86, 0x49, 0x0a, 0x11, 0x75, 0x45, 0x05, 0x56, 0x51, 0xa3, 0x2c, 0x50, 0x15, 0x50, 0x95, - 0x0d, 0x8e, 0x14, 0xb8, 0x40, 0x0b, 0x08, 0xb1, 0x40, 0xa0, 0x50, 0xb1, 0x80, 0x05, 0x72, 0x93, - 0xd7, 0x60, 0x29, 0xce, 0x33, 0xb6, 0x23, 0xc4, 0x81, 0xb8, 0x04, 0xf7, 0xe0, 0x3e, 0xa3, 0xda, - 0x9d, 0x19, 0x4d, 0x3a, 0x8b, 0x6e, 0xa6, 0xab, 0xbc, 0xe4, 0xff, 0xf3, 0xbd, 0x3f, 0x7f, 0x4c, - 0x5e, 0x48, 0xac, 0x7e, 0x08, 0xc5, 0xeb, 0x5a, 0x83, 0x31, 0xd7, 0x93, 0xe4, 0x1d, 0x6f, 0x40, - 0x33, 0xa5, 0xd1, 0x22, 0x9d, 0x49, 0xac, 0xd8, 0x50, 0x4b, 0x9e, 0x35, 0x88, 0x4d, 0x0b, 0xb9, - 0xf3, 0x6c, 0xfb, 0x5d, 0xfe, 0x5b, 0x73, 0xa5, 0x40, 0x1b, 0xff, 0x56, 0x32, 0xdf, 0xb3, 0x2b, - 0x94, 0x12, 0xbb, 0xc3, 0xc5, 0x0b, 0xe9, 0xdf, 0x80, 0xcc, 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8f, 0x0a, - 0x12, 0xbd, 0xd1, 0xc0, 0x2d, 0x9c, 0x65, 0xd5, 0x5b, 0x68, 0xe1, 0x0c, 0xab, 0xd6, 0xd9, 0xb7, - 0x65, 0x23, 0xec, 0xcf, 0x7e, 0xcb, 0x2a, 0x94, 0xb9, 0x14, 0x95, 0x46, 0x83, 0x3b, 0x9b, 0x4b, - 0xac, 0x72, 0xad, 0xaa, 0x5c, 0x28, 0x2e, 0xf9, 0xbe, 0xe7, 0x6d, 0xe4, 0x0e, 0xc4, 0xab, 0x8b, - 0x00, 0x00, 0x00, 0xff, 0xff, 0x97, 0x9f, 0xd3, 0xdd, 0xc1, 0x03, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// IPAddressManagerAgentClient is the client API for IPAddressManagerAgent service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type IPAddressManagerAgentClient interface { - Get(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) - Create(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) - Delete(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) -} - -type iPAddressManagerAgentClient struct { - cc *grpc.ClientConn -} - -func NewIPAddressManagerAgentClient(cc *grpc.ClientConn) IPAddressManagerAgentClient { - return &iPAddressManagerAgentClient{cc} -} - -func (c *iPAddressManagerAgentClient) Get(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) { - out := new(IPAddressManagerResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddressmanager.IPAddressManagerAgent/Get", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *iPAddressManagerAgentClient) Create(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) { - out := new(IPAddressManagerResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddressmanager.IPAddressManagerAgent/Create", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *iPAddressManagerAgentClient) Delete(ctx context.Context, in *IPAddressManagerRequest, opts ...grpc.CallOption) (*IPAddressManagerResponse, error) { - out := new(IPAddressManagerResponse) - err := c.cc.Invoke(ctx, "/moc.ipaddressmanager.IPAddressManagerAgent/Delete", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// IPAddressManagerAgentServer is the server API for IPAddressManagerAgent service. -type IPAddressManagerAgentServer interface { - Get(context.Context, *IPAddressManagerRequest) (*IPAddressManagerResponse, error) - Create(context.Context, *IPAddressManagerRequest) (*IPAddressManagerResponse, error) - Delete(context.Context, *IPAddressManagerRequest) (*IPAddressManagerResponse, error) -} - -// UnimplementedIPAddressManagerAgentServer can be embedded to have forward compatible implementations. -type UnimplementedIPAddressManagerAgentServer struct { -} - -func (*UnimplementedIPAddressManagerAgentServer) Get(ctx context.Context, req *IPAddressManagerRequest) (*IPAddressManagerResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Get not implemented") -} -func (*UnimplementedIPAddressManagerAgentServer) Create(ctx context.Context, req *IPAddressManagerRequest) (*IPAddressManagerResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Create not implemented") -} -func (*UnimplementedIPAddressManagerAgentServer) Delete(ctx context.Context, req *IPAddressManagerRequest) (*IPAddressManagerResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Delete not implemented") -} - -func RegisterIPAddressManagerAgentServer(s *grpc.Server, srv IPAddressManagerAgentServer) { - s.RegisterService(&_IPAddressManagerAgent_serviceDesc, srv) -} - -func _IPAddressManagerAgent_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressManagerRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressManagerAgentServer).Get(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddressmanager.IPAddressManagerAgent/Get", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressManagerAgentServer).Get(ctx, req.(*IPAddressManagerRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IPAddressManagerAgent_Create_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressManagerRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressManagerAgentServer).Create(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddressmanager.IPAddressManagerAgent/Create", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressManagerAgentServer).Create(ctx, req.(*IPAddressManagerRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IPAddressManagerAgent_Delete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(IPAddressManagerRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IPAddressManagerAgentServer).Delete(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/moc.ipaddressmanager.IPAddressManagerAgent/Delete", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IPAddressManagerAgentServer).Delete(ctx, req.(*IPAddressManagerRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _IPAddressManagerAgent_serviceDesc = grpc.ServiceDesc{ - ServiceName: "moc.ipaddressmanager.IPAddressManagerAgent", - HandlerType: (*IPAddressManagerAgentServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Get", - Handler: _IPAddressManagerAgent_Get_Handler, - }, - { - MethodName: "Create", - Handler: _IPAddressManagerAgent_Create_Handler, - }, - { - MethodName: "Delete", - Handler: _IPAddressManagerAgent_Delete_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "moc_ipaddress_ipaddressmanager.proto", -}