firewallv1connect

package
v0.0.0-...-94cd6a6 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// FirewallServiceCreateEgressFirewallRuleProcedure is the fully-qualified name of the
	// FirewallService's CreateEgressFirewallRule RPC.
	FirewallServiceCreateEgressFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/CreateEgressFirewallRule"
	// FirewallServiceCreateFirewallRuleProcedure is the fully-qualified name of the FirewallService's
	// CreateFirewallRule RPC.
	FirewallServiceCreateFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/CreateFirewallRule"
	// FirewallServiceCreatePortForwardingRuleProcedure is the fully-qualified name of the
	// FirewallService's CreatePortForwardingRule RPC.
	FirewallServiceCreatePortForwardingRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/CreatePortForwardingRule"
	// FirewallServiceDeleteEgressFirewallRuleProcedure is the fully-qualified name of the
	// FirewallService's DeleteEgressFirewallRule RPC.
	FirewallServiceDeleteEgressFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/DeleteEgressFirewallRule"
	// FirewallServiceDeleteFirewallRuleProcedure is the fully-qualified name of the FirewallService's
	// DeleteFirewallRule RPC.
	FirewallServiceDeleteFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/DeleteFirewallRule"
	// FirewallServiceDeletePortForwardingRuleProcedure is the fully-qualified name of the
	// FirewallService's DeletePortForwardingRule RPC.
	FirewallServiceDeletePortForwardingRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/DeletePortForwardingRule"
	// FirewallServiceListEgressFirewallRulesProcedure is the fully-qualified name of the
	// FirewallService's ListEgressFirewallRules RPC.
	FirewallServiceListEgressFirewallRulesProcedure = "/cloudstack.management.firewall.v1.FirewallService/ListEgressFirewallRules"
	// FirewallServiceListFirewallRulesProcedure is the fully-qualified name of the FirewallService's
	// ListFirewallRules RPC.
	FirewallServiceListFirewallRulesProcedure = "/cloudstack.management.firewall.v1.FirewallService/ListFirewallRules"
	// FirewallServiceListPortForwardingRulesProcedure is the fully-qualified name of the
	// FirewallService's ListPortForwardingRules RPC.
	FirewallServiceListPortForwardingRulesProcedure = "/cloudstack.management.firewall.v1.FirewallService/ListPortForwardingRules"
	// FirewallServiceUpdateEgressFirewallRuleProcedure is the fully-qualified name of the
	// FirewallService's UpdateEgressFirewallRule RPC.
	FirewallServiceUpdateEgressFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/UpdateEgressFirewallRule"
	// FirewallServiceUpdateFirewallRuleProcedure is the fully-qualified name of the FirewallService's
	// UpdateFirewallRule RPC.
	FirewallServiceUpdateFirewallRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/UpdateFirewallRule"
	// FirewallServiceUpdatePortForwardingRuleProcedure is the fully-qualified name of the
	// FirewallService's UpdatePortForwardingRule RPC.
	FirewallServiceUpdatePortForwardingRuleProcedure = "/cloudstack.management.firewall.v1.FirewallService/UpdatePortForwardingRule"
)

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 (
	// FirewallServiceName is the fully-qualified name of the FirewallService service.
	FirewallServiceName = "cloudstack.management.firewall.v1.FirewallService"
)

Variables

This section is empty.

Functions

func NewFirewallServiceHandler

func NewFirewallServiceHandler(svc FirewallServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewFirewallServiceHandler 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 FirewallServiceClient

type FirewallServiceClient interface {
	// CreateEgressFirewallRule Creates a egress firewall rule for a given network
	CreateEgressFirewallRule(context.Context, *connect.Request[v1.CreateEgressFirewallRuleRequest]) (*connect.Response[v1.CreateEgressFirewallRuleResponse], error)
	// CreateFirewallRule Creates a firewall rule for a given IP address
	CreateFirewallRule(context.Context, *connect.Request[v1.CreateFirewallRuleRequest]) (*connect.Response[v1.CreateFirewallRuleResponse], error)
	// CreatePortForwardingRule Creates a port forwarding rule
	CreatePortForwardingRule(context.Context, *connect.Request[v1.CreatePortForwardingRuleRequest]) (*connect.Response[v1.CreatePortForwardingRuleResponse], error)
	// DeleteEgressFirewallRule Deletes an egress firewall rule
	DeleteEgressFirewallRule(context.Context, *connect.Request[v1.DeleteEgressFirewallRuleRequest]) (*connect.Response[v1.DeleteEgressFirewallRuleResponse], error)
	// DeleteFirewallRule Deletes a firewall rule
	DeleteFirewallRule(context.Context, *connect.Request[v1.DeleteFirewallRuleRequest]) (*connect.Response[v1.DeleteFirewallRuleResponse], error)
	// DeletePortForwardingRule Deletes a port forwarding rule
	DeletePortForwardingRule(context.Context, *connect.Request[v1.DeletePortForwardingRuleRequest]) (*connect.Response[v1.DeletePortForwardingRuleResponse], error)
	// ListEgressFirewallRules Lists all egress firewall rules for network ID.
	ListEgressFirewallRules(context.Context, *connect.Request[v1.ListEgressFirewallRulesRequest]) (*connect.Response[v1.ListEgressFirewallRulesResponse], error)
	// ListFirewallRules Lists all firewall rules for an IP address.
	ListFirewallRules(context.Context, *connect.Request[v1.ListFirewallRulesRequest]) (*connect.Response[v1.ListFirewallRulesResponse], error)
	// ListPortForwardingRules Lists all port forwarding rules for an IP address.
	ListPortForwardingRules(context.Context, *connect.Request[v1.ListPortForwardingRulesRequest]) (*connect.Response[v1.ListPortForwardingRulesResponse], error)
	// UpdateEgressFirewallRule Updates egress firewall rule
	UpdateEgressFirewallRule(context.Context, *connect.Request[v1.UpdateEgressFirewallRuleRequest]) (*connect.Response[v1.UpdateEgressFirewallRuleResponse], error)
	// UpdateFirewallRule Updates firewall rule
	UpdateFirewallRule(context.Context, *connect.Request[v1.UpdateFirewallRuleRequest]) (*connect.Response[v1.UpdateFirewallRuleResponse], error)
	// UpdatePortForwardingRule Updates a port forwarding rule. Only the private port and the virtual machine can be updated.
	UpdatePortForwardingRule(context.Context, *connect.Request[v1.UpdatePortForwardingRuleRequest]) (*connect.Response[v1.UpdatePortForwardingRuleResponse], error)
}

FirewallServiceClient is a client for the cloudstack.management.firewall.v1.FirewallService service.

func NewFirewallServiceClient

func NewFirewallServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) FirewallServiceClient

NewFirewallServiceClient constructs a client for the cloudstack.management.firewall.v1.FirewallService 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 FirewallServiceHandler

type FirewallServiceHandler interface {
	// CreateEgressFirewallRule Creates a egress firewall rule for a given network
	CreateEgressFirewallRule(context.Context, *connect.Request[v1.CreateEgressFirewallRuleRequest]) (*connect.Response[v1.CreateEgressFirewallRuleResponse], error)
	// CreateFirewallRule Creates a firewall rule for a given IP address
	CreateFirewallRule(context.Context, *connect.Request[v1.CreateFirewallRuleRequest]) (*connect.Response[v1.CreateFirewallRuleResponse], error)
	// CreatePortForwardingRule Creates a port forwarding rule
	CreatePortForwardingRule(context.Context, *connect.Request[v1.CreatePortForwardingRuleRequest]) (*connect.Response[v1.CreatePortForwardingRuleResponse], error)
	// DeleteEgressFirewallRule Deletes an egress firewall rule
	DeleteEgressFirewallRule(context.Context, *connect.Request[v1.DeleteEgressFirewallRuleRequest]) (*connect.Response[v1.DeleteEgressFirewallRuleResponse], error)
	// DeleteFirewallRule Deletes a firewall rule
	DeleteFirewallRule(context.Context, *connect.Request[v1.DeleteFirewallRuleRequest]) (*connect.Response[v1.DeleteFirewallRuleResponse], error)
	// DeletePortForwardingRule Deletes a port forwarding rule
	DeletePortForwardingRule(context.Context, *connect.Request[v1.DeletePortForwardingRuleRequest]) (*connect.Response[v1.DeletePortForwardingRuleResponse], error)
	// ListEgressFirewallRules Lists all egress firewall rules for network ID.
	ListEgressFirewallRules(context.Context, *connect.Request[v1.ListEgressFirewallRulesRequest]) (*connect.Response[v1.ListEgressFirewallRulesResponse], error)
	// ListFirewallRules Lists all firewall rules for an IP address.
	ListFirewallRules(context.Context, *connect.Request[v1.ListFirewallRulesRequest]) (*connect.Response[v1.ListFirewallRulesResponse], error)
	// ListPortForwardingRules Lists all port forwarding rules for an IP address.
	ListPortForwardingRules(context.Context, *connect.Request[v1.ListPortForwardingRulesRequest]) (*connect.Response[v1.ListPortForwardingRulesResponse], error)
	// UpdateEgressFirewallRule Updates egress firewall rule
	UpdateEgressFirewallRule(context.Context, *connect.Request[v1.UpdateEgressFirewallRuleRequest]) (*connect.Response[v1.UpdateEgressFirewallRuleResponse], error)
	// UpdateFirewallRule Updates firewall rule
	UpdateFirewallRule(context.Context, *connect.Request[v1.UpdateFirewallRuleRequest]) (*connect.Response[v1.UpdateFirewallRuleResponse], error)
	// UpdatePortForwardingRule Updates a port forwarding rule. Only the private port and the virtual machine can be updated.
	UpdatePortForwardingRule(context.Context, *connect.Request[v1.UpdatePortForwardingRuleRequest]) (*connect.Response[v1.UpdatePortForwardingRuleResponse], error)
}

FirewallServiceHandler is an implementation of the cloudstack.management.firewall.v1.FirewallService service.

type UnimplementedFirewallServiceHandler

type UnimplementedFirewallServiceHandler struct{}

UnimplementedFirewallServiceHandler returns CodeUnimplemented from all methods.

Jump to

Keyboard shortcuts

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