namespace

package
v0.0.0-...-b63aa1a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 18, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterService

func RegisterService(s giraffe_micro.Server, srv Service)

Types

type Client

type Client interface {
	Create(ctx context.Context, in *CreateRequest) (*CreateResponse, error)
	DeleteNamespace(ctx context.Context, in *DeleteNamespaceRequest) (*types.Empty, error)
	Get(ctx context.Context, in *GetRequest) (*GetResponse, error)
	List(ctx context.Context, in *ListRequest) (*ListResponse, error)
	Update(ctx context.Context, in *UpdateRequest) (*UpdateResponse, error)
}

Client is the client API for namespace service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewClient

func NewClient(c giraffe_micro.Client) Client

type CreateRequest

type CreateRequest struct {
	//
	//k8s 集群 id
	ClusterId string `protobuf:"bytes,1,opt,name=clusterId,proto3" json:"clusterId" form:"clusterId"`
	//
	//命名空间
	Namespace *container.Namespace `protobuf:"bytes,2,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"count/deployments.apps": "100",   #  无状态工作负载
	//"count/statefulsets.apps": "100",  #  有状态工作负载
	//"count/daemonsets.apps": "100",    #  守护进程
	//"count/jobs.batch": "100",     # 任务
	//"count/cronjobs.batch": "100", # 定时任务
	//"count/pods": "500",      # Pod
	//"count/services": "100",  # 服务
	//"count/ingresses.extensions": "100", # 应用路由
	//"persistentvolumeclaims": "100", # 存储卷
	//"count/secrets": "100",    # 密钥
	//"count/configmaps": "100", # 配置
	//"limits.cpu": "10",        # CPU 限额
	//"limits.memory": "20Gi"    # 内存限额
	//"requests.cpu": "1",       # CPU 预留
	//"requests.memory": "100Mi" # 内存预留
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,3,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,4,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

Create请求

func (*CreateRequest) Descriptor

func (*CreateRequest) Descriptor() ([]byte, []int)

func (*CreateRequest) GetClusterId

func (m *CreateRequest) GetClusterId() string

func (*CreateRequest) GetContainerDefaultLimit

func (m *CreateRequest) GetContainerDefaultLimit() *container.ResourceRequirements

func (*CreateRequest) GetNamespace

func (m *CreateRequest) GetNamespace() *container.Namespace

func (*CreateRequest) GetNamespaceQuota

func (m *CreateRequest) GetNamespaceQuota() *types.Struct

func (*CreateRequest) ProtoMessage

func (*CreateRequest) ProtoMessage()

func (*CreateRequest) Reset

func (m *CreateRequest) Reset()

func (*CreateRequest) String

func (m *CreateRequest) String() string

func (*CreateRequest) Validate

func (this *CreateRequest) Validate() error

func (*CreateRequest) XXX_DiscardUnknown

func (m *CreateRequest) XXX_DiscardUnknown()

func (*CreateRequest) XXX_Marshal

func (m *CreateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CreateRequest) XXX_Merge

func (m *CreateRequest) XXX_Merge(src proto.Message)

func (*CreateRequest) XXX_Size

func (m *CreateRequest) XXX_Size() int

func (*CreateRequest) XXX_Unmarshal

func (m *CreateRequest) XXX_Unmarshal(b []byte) error

type CreateResponse

type CreateResponse struct {
	//
	//命名空间
	Namespace *container.Namespace `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"limits.cpu": "2",
	//"limits.memory": "1Gi"
	//"configmaps": 50,
	//"persistentvolumeclaims": 50,
	//"pods": 50,
	//"replicationcontrollers": 50,
	//"resourcequotas": 50,
	//"secrets": 50,
	//"services": 50,
	//"service.loadbalancers": 50,
	//"service.nodeports": 50
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,2,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,3,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

Create返回

func (*CreateResponse) Descriptor

func (*CreateResponse) Descriptor() ([]byte, []int)

func (*CreateResponse) GetContainerDefaultLimit

func (m *CreateResponse) GetContainerDefaultLimit() *container.ResourceRequirements

func (*CreateResponse) GetNamespace

func (m *CreateResponse) GetNamespace() *container.Namespace

func (*CreateResponse) GetNamespaceQuota

func (m *CreateResponse) GetNamespaceQuota() *types.Struct

func (*CreateResponse) ProtoMessage

func (*CreateResponse) ProtoMessage()

func (*CreateResponse) Reset

func (m *CreateResponse) Reset()

func (*CreateResponse) String

func (m *CreateResponse) String() string

func (*CreateResponse) Validate

func (this *CreateResponse) Validate() error

func (*CreateResponse) XXX_DiscardUnknown

func (m *CreateResponse) XXX_DiscardUnknown()

func (*CreateResponse) XXX_Marshal

func (m *CreateResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CreateResponse) XXX_Merge

func (m *CreateResponse) XXX_Merge(src proto.Message)

func (*CreateResponse) XXX_Size

func (m *CreateResponse) XXX_Size() int

func (*CreateResponse) XXX_Unmarshal

func (m *CreateResponse) XXX_Unmarshal(b []byte) error

type CreateResponseWrapper

type CreateResponseWrapper struct {
	//
	//返回码
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code" form:"code"`
	//
	//返回码解释
	CodeExplain string `protobuf:"bytes,2,opt,name=codeExplain,proto3" json:"codeExplain" form:"codeExplain"`
	//
	//错误详情
	Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error" form:"error"`
	//
	//返回数据
	Data                 *CreateResponse `protobuf:"bytes,4,opt,name=data,proto3" json:"data" form:"data"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

CreateApi返回

func (*CreateResponseWrapper) Descriptor

func (*CreateResponseWrapper) Descriptor() ([]byte, []int)

func (*CreateResponseWrapper) GetCode

func (m *CreateResponseWrapper) GetCode() int32

func (*CreateResponseWrapper) GetCodeExplain

func (m *CreateResponseWrapper) GetCodeExplain() string

func (*CreateResponseWrapper) GetData

func (m *CreateResponseWrapper) GetData() *CreateResponse

func (*CreateResponseWrapper) GetError

func (m *CreateResponseWrapper) GetError() string

func (*CreateResponseWrapper) ProtoMessage

func (*CreateResponseWrapper) ProtoMessage()

func (*CreateResponseWrapper) Reset

func (m *CreateResponseWrapper) Reset()

func (*CreateResponseWrapper) String

func (m *CreateResponseWrapper) String() string

func (*CreateResponseWrapper) Validate

func (this *CreateResponseWrapper) Validate() error

func (*CreateResponseWrapper) XXX_DiscardUnknown

func (m *CreateResponseWrapper) XXX_DiscardUnknown()

func (*CreateResponseWrapper) XXX_Marshal

func (m *CreateResponseWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CreateResponseWrapper) XXX_Merge

func (m *CreateResponseWrapper) XXX_Merge(src proto.Message)

func (*CreateResponseWrapper) XXX_Size

func (m *CreateResponseWrapper) XXX_Size() int

func (*CreateResponseWrapper) XXX_Unmarshal

func (m *CreateResponseWrapper) XXX_Unmarshal(b []byte) error

type DeleteNamespaceRequest

type DeleteNamespaceRequest struct {
	//
	//要删除的实例 id
	InstanceId           string   `protobuf:"bytes,1,opt,name=instanceId,proto3" json:"instanceId" form:"instanceId"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

DeleteNamespace请求

func (*DeleteNamespaceRequest) Descriptor

func (*DeleteNamespaceRequest) Descriptor() ([]byte, []int)

func (*DeleteNamespaceRequest) GetInstanceId

func (m *DeleteNamespaceRequest) GetInstanceId() string

func (*DeleteNamespaceRequest) ProtoMessage

func (*DeleteNamespaceRequest) ProtoMessage()

func (*DeleteNamespaceRequest) Reset

func (m *DeleteNamespaceRequest) Reset()

func (*DeleteNamespaceRequest) String

func (m *DeleteNamespaceRequest) String() string

func (*DeleteNamespaceRequest) Validate

func (this *DeleteNamespaceRequest) Validate() error

func (*DeleteNamespaceRequest) XXX_DiscardUnknown

func (m *DeleteNamespaceRequest) XXX_DiscardUnknown()

func (*DeleteNamespaceRequest) XXX_Marshal

func (m *DeleteNamespaceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DeleteNamespaceRequest) XXX_Merge

func (m *DeleteNamespaceRequest) XXX_Merge(src proto.Message)

func (*DeleteNamespaceRequest) XXX_Size

func (m *DeleteNamespaceRequest) XXX_Size() int

func (*DeleteNamespaceRequest) XXX_Unmarshal

func (m *DeleteNamespaceRequest) XXX_Unmarshal(b []byte) error

type DeleteNamespaceResponseWrapper

type DeleteNamespaceResponseWrapper struct {
	//
	//返回码
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code" form:"code"`
	//
	//返回码解释
	CodeExplain string `protobuf:"bytes,2,opt,name=codeExplain,proto3" json:"codeExplain" form:"codeExplain"`
	//
	//错误详情
	Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error" form:"error"`
	//
	//返回数据
	Data                 *types.Empty `protobuf:"bytes,4,opt,name=data,proto3" json:"data" form:"data"`
	XXX_NoUnkeyedLiteral struct{}     `json:"-"`
	XXX_unrecognized     []byte       `json:"-"`
	XXX_sizecache        int32        `json:"-"`
}

DeleteNamespaceApi返回

func (*DeleteNamespaceResponseWrapper) Descriptor

func (*DeleteNamespaceResponseWrapper) Descriptor() ([]byte, []int)

func (*DeleteNamespaceResponseWrapper) GetCode

func (*DeleteNamespaceResponseWrapper) GetCodeExplain

func (m *DeleteNamespaceResponseWrapper) GetCodeExplain() string

func (*DeleteNamespaceResponseWrapper) GetData

func (*DeleteNamespaceResponseWrapper) GetError

func (m *DeleteNamespaceResponseWrapper) GetError() string

func (*DeleteNamespaceResponseWrapper) ProtoMessage

func (*DeleteNamespaceResponseWrapper) ProtoMessage()

func (*DeleteNamespaceResponseWrapper) Reset

func (m *DeleteNamespaceResponseWrapper) Reset()

func (*DeleteNamespaceResponseWrapper) String

func (*DeleteNamespaceResponseWrapper) Validate

func (this *DeleteNamespaceResponseWrapper) Validate() error

func (*DeleteNamespaceResponseWrapper) XXX_DiscardUnknown

func (m *DeleteNamespaceResponseWrapper) XXX_DiscardUnknown()

func (*DeleteNamespaceResponseWrapper) XXX_Marshal

func (m *DeleteNamespaceResponseWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DeleteNamespaceResponseWrapper) XXX_Merge

func (m *DeleteNamespaceResponseWrapper) XXX_Merge(src proto.Message)

func (*DeleteNamespaceResponseWrapper) XXX_Size

func (m *DeleteNamespaceResponseWrapper) XXX_Size() int

func (*DeleteNamespaceResponseWrapper) XXX_Unmarshal

func (m *DeleteNamespaceResponseWrapper) XXX_Unmarshal(b []byte) error

type GetRequest

type GetRequest struct {
	//
	//获取指定的 namespace id
	InstanceId           string   `protobuf:"bytes,1,opt,name=instanceId,proto3" json:"instanceId" form:"instanceId"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Get请求

func (*GetRequest) Descriptor

func (*GetRequest) Descriptor() ([]byte, []int)

func (*GetRequest) GetInstanceId

func (m *GetRequest) GetInstanceId() string

func (*GetRequest) ProtoMessage

func (*GetRequest) ProtoMessage()

func (*GetRequest) Reset

func (m *GetRequest) Reset()

func (*GetRequest) String

func (m *GetRequest) String() string

func (*GetRequest) Validate

func (this *GetRequest) Validate() error

func (*GetRequest) XXX_DiscardUnknown

func (m *GetRequest) XXX_DiscardUnknown()

func (*GetRequest) XXX_Marshal

func (m *GetRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GetRequest) XXX_Merge

func (m *GetRequest) XXX_Merge(src proto.Message)

func (*GetRequest) XXX_Size

func (m *GetRequest) XXX_Size() int

func (*GetRequest) XXX_Unmarshal

func (m *GetRequest) XXX_Unmarshal(b []byte) error

type GetResponse

type GetResponse struct {
	//
	//namespace 信息
	Namespace *container.Namespace `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"count/deployments.apps": "100",   #  无状态工作负载
	//"count/statefulsets.apps": "100",  #  有状态工作负载
	//"count/daemonsets.apps": "100",    #  守护进程
	//"count/jobs.batch": "100",     # 任务
	//"count/cronjobs.batch": "100", # 定时任务
	//"count/pods": "500",      # Pod
	//"count/services": "100",  # 服务
	//"count/ingresses.extensions": "100", # 应用路由
	//"persistentvolumeclaims": "100", # 存储卷
	//"count/secrets": "100",    # 密钥
	//"count/configmaps": "100", # 配置
	//"limits.cpu": "10",        # CPU 限额
	//"limits.memory": "20Gi"    # 内存限额
	//"requests.cpu": "1",       # CPU 预留
	//"requests.memory": "100Mi" # 内存预留
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,2,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,3,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

Get返回

func (*GetResponse) Descriptor

func (*GetResponse) Descriptor() ([]byte, []int)

func (*GetResponse) GetContainerDefaultLimit

func (m *GetResponse) GetContainerDefaultLimit() *container.ResourceRequirements

func (*GetResponse) GetNamespace

func (m *GetResponse) GetNamespace() *container.Namespace

func (*GetResponse) GetNamespaceQuota

func (m *GetResponse) GetNamespaceQuota() *types.Struct

func (*GetResponse) ProtoMessage

func (*GetResponse) ProtoMessage()

func (*GetResponse) Reset

func (m *GetResponse) Reset()

func (*GetResponse) String

func (m *GetResponse) String() string

func (*GetResponse) Validate

func (this *GetResponse) Validate() error

func (*GetResponse) XXX_DiscardUnknown

func (m *GetResponse) XXX_DiscardUnknown()

func (*GetResponse) XXX_Marshal

func (m *GetResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GetResponse) XXX_Merge

func (m *GetResponse) XXX_Merge(src proto.Message)

func (*GetResponse) XXX_Size

func (m *GetResponse) XXX_Size() int

func (*GetResponse) XXX_Unmarshal

func (m *GetResponse) XXX_Unmarshal(b []byte) error

type GetResponseWrapper

type GetResponseWrapper struct {
	//
	//返回码
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code" form:"code"`
	//
	//返回码解释
	CodeExplain string `protobuf:"bytes,2,opt,name=codeExplain,proto3" json:"codeExplain" form:"codeExplain"`
	//
	//错误详情
	Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error" form:"error"`
	//
	//返回数据
	Data                 *GetResponse `protobuf:"bytes,4,opt,name=data,proto3" json:"data" form:"data"`
	XXX_NoUnkeyedLiteral struct{}     `json:"-"`
	XXX_unrecognized     []byte       `json:"-"`
	XXX_sizecache        int32        `json:"-"`
}

GetApi返回

func (*GetResponseWrapper) Descriptor

func (*GetResponseWrapper) Descriptor() ([]byte, []int)

func (*GetResponseWrapper) GetCode

func (m *GetResponseWrapper) GetCode() int32

func (*GetResponseWrapper) GetCodeExplain

func (m *GetResponseWrapper) GetCodeExplain() string

func (*GetResponseWrapper) GetData

func (m *GetResponseWrapper) GetData() *GetResponse

func (*GetResponseWrapper) GetError

func (m *GetResponseWrapper) GetError() string

func (*GetResponseWrapper) ProtoMessage

func (*GetResponseWrapper) ProtoMessage()

func (*GetResponseWrapper) Reset

func (m *GetResponseWrapper) Reset()

func (*GetResponseWrapper) String

func (m *GetResponseWrapper) String() string

func (*GetResponseWrapper) Validate

func (this *GetResponseWrapper) Validate() error

func (*GetResponseWrapper) XXX_DiscardUnknown

func (m *GetResponseWrapper) XXX_DiscardUnknown()

func (*GetResponseWrapper) XXX_Marshal

func (m *GetResponseWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GetResponseWrapper) XXX_Merge

func (m *GetResponseWrapper) XXX_Merge(src proto.Message)

func (*GetResponseWrapper) XXX_Size

func (m *GetResponseWrapper) XXX_Size() int

func (*GetResponseWrapper) XXX_Unmarshal

func (m *GetResponseWrapper) XXX_Unmarshal(b []byte) error

type ListRequest

type ListRequest struct {
	//
	//k8s 集群 id
	ClusterId            string   `protobuf:"bytes,1,opt,name=clusterId,proto3" json:"clusterId" form:"clusterId"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

List请求

func (*ListRequest) Descriptor

func (*ListRequest) Descriptor() ([]byte, []int)

func (*ListRequest) GetClusterId

func (m *ListRequest) GetClusterId() string

func (*ListRequest) ProtoMessage

func (*ListRequest) ProtoMessage()

func (*ListRequest) Reset

func (m *ListRequest) Reset()

func (*ListRequest) String

func (m *ListRequest) String() string

func (*ListRequest) Validate

func (this *ListRequest) Validate() error

func (*ListRequest) XXX_DiscardUnknown

func (m *ListRequest) XXX_DiscardUnknown()

func (*ListRequest) XXX_Marshal

func (m *ListRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListRequest) XXX_Merge

func (m *ListRequest) XXX_Merge(src proto.Message)

func (*ListRequest) XXX_Size

func (m *ListRequest) XXX_Size() int

func (*ListRequest) XXX_Unmarshal

func (m *ListRequest) XXX_Unmarshal(b []byte) error

type ListResponse

type ListResponse struct {
	//
	//页数
	Page int32 `protobuf:"varint,1,opt,name=page,proto3" json:"page" form:"page"`
	//
	//页大小
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size" form:"page_size"`
	//
	//总数
	Total int32 `protobuf:"varint,3,opt,name=total,proto3" json:"total" form:"total"`
	//
	//数据列表
	List                 []*ListResponse_List `protobuf:"bytes,4,rep,name=list,proto3" json:"list" form:"list"`
	XXX_NoUnkeyedLiteral struct{}             `json:"-"`
	XXX_unrecognized     []byte               `json:"-"`
	XXX_sizecache        int32                `json:"-"`
}

List返回

func (*ListResponse) Descriptor

func (*ListResponse) Descriptor() ([]byte, []int)

func (*ListResponse) GetList

func (m *ListResponse) GetList() []*ListResponse_List

func (*ListResponse) GetPage

func (m *ListResponse) GetPage() int32

func (*ListResponse) GetPageSize

func (m *ListResponse) GetPageSize() int32

func (*ListResponse) GetTotal

func (m *ListResponse) GetTotal() int32

func (*ListResponse) ProtoMessage

func (*ListResponse) ProtoMessage()

func (*ListResponse) Reset

func (m *ListResponse) Reset()

func (*ListResponse) String

func (m *ListResponse) String() string

func (*ListResponse) Validate

func (this *ListResponse) Validate() error

func (*ListResponse) XXX_DiscardUnknown

func (m *ListResponse) XXX_DiscardUnknown()

func (*ListResponse) XXX_Marshal

func (m *ListResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListResponse) XXX_Merge

func (m *ListResponse) XXX_Merge(src proto.Message)

func (*ListResponse) XXX_Size

func (m *ListResponse) XXX_Size() int

func (*ListResponse) XXX_Unmarshal

func (m *ListResponse) XXX_Unmarshal(b []byte) error

type ListResponseWrapper

type ListResponseWrapper struct {
	//
	//返回码
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code" form:"code"`
	//
	//返回码解释
	CodeExplain string `protobuf:"bytes,2,opt,name=codeExplain,proto3" json:"codeExplain" form:"codeExplain"`
	//
	//错误详情
	Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error" form:"error"`
	//
	//返回数据
	Data                 *ListResponse `protobuf:"bytes,4,opt,name=data,proto3" json:"data" form:"data"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

ListApi返回

func (*ListResponseWrapper) Descriptor

func (*ListResponseWrapper) Descriptor() ([]byte, []int)

func (*ListResponseWrapper) GetCode

func (m *ListResponseWrapper) GetCode() int32

func (*ListResponseWrapper) GetCodeExplain

func (m *ListResponseWrapper) GetCodeExplain() string

func (*ListResponseWrapper) GetData

func (m *ListResponseWrapper) GetData() *ListResponse

func (*ListResponseWrapper) GetError

func (m *ListResponseWrapper) GetError() string

func (*ListResponseWrapper) ProtoMessage

func (*ListResponseWrapper) ProtoMessage()

func (*ListResponseWrapper) Reset

func (m *ListResponseWrapper) Reset()

func (*ListResponseWrapper) String

func (m *ListResponseWrapper) String() string

func (*ListResponseWrapper) Validate

func (this *ListResponseWrapper) Validate() error

func (*ListResponseWrapper) XXX_DiscardUnknown

func (m *ListResponseWrapper) XXX_DiscardUnknown()

func (*ListResponseWrapper) XXX_Marshal

func (m *ListResponseWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListResponseWrapper) XXX_Merge

func (m *ListResponseWrapper) XXX_Merge(src proto.Message)

func (*ListResponseWrapper) XXX_Size

func (m *ListResponseWrapper) XXX_Size() int

func (*ListResponseWrapper) XXX_Unmarshal

func (m *ListResponseWrapper) XXX_Unmarshal(b []byte) error

type ListResponse_List

type ListResponse_List struct {
	//
	//namespace 信息
	Namespace *container.Namespace `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"count/deployments.apps": "100",   #  无状态工作负载
	//"count/statefulsets.apps": "100",  #  有状态工作负载
	//"count/daemonsets.apps": "100",    #  守护进程
	//"count/jobs.batch": "100",     # 任务
	//"count/cronjobs.batch": "100", # 定时任务
	//"count/pods": "500",      # Pod
	//"count/services": "100",  # 服务
	//"count/ingresses.extensions": "100", # 应用路由
	//"persistentvolumeclaims": "100", # 存储卷
	//"count/secrets": "100",    # 密钥
	//"count/configmaps": "100", # 配置
	//"limits.cpu": "10",        # CPU 限额
	//"limits.memory": "20Gi"    # 内存限额
	//"requests.cpu": "1",       # CPU 预留
	//"requests.memory": "100Mi" # 内存预留
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,2,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,3,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

func (*ListResponse_List) Descriptor

func (*ListResponse_List) Descriptor() ([]byte, []int)

func (*ListResponse_List) GetContainerDefaultLimit

func (m *ListResponse_List) GetContainerDefaultLimit() *container.ResourceRequirements

func (*ListResponse_List) GetNamespace

func (m *ListResponse_List) GetNamespace() *container.Namespace

func (*ListResponse_List) GetNamespaceQuota

func (m *ListResponse_List) GetNamespaceQuota() *types.Struct

func (*ListResponse_List) ProtoMessage

func (*ListResponse_List) ProtoMessage()

func (*ListResponse_List) Reset

func (m *ListResponse_List) Reset()

func (*ListResponse_List) String

func (m *ListResponse_List) String() string

func (*ListResponse_List) Validate

func (this *ListResponse_List) Validate() error

func (*ListResponse_List) XXX_DiscardUnknown

func (m *ListResponse_List) XXX_DiscardUnknown()

func (*ListResponse_List) XXX_Marshal

func (m *ListResponse_List) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ListResponse_List) XXX_Merge

func (m *ListResponse_List) XXX_Merge(src proto.Message)

func (*ListResponse_List) XXX_Size

func (m *ListResponse_List) XXX_Size() int

func (*ListResponse_List) XXX_Unmarshal

func (m *ListResponse_List) XXX_Unmarshal(b []byte) error

type Service

Service is the server API for namespace service.

type UpdateRequest

type UpdateRequest struct {
	//
	//namespace id
	InstanceId string `protobuf:"bytes,1,opt,name=instanceId,proto3" json:"instanceId" form:"instanceId"`
	//
	//命名空间
	Namespace *container.Namespace `protobuf:"bytes,2,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"count/deployments.apps": "100",   #  无状态工作负载
	//"count/statefulsets.apps": "100",  #  有状态工作负载
	//"count/daemonsets.apps": "100",    #  守护进程
	//"count/jobs.batch": "100",     # 任务
	//"count/cronjobs.batch": "100", # 定时任务
	//"count/pods": "500",      # Pod
	//"count/services": "100",  # 服务
	//"count/ingresses.extensions": "100", # 应用路由
	//"persistentvolumeclaims": "100", # 存储卷
	//"count/secrets": "100",    # 密钥
	//"count/configmaps": "100", # 配置
	//"limits.cpu": "10",        # CPU 限额
	//"limits.memory": "20Gi"    # 内存限额
	//"requests.cpu": "1",       # CPU 预留
	//"requests.memory": "100Mi" # 内存预留
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,3,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,4,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

Update请求

func (*UpdateRequest) Descriptor

func (*UpdateRequest) Descriptor() ([]byte, []int)

func (*UpdateRequest) GetContainerDefaultLimit

func (m *UpdateRequest) GetContainerDefaultLimit() *container.ResourceRequirements

func (*UpdateRequest) GetInstanceId

func (m *UpdateRequest) GetInstanceId() string

func (*UpdateRequest) GetNamespace

func (m *UpdateRequest) GetNamespace() *container.Namespace

func (*UpdateRequest) GetNamespaceQuota

func (m *UpdateRequest) GetNamespaceQuota() *types.Struct

func (*UpdateRequest) ProtoMessage

func (*UpdateRequest) ProtoMessage()

func (*UpdateRequest) Reset

func (m *UpdateRequest) Reset()

func (*UpdateRequest) String

func (m *UpdateRequest) String() string

func (*UpdateRequest) Validate

func (this *UpdateRequest) Validate() error

func (*UpdateRequest) XXX_DiscardUnknown

func (m *UpdateRequest) XXX_DiscardUnknown()

func (*UpdateRequest) XXX_Marshal

func (m *UpdateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*UpdateRequest) XXX_Merge

func (m *UpdateRequest) XXX_Merge(src proto.Message)

func (*UpdateRequest) XXX_Size

func (m *UpdateRequest) XXX_Size() int

func (*UpdateRequest) XXX_Unmarshal

func (m *UpdateRequest) XXX_Unmarshal(b []byte) error

type UpdateResponse

type UpdateResponse struct {
	//
	//命名空间
	Namespace *container.Namespace `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace" form:"namespace"`
	//
	//namespace 资源限制
	//{
	//"limits.cpu": "2",
	//"limits.memory": "1Gi"
	//"configmaps": 50,
	//"persistentvolumeclaims": 50,
	//"pods": 50,
	//"replicationcontrollers": 50,
	//"resourcequotas": 50,
	//"secrets": 50,
	//"services": 50,
	//"service.loadbalancers": 50,
	//"service.nodeports": 50
	//}
	//
	NamespaceQuota *types.Struct `protobuf:"bytes,2,opt,name=namespaceQuota,proto3" json:"namespaceQuota" form:"namespaceQuota"`
	//
	//最大资源限制和初始资源请求
	ContainerDefaultLimit *container.ResourceRequirements `protobuf:"bytes,3,opt,name=containerDefaultLimit,proto3" json:"containerDefaultLimit" form:"containerDefaultLimit"`
	XXX_NoUnkeyedLiteral  struct{}                        `json:"-"`
	XXX_unrecognized      []byte                          `json:"-"`
	XXX_sizecache         int32                           `json:"-"`
}

Update返回

func (*UpdateResponse) Descriptor

func (*UpdateResponse) Descriptor() ([]byte, []int)

func (*UpdateResponse) GetContainerDefaultLimit

func (m *UpdateResponse) GetContainerDefaultLimit() *container.ResourceRequirements

func (*UpdateResponse) GetNamespace

func (m *UpdateResponse) GetNamespace() *container.Namespace

func (*UpdateResponse) GetNamespaceQuota

func (m *UpdateResponse) GetNamespaceQuota() *types.Struct

func (*UpdateResponse) ProtoMessage

func (*UpdateResponse) ProtoMessage()

func (*UpdateResponse) Reset

func (m *UpdateResponse) Reset()

func (*UpdateResponse) String

func (m *UpdateResponse) String() string

func (*UpdateResponse) Validate

func (this *UpdateResponse) Validate() error

func (*UpdateResponse) XXX_DiscardUnknown

func (m *UpdateResponse) XXX_DiscardUnknown()

func (*UpdateResponse) XXX_Marshal

func (m *UpdateResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*UpdateResponse) XXX_Merge

func (m *UpdateResponse) XXX_Merge(src proto.Message)

func (*UpdateResponse) XXX_Size

func (m *UpdateResponse) XXX_Size() int

func (*UpdateResponse) XXX_Unmarshal

func (m *UpdateResponse) XXX_Unmarshal(b []byte) error

type UpdateResponseWrapper

type UpdateResponseWrapper struct {
	//
	//返回码
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code" form:"code"`
	//
	//返回码解释
	CodeExplain string `protobuf:"bytes,2,opt,name=codeExplain,proto3" json:"codeExplain" form:"codeExplain"`
	//
	//错误详情
	Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error" form:"error"`
	//
	//返回数据
	Data                 *UpdateResponse `protobuf:"bytes,4,opt,name=data,proto3" json:"data" form:"data"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

UpdateApi返回

func (*UpdateResponseWrapper) Descriptor

func (*UpdateResponseWrapper) Descriptor() ([]byte, []int)

func (*UpdateResponseWrapper) GetCode

func (m *UpdateResponseWrapper) GetCode() int32

func (*UpdateResponseWrapper) GetCodeExplain

func (m *UpdateResponseWrapper) GetCodeExplain() string

func (*UpdateResponseWrapper) GetData

func (m *UpdateResponseWrapper) GetData() *UpdateResponse

func (*UpdateResponseWrapper) GetError

func (m *UpdateResponseWrapper) GetError() string

func (*UpdateResponseWrapper) ProtoMessage

func (*UpdateResponseWrapper) ProtoMessage()

func (*UpdateResponseWrapper) Reset

func (m *UpdateResponseWrapper) Reset()

func (*UpdateResponseWrapper) String

func (m *UpdateResponseWrapper) String() string

func (*UpdateResponseWrapper) Validate

func (this *UpdateResponseWrapper) Validate() error

func (*UpdateResponseWrapper) XXX_DiscardUnknown

func (m *UpdateResponseWrapper) XXX_DiscardUnknown()

func (*UpdateResponseWrapper) XXX_Marshal

func (m *UpdateResponseWrapper) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*UpdateResponseWrapper) XXX_Merge

func (m *UpdateResponseWrapper) XXX_Merge(src proto.Message)

func (*UpdateResponseWrapper) XXX_Size

func (m *UpdateResponseWrapper) XXX_Size() int

func (*UpdateResponseWrapper) XXX_Unmarshal

func (m *UpdateResponseWrapper) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL