provider

package
v0.8.64 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: Apache-2.0 Imports: 19 Imported by: 3

Documentation

Overview

Package provider is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	Provider_ListProviders_FullMethodName     = "/aserto.tenant.provider.v1.Provider/ListProviders"
	Provider_GetProvider_FullMethodName       = "/aserto.tenant.provider.v1.Provider/GetProvider"
	Provider_ListProviderKinds_FullMethodName = "/aserto.tenant.provider.v1.Provider/ListProviderKinds"
)

Variables

View Source
var File_aserto_tenant_provider_v1_provider_proto protoreflect.FileDescriptor
View Source
var Provider_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "aserto.tenant.provider.v1.Provider",
	HandlerType: (*ProviderServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "ListProviders",
			Handler:    _Provider_ListProviders_Handler,
		},
		{
			MethodName: "GetProvider",
			Handler:    _Provider_GetProvider_Handler,
		},
		{
			MethodName: "ListProviderKinds",
			Handler:    _Provider_ListProviderKinds_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "aserto/tenant/provider/v1/provider.proto",
}

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

Functions

func RegisterProviderHandler

func RegisterProviderHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterProviderHandler registers the http handlers for service Provider to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterProviderHandlerClient

func RegisterProviderHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ProviderClient) error

RegisterProviderHandlerClient registers the http handlers for service Provider to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ProviderClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ProviderClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ProviderClient" to call the correct interceptors.

func RegisterProviderHandlerFromEndpoint

func RegisterProviderHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterProviderHandlerFromEndpoint is same as RegisterProviderHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterProviderHandlerServer

func RegisterProviderHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ProviderServer) error

RegisterProviderHandlerServer registers the http handlers for service Provider to "mux". UnaryRPC :call ProviderServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterProviderHandlerFromEndpoint instead.

func RegisterProviderServer

func RegisterProviderServer(s grpc.ServiceRegistrar, srv ProviderServer)

Types

type GetProviderRequest

type GetProviderRequest struct {
	Kind v1.ProviderKind `protobuf:"varint,1,opt,name=kind,proto3,enum=aserto.api.v1.ProviderKind" json:"kind,omitempty"`
	Id   string          `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*GetProviderRequest) Descriptor deprecated

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

Deprecated: Use GetProviderRequest.ProtoReflect.Descriptor instead.

func (*GetProviderRequest) GetId

func (x *GetProviderRequest) GetId() string

func (*GetProviderRequest) GetKind

func (x *GetProviderRequest) GetKind() v1.ProviderKind

func (*GetProviderRequest) ProtoMessage

func (*GetProviderRequest) ProtoMessage()

func (*GetProviderRequest) ProtoReflect

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

func (*GetProviderRequest) Reset

func (x *GetProviderRequest) Reset()

func (*GetProviderRequest) String

func (x *GetProviderRequest) String() string

type GetProviderResponse

type GetProviderResponse struct {
	Results []*v1.Provider `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

func (*GetProviderResponse) Descriptor deprecated

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

Deprecated: Use GetProviderResponse.ProtoReflect.Descriptor instead.

func (*GetProviderResponse) GetResults

func (x *GetProviderResponse) GetResults() []*v1.Provider

func (*GetProviderResponse) ProtoMessage

func (*GetProviderResponse) ProtoMessage()

func (*GetProviderResponse) ProtoReflect

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

func (*GetProviderResponse) Reset

func (x *GetProviderResponse) Reset()

func (*GetProviderResponse) String

func (x *GetProviderResponse) String() string

type ListProviderKindsRequest

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

func (*ListProviderKindsRequest) Descriptor deprecated

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

Deprecated: Use ListProviderKindsRequest.ProtoReflect.Descriptor instead.

func (*ListProviderKindsRequest) ProtoMessage

func (*ListProviderKindsRequest) ProtoMessage()

func (*ListProviderKindsRequest) ProtoReflect

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

func (*ListProviderKindsRequest) Reset

func (x *ListProviderKindsRequest) Reset()

func (*ListProviderKindsRequest) String

func (x *ListProviderKindsRequest) String() string

type ListProviderKindsResponse

type ListProviderKindsResponse struct {
	Results []string `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

func (*ListProviderKindsResponse) Descriptor deprecated

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

Deprecated: Use ListProviderKindsResponse.ProtoReflect.Descriptor instead.

func (*ListProviderKindsResponse) GetResults

func (x *ListProviderKindsResponse) GetResults() []string

func (*ListProviderKindsResponse) ProtoMessage

func (*ListProviderKindsResponse) ProtoMessage()

func (*ListProviderKindsResponse) ProtoReflect

func (*ListProviderKindsResponse) Reset

func (x *ListProviderKindsResponse) Reset()

func (*ListProviderKindsResponse) String

func (x *ListProviderKindsResponse) String() string

type ListProvidersRequest

type ListProvidersRequest struct {
	Kind v1.ProviderKind `protobuf:"varint,1,opt,name=kind,proto3,enum=aserto.api.v1.ProviderKind" json:"kind,omitempty"`
	// contains filtered or unexported fields
}

func (*ListProvidersRequest) Descriptor deprecated

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

Deprecated: Use ListProvidersRequest.ProtoReflect.Descriptor instead.

func (*ListProvidersRequest) GetKind

func (x *ListProvidersRequest) GetKind() v1.ProviderKind

func (*ListProvidersRequest) ProtoMessage

func (*ListProvidersRequest) ProtoMessage()

func (*ListProvidersRequest) ProtoReflect

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

func (*ListProvidersRequest) Reset

func (x *ListProvidersRequest) Reset()

func (*ListProvidersRequest) String

func (x *ListProvidersRequest) String() string

type ListProvidersResponse

type ListProvidersResponse struct {
	Results []*v1.Provider `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

func (*ListProvidersResponse) Descriptor deprecated

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

Deprecated: Use ListProvidersResponse.ProtoReflect.Descriptor instead.

func (*ListProvidersResponse) GetResults

func (x *ListProvidersResponse) GetResults() []*v1.Provider

func (*ListProvidersResponse) ProtoMessage

func (*ListProvidersResponse) ProtoMessage()

func (*ListProvidersResponse) ProtoReflect

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

func (*ListProvidersResponse) Reset

func (x *ListProvidersResponse) Reset()

func (*ListProvidersResponse) String

func (x *ListProvidersResponse) String() string

type ProviderClient

type ProviderClient interface {
	ListProviders(ctx context.Context, in *ListProvidersRequest, opts ...grpc.CallOption) (*ListProvidersResponse, error)
	GetProvider(ctx context.Context, in *GetProviderRequest, opts ...grpc.CallOption) (*GetProviderResponse, error)
	ListProviderKinds(ctx context.Context, in *ListProviderKindsRequest, opts ...grpc.CallOption) (*ListProviderKindsResponse, error)
}

ProviderClient is the client API for Provider 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 NewProviderClient

func NewProviderClient(cc grpc.ClientConnInterface) ProviderClient

type ProviderServer

ProviderServer is the server API for Provider service. All implementations should embed UnimplementedProviderServer for forward compatibility

type UnimplementedProviderServer

type UnimplementedProviderServer struct {
}

UnimplementedProviderServer should be embedded to have forward compatible implementations.

func (UnimplementedProviderServer) GetProvider

func (UnimplementedProviderServer) ListProviderKinds

func (UnimplementedProviderServer) ListProviders

type UnsafeProviderServer

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

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

Jump to

Keyboard shortcuts

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