operatorconnect

package
v1.17.21 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2026 License: Apache-2.0 Imports: 7 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// OperatorComponentUpdateProcedure is the fully-qualified name of the Operator's ComponentUpdate
	// RPC.
	OperatorComponentUpdateProcedure = "/dapr.proto.operator.v1.Operator/ComponentUpdate"
	// OperatorListComponentsProcedure is the fully-qualified name of the Operator's ListComponents RPC.
	OperatorListComponentsProcedure = "/dapr.proto.operator.v1.Operator/ListComponents"
	// OperatorGetConfigurationProcedure is the fully-qualified name of the Operator's GetConfiguration
	// RPC.
	OperatorGetConfigurationProcedure = "/dapr.proto.operator.v1.Operator/GetConfiguration"
	// OperatorListSubscriptionsProcedure is the fully-qualified name of the Operator's
	// ListSubscriptions RPC.
	OperatorListSubscriptionsProcedure = "/dapr.proto.operator.v1.Operator/ListSubscriptions"
	// OperatorGetResiliencyProcedure is the fully-qualified name of the Operator's GetResiliency RPC.
	OperatorGetResiliencyProcedure = "/dapr.proto.operator.v1.Operator/GetResiliency"
	// OperatorListResiliencyProcedure is the fully-qualified name of the Operator's ListResiliency RPC.
	OperatorListResiliencyProcedure = "/dapr.proto.operator.v1.Operator/ListResiliency"
	// OperatorListSubscriptionsV2Procedure is the fully-qualified name of the Operator's
	// ListSubscriptionsV2 RPC.
	OperatorListSubscriptionsV2Procedure = "/dapr.proto.operator.v1.Operator/ListSubscriptionsV2"
	// OperatorSubscriptionUpdateProcedure is the fully-qualified name of the Operator's
	// SubscriptionUpdate RPC.
	OperatorSubscriptionUpdateProcedure = "/dapr.proto.operator.v1.Operator/SubscriptionUpdate"
	// OperatorListHTTPEndpointsProcedure is the fully-qualified name of the Operator's
	// ListHTTPEndpoints RPC.
	OperatorListHTTPEndpointsProcedure = "/dapr.proto.operator.v1.Operator/ListHTTPEndpoints"
	// OperatorHTTPEndpointUpdateProcedure is the fully-qualified name of the Operator's
	// HTTPEndpointUpdate RPC.
	OperatorHTTPEndpointUpdateProcedure = "/dapr.proto.operator.v1.Operator/HTTPEndpointUpdate"
)

These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.

Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.

View Source
const (
	// OperatorName is the fully-qualified name of the Operator service.
	OperatorName = "dapr.proto.operator.v1.Operator"
)

Variables

This section is empty.

Functions

func NewOperatorHandler

func NewOperatorHandler(svc OperatorHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewOperatorHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

Types

type OperatorClient

type OperatorClient interface {
	// Sends events to Dapr sidecars upon component changes.
	ComponentUpdate(context.Context, *connect.Request[v1.ComponentUpdateRequest]) (*connect.ServerStreamForClient[v1.ComponentUpdateEvent], error)
	// Returns a list of available components
	ListComponents(context.Context, *connect.Request[v1.ListComponentsRequest]) (*connect.Response[v1.ListComponentResponse], error)
	// Returns a given configuration by name
	GetConfiguration(context.Context, *connect.Request[v1.GetConfigurationRequest]) (*connect.Response[v1.GetConfigurationResponse], error)
	// Returns a list of pub/sub subscriptions
	ListSubscriptions(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[v1.ListSubscriptionsResponse], error)
	// Returns a given resiliency configuration by name
	GetResiliency(context.Context, *connect.Request[v1.GetResiliencyRequest]) (*connect.Response[v1.GetResiliencyResponse], error)
	// Returns a list of resiliency configurations
	ListResiliency(context.Context, *connect.Request[v1.ListResiliencyRequest]) (*connect.Response[v1.ListResiliencyResponse], error)
	// Returns a list of pub/sub subscriptions, ListSubscriptionsRequest to expose pod info
	ListSubscriptionsV2(context.Context, *connect.Request[v1.ListSubscriptionsRequest]) (*connect.Response[v1.ListSubscriptionsResponse], error)
	// Sends events to Dapr sidecars upon subscription changes.
	SubscriptionUpdate(context.Context, *connect.Request[v1.SubscriptionUpdateRequest]) (*connect.ServerStreamForClient[v1.SubscriptionUpdateEvent], error)
	// Returns a list of http endpoints
	ListHTTPEndpoints(context.Context, *connect.Request[v1.ListHTTPEndpointsRequest]) (*connect.Response[v1.ListHTTPEndpointsResponse], error)
	// Sends events to Dapr sidecars upon http endpoint changes.
	HTTPEndpointUpdate(context.Context, *connect.Request[v1.HTTPEndpointUpdateRequest]) (*connect.ServerStreamForClient[v1.HTTPEndpointUpdateEvent], error)
}

OperatorClient is a client for the dapr.proto.operator.v1.Operator service.

func NewOperatorClient

func NewOperatorClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) OperatorClient

NewOperatorClient constructs a client for the dapr.proto.operator.v1.Operator service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type OperatorHandler

type OperatorHandler interface {
	// Sends events to Dapr sidecars upon component changes.
	ComponentUpdate(context.Context, *connect.Request[v1.ComponentUpdateRequest], *connect.ServerStream[v1.ComponentUpdateEvent]) error
	// Returns a list of available components
	ListComponents(context.Context, *connect.Request[v1.ListComponentsRequest]) (*connect.Response[v1.ListComponentResponse], error)
	// Returns a given configuration by name
	GetConfiguration(context.Context, *connect.Request[v1.GetConfigurationRequest]) (*connect.Response[v1.GetConfigurationResponse], error)
	// Returns a list of pub/sub subscriptions
	ListSubscriptions(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[v1.ListSubscriptionsResponse], error)
	// Returns a given resiliency configuration by name
	GetResiliency(context.Context, *connect.Request[v1.GetResiliencyRequest]) (*connect.Response[v1.GetResiliencyResponse], error)
	// Returns a list of resiliency configurations
	ListResiliency(context.Context, *connect.Request[v1.ListResiliencyRequest]) (*connect.Response[v1.ListResiliencyResponse], error)
	// Returns a list of pub/sub subscriptions, ListSubscriptionsRequest to expose pod info
	ListSubscriptionsV2(context.Context, *connect.Request[v1.ListSubscriptionsRequest]) (*connect.Response[v1.ListSubscriptionsResponse], error)
	// Sends events to Dapr sidecars upon subscription changes.
	SubscriptionUpdate(context.Context, *connect.Request[v1.SubscriptionUpdateRequest], *connect.ServerStream[v1.SubscriptionUpdateEvent]) error
	// Returns a list of http endpoints
	ListHTTPEndpoints(context.Context, *connect.Request[v1.ListHTTPEndpointsRequest]) (*connect.Response[v1.ListHTTPEndpointsResponse], error)
	// Sends events to Dapr sidecars upon http endpoint changes.
	HTTPEndpointUpdate(context.Context, *connect.Request[v1.HTTPEndpointUpdateRequest], *connect.ServerStream[v1.HTTPEndpointUpdateEvent]) error
}

OperatorHandler is an implementation of the dapr.proto.operator.v1.Operator service.

type UnimplementedOperatorHandler

type UnimplementedOperatorHandler struct{}

UnimplementedOperatorHandler returns CodeUnimplemented from all methods.

Jump to

Keyboard shortcuts

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