v1

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2022 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Error_name = map[int32]string{
		0: "CONFIG_ERR_UNKNOWN",
		1: "CONFIG_ERR_INTERNAL_ERROR",
		2: "CONFIG_ERR_NOT_ADMIN_PORTAL",
	}
	Error_value = map[string]int32{
		"CONFIG_ERR_UNKNOWN":          0,
		"CONFIG_ERR_INTERNAL_ERROR":   1,
		"CONFIG_ERR_NOT_ADMIN_PORTAL": 2,
	}
)

Enum value maps for Error.

View Source
var Config_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "io.tkeel.rudder.api.config.v1.Config",
	HandlerType: (*ConfigServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetDeploymentConfig",
			Handler:    _Config_GetDeploymentConfig_Handler,
		},
		{
			MethodName: "GetPlatformConfig",
			Handler:    _Config_GetPlatformConfig_Handler,
		},
		{
			MethodName: "DelPlatformConfig",
			Handler:    _Config_DelPlatformConfig_Handler,
		},
		{
			MethodName: "SetPlatformExtraConfig",
			Handler:    _Config_SetPlatformExtraConfig_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/config/v1/config.proto",
}

Config_ServiceDesc is the grpc.ServiceDesc for Config service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_api_config_v1_config_proto protoreflect.FileDescriptor
View Source
var File_api_config_v1_error_proto protoreflect.FileDescriptor

Functions

func ConfigErrInternalError

func ConfigErrInternalError() errors.Error

func ConfigErrNotAdminPortal added in v1.0.0

func ConfigErrNotAdminPortal() errors.Error

func ConfigErrUnknown

func ConfigErrUnknown() errors.Error

func RegisterConfigHTTPServer

func RegisterConfigHTTPServer(container *go_restful.Container, srv ConfigHTTPServer)

func RegisterConfigServer

func RegisterConfigServer(s grpc.ServiceRegistrar, srv ConfigServer)

Types

type ConfigClient

type ConfigClient interface {
	GetDeploymentConfig(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*GetDeploymentConfigResponse, error)
	GetPlatformConfig(ctx context.Context, in *PlatformConfigRequest, opts ...grpc.CallOption) (*structpb.Value, error)
	DelPlatformConfig(ctx context.Context, in *PlatformConfigRequest, opts ...grpc.CallOption) (*structpb.Value, error)
	SetPlatformExtraConfig(ctx context.Context, in *SetPlatformExtraConfigRequest, opts ...grpc.CallOption) (*structpb.Value, error)
}

ConfigClient is the client API for Config service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewConfigClient

func NewConfigClient(cc grpc.ClientConnInterface) ConfigClient

type ConfigHTTPHandler

type ConfigHTTPHandler struct {
	// contains filtered or unexported fields
}

func (*ConfigHTTPHandler) DelPlatformConfig added in v1.0.0

func (h *ConfigHTTPHandler) DelPlatformConfig(req *go_restful.Request, resp *go_restful.Response)

func (*ConfigHTTPHandler) GetDeploymentConfig

func (h *ConfigHTTPHandler) GetDeploymentConfig(req *go_restful.Request, resp *go_restful.Response)

func (*ConfigHTTPHandler) GetPlatformConfig added in v1.0.0

func (h *ConfigHTTPHandler) GetPlatformConfig(req *go_restful.Request, resp *go_restful.Response)

func (*ConfigHTTPHandler) SetPlatformExtraConfig added in v1.0.0

func (h *ConfigHTTPHandler) SetPlatformExtraConfig(req *go_restful.Request, resp *go_restful.Response)

type ConfigHTTPServer

type ConfigHTTPServer interface {
	DelPlatformConfig(context.Context, *PlatformConfigRequest) (*structpb.Value, error)
	GetDeploymentConfig(context.Context, *emptypb.Empty) (*GetDeploymentConfigResponse, error)
	GetPlatformConfig(context.Context, *PlatformConfigRequest) (*structpb.Value, error)
	SetPlatformExtraConfig(context.Context, *SetPlatformExtraConfigRequest) (*structpb.Value, error)
}

type ConfigServer

type ConfigServer interface {
	GetDeploymentConfig(context.Context, *emptypb.Empty) (*GetDeploymentConfigResponse, error)
	GetPlatformConfig(context.Context, *PlatformConfigRequest) (*structpb.Value, error)
	DelPlatformConfig(context.Context, *PlatformConfigRequest) (*structpb.Value, error)
	SetPlatformExtraConfig(context.Context, *SetPlatformExtraConfigRequest) (*structpb.Value, error)
	// contains filtered or unexported methods
}

ConfigServer is the server API for Config service. All implementations must embed UnimplementedConfigServer for forward compatibility

type Error

type Error int32

@plugins=protoc-gen-go-errors 错误

const (
	// @msg=未知类型
	// @code=UNKNOWN
	Error_CONFIG_ERR_UNKNOWN Error = 0
	// @msg=请求后端内部错误
	// @code=INTERNAL
	Error_CONFIG_ERR_INTERNAL_ERROR Error = 1
	// @msg=非管理平台
	// @code=PERMISSION_DENIED
	Error_CONFIG_ERR_NOT_ADMIN_PORTAL Error = 2
)

func (Error) Descriptor

func (Error) Descriptor() protoreflect.EnumDescriptor

func (Error) Enum

func (x Error) Enum() *Error

func (Error) EnumDescriptor deprecated

func (Error) EnumDescriptor() ([]byte, []int)

Deprecated: Use Error.Descriptor instead.

func (Error) Number

func (x Error) Number() protoreflect.EnumNumber

func (Error) String

func (x Error) String() string

func (Error) Type

func (Error) Type() protoreflect.EnumType

type GetDeploymentConfigResponse

type GetDeploymentConfigResponse struct {
	AdminHost  string `protobuf:"bytes,1,opt,name=admin_host,json=adminHost,proto3" json:"admin_host,omitempty"`
	TenantHost string `protobuf:"bytes,2,opt,name=tenant_host,json=tenantHost,proto3" json:"tenant_host,omitempty"`
	Port       string `protobuf:"bytes,3,opt,name=port,proto3" json:"port,omitempty"`
	DocsAddr   string `protobuf:"bytes,4,opt,name=docs_addr,json=docsAddr,proto3" json:"docs_addr,omitempty"`
	// contains filtered or unexported fields
}

func (*GetDeploymentConfigResponse) Descriptor deprecated

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

Deprecated: Use GetDeploymentConfigResponse.ProtoReflect.Descriptor instead.

func (*GetDeploymentConfigResponse) GetAdminHost

func (x *GetDeploymentConfigResponse) GetAdminHost() string

func (*GetDeploymentConfigResponse) GetDocsAddr added in v1.0.0

func (x *GetDeploymentConfigResponse) GetDocsAddr() string

func (*GetDeploymentConfigResponse) GetPort

func (x *GetDeploymentConfigResponse) GetPort() string

func (*GetDeploymentConfigResponse) GetTenantHost

func (x *GetDeploymentConfigResponse) GetTenantHost() string

func (*GetDeploymentConfigResponse) ProtoMessage

func (*GetDeploymentConfigResponse) ProtoMessage()

func (*GetDeploymentConfigResponse) ProtoReflect

func (*GetDeploymentConfigResponse) Reset

func (x *GetDeploymentConfigResponse) Reset()

func (*GetDeploymentConfigResponse) String

func (x *GetDeploymentConfigResponse) String() string

type PlatformConfigRequest added in v1.0.0

type PlatformConfigRequest struct {
	Key  string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

func (*PlatformConfigRequest) Descriptor deprecated added in v1.0.0

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

Deprecated: Use PlatformConfigRequest.ProtoReflect.Descriptor instead.

func (*PlatformConfigRequest) GetKey added in v1.0.0

func (x *PlatformConfigRequest) GetKey() string

func (*PlatformConfigRequest) GetPath added in v1.0.0

func (x *PlatformConfigRequest) GetPath() string

func (*PlatformConfigRequest) ProtoMessage added in v1.0.0

func (*PlatformConfigRequest) ProtoMessage()

func (*PlatformConfigRequest) ProtoReflect added in v1.0.0

func (x *PlatformConfigRequest) ProtoReflect() protoreflect.Message

func (*PlatformConfigRequest) Reset added in v1.0.0

func (x *PlatformConfigRequest) Reset()

func (*PlatformConfigRequest) String added in v1.0.0

func (x *PlatformConfigRequest) String() string

type SetPlatformExtraConfigRequest added in v1.0.0

type SetPlatformExtraConfigRequest struct {
	Key   string          `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Path  string          `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	Extra *structpb.Value `protobuf:"bytes,3,opt,name=extra,proto3" json:"extra,omitempty"`
	// contains filtered or unexported fields
}

func (*SetPlatformExtraConfigRequest) Descriptor deprecated added in v1.0.0

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

Deprecated: Use SetPlatformExtraConfigRequest.ProtoReflect.Descriptor instead.

func (*SetPlatformExtraConfigRequest) GetExtra added in v1.0.0

func (*SetPlatformExtraConfigRequest) GetKey added in v1.0.0

func (*SetPlatformExtraConfigRequest) GetPath added in v1.0.0

func (*SetPlatformExtraConfigRequest) ProtoMessage added in v1.0.0

func (*SetPlatformExtraConfigRequest) ProtoMessage()

func (*SetPlatformExtraConfigRequest) ProtoReflect added in v1.0.0

func (*SetPlatformExtraConfigRequest) Reset added in v1.0.0

func (x *SetPlatformExtraConfigRequest) Reset()

func (*SetPlatformExtraConfigRequest) String added in v1.0.0

type UnimplementedConfigServer

type UnimplementedConfigServer struct {
}

UnimplementedConfigServer must be embedded to have forward compatible implementations.

func (UnimplementedConfigServer) DelPlatformConfig added in v1.0.0

func (UnimplementedConfigServer) GetDeploymentConfig

func (UnimplementedConfigServer) GetPlatformConfig added in v1.0.0

func (UnimplementedConfigServer) SetPlatformExtraConfig added in v1.0.0

type UnsafeConfigServer

type UnsafeConfigServer interface {
	// contains filtered or unexported methods
}

UnsafeConfigServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ConfigServer will result in compilation errors.

Jump to

Keyboard shortcuts

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