v0

package
v0.1.88 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: MIT Imports: 22 Imported by: 0

Documentation

Overview

Package v0 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	CLI_Ping_FullMethodName                                        = "/observability.v0.CLI/Ping"
	CLI_GetAgentInformation_FullMethodName                         = "/observability.v0.CLI/GetAgentInformation"
	CLI_GetProjects_FullMethodName                                 = "/observability.v0.CLI/GetProjects"
	CLI_GetProjectInventory_FullMethodName                         = "/observability.v0.CLI/GetProjectInventory"
	CLI_GetProjectServiceDependencyGraph_FullMethodName            = "/observability.v0.CLI/GetProjectServiceDependencyGraph"
	CLI_GetProjectPublicApplicationsDependencyGraph_FullMethodName = "/observability.v0.CLI/GetProjectPublicApplicationsDependencyGraph"
	CLI_LogHistory_FullMethodName                                  = "/observability.v0.CLI/LogHistory"
	CLI_GetActive_FullMethodName                                   = "/observability.v0.CLI/GetActive"
	CLI_GetAddresses_FullMethodName                                = "/observability.v0.CLI/GetAddresses"
	CLI_GetSharedConfiguration_FullMethodName                      = "/observability.v0.CLI/GetSharedConfiguration"
	CLI_Logs_FullMethodName                                        = "/observability.v0.CLI/Logs"
	CLI_ActiveLogHistory_FullMethodName                            = "/observability.v0.CLI/ActiveLogHistory"
	CLI_GetFlowStatus_FullMethodName                               = "/observability.v0.CLI/GetFlowStatus"
	CLI_StopFlow_FullMethodName                                    = "/observability.v0.CLI/StopFlow"
)

Variables

View Source
var CLI_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "observability.v0.CLI",
	HandlerType: (*CLIServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Ping",
			Handler:    _CLI_Ping_Handler,
		},
		{
			MethodName: "GetAgentInformation",
			Handler:    _CLI_GetAgentInformation_Handler,
		},
		{
			MethodName: "GetProjects",
			Handler:    _CLI_GetProjects_Handler,
		},
		{
			MethodName: "GetProjectInventory",
			Handler:    _CLI_GetProjectInventory_Handler,
		},
		{
			MethodName: "GetProjectServiceDependencyGraph",
			Handler:    _CLI_GetProjectServiceDependencyGraph_Handler,
		},
		{
			MethodName: "GetProjectPublicApplicationsDependencyGraph",
			Handler:    _CLI_GetProjectPublicApplicationsDependencyGraph_Handler,
		},
		{
			MethodName: "LogHistory",
			Handler:    _CLI_LogHistory_Handler,
		},
		{
			MethodName: "GetActive",
			Handler:    _CLI_GetActive_Handler,
		},
		{
			MethodName: "GetAddresses",
			Handler:    _CLI_GetAddresses_Handler,
		},
		{
			MethodName: "GetSharedConfiguration",
			Handler:    _CLI_GetSharedConfiguration_Handler,
		},
		{
			MethodName: "ActiveLogHistory",
			Handler:    _CLI_ActiveLogHistory_Handler,
		},
		{
			MethodName: "GetFlowStatus",
			Handler:    _CLI_GetFlowStatus_Handler,
		},
		{
			MethodName: "StopFlow",
			Handler:    _CLI_StopFlow_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Logs",
			Handler:       _CLI_Logs_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "cli/v0/cli.proto",
}

CLI_ServiceDesc is the grpc.ServiceDesc for CLI 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_cli_v0_cli_proto protoreflect.FileDescriptor

Functions

func RegisterCLIHandler

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

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

func RegisterCLIHandlerClient

func RegisterCLIHandlerClient(ctx context.Context, mux *runtime.ServeMux, client CLIClient) error

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

func RegisterCLIHandlerFromEndpoint

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

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

func RegisterCLIHandlerServer

func RegisterCLIHandlerServer(ctx context.Context, mux *runtime.ServeMux, server CLIServer) error

RegisterCLIHandlerServer registers the http handlers for service CLI to "mux". UnaryRPC :call CLIServer 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 RegisterCLIHandlerFromEndpoint instead.

func RegisterCLIServer

func RegisterCLIServer(s grpc.ServiceRegistrar, srv CLIServer)

Types

type ActiveResponse

type ActiveResponse struct {
	Project     string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
	Application string `protobuf:"bytes,2,opt,name=application,proto3" json:"application,omitempty"`
	Service     string `protobuf:"bytes,3,opt,name=service,proto3" json:"service,omitempty"`
	// contains filtered or unexported fields
}

func (*ActiveResponse) Descriptor deprecated

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

Deprecated: Use ActiveResponse.ProtoReflect.Descriptor instead.

func (*ActiveResponse) GetApplication

func (x *ActiveResponse) GetApplication() string

func (*ActiveResponse) GetProject

func (x *ActiveResponse) GetProject() string

func (*ActiveResponse) GetService

func (x *ActiveResponse) GetService() string

func (*ActiveResponse) ProtoMessage

func (*ActiveResponse) ProtoMessage()

func (*ActiveResponse) ProtoReflect

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

func (*ActiveResponse) Reset

func (x *ActiveResponse) Reset()

func (*ActiveResponse) String

func (x *ActiveResponse) String() string

type CLIClient

type CLIClient interface {
	Ping(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
	GetAgentInformation(ctx context.Context, in *GetAgentInformationRequest, opts ...grpc.CallOption) (*v0.AgentInformation, error)
	GetProjects(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*GetProjectsResponse, error)
	GetProjectInventory(ctx context.Context, in *ProjectRequest, opts ...grpc.CallOption) (*v01.Project, error)
	GetProjectServiceDependencyGraph(ctx context.Context, in *ProjectRequest, opts ...grpc.CallOption) (*v02.GraphResponse, error)
	GetProjectPublicApplicationsDependencyGraph(ctx context.Context, in *ProjectRequest, opts ...grpc.CallOption) (*MultiGraphResponse, error)
	LogHistory(ctx context.Context, in *v02.LogRequest, opts ...grpc.CallOption) (*v02.LogResponse, error)
	GetActive(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ActiveResponse, error)
	GetAddresses(ctx context.Context, in *GetAddressRequest, opts ...grpc.CallOption) (*GetAddressResponse, error)
	GetSharedConfiguration(ctx context.Context, in *GetConfigurationRequest, opts ...grpc.CallOption) (*GetConfigurationResponse, error)
	Logs(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (CLI_LogsClient, error)
	ActiveLogHistory(ctx context.Context, in *v02.LogRequest, opts ...grpc.CallOption) (*v02.LogResponse, error)
	GetFlowStatus(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FlowStatus, error)
	StopFlow(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

CLIClient is the client API for CLI 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 NewCLIClient

func NewCLIClient(cc grpc.ClientConnInterface) CLIClient

type CLIServer

type CLIServer interface {
	Ping(context.Context, *emptypb.Empty) (*emptypb.Empty, error)
	GetAgentInformation(context.Context, *GetAgentInformationRequest) (*v0.AgentInformation, error)
	GetProjects(context.Context, *emptypb.Empty) (*GetProjectsResponse, error)
	GetProjectInventory(context.Context, *ProjectRequest) (*v01.Project, error)
	GetProjectServiceDependencyGraph(context.Context, *ProjectRequest) (*v02.GraphResponse, error)
	GetProjectPublicApplicationsDependencyGraph(context.Context, *ProjectRequest) (*MultiGraphResponse, error)
	LogHistory(context.Context, *v02.LogRequest) (*v02.LogResponse, error)
	GetActive(context.Context, *emptypb.Empty) (*ActiveResponse, error)
	GetAddresses(context.Context, *GetAddressRequest) (*GetAddressResponse, error)
	GetSharedConfiguration(context.Context, *GetConfigurationRequest) (*GetConfigurationResponse, error)
	Logs(*emptypb.Empty, CLI_LogsServer) error
	ActiveLogHistory(context.Context, *v02.LogRequest) (*v02.LogResponse, error)
	GetFlowStatus(context.Context, *emptypb.Empty) (*FlowStatus, error)
	StopFlow(context.Context, *emptypb.Empty) (*emptypb.Empty, error)
	// contains filtered or unexported methods
}

CLIServer is the server API for CLI service. All implementations must embed UnimplementedCLIServer for forward compatibility

type CLI_LogsClient

type CLI_LogsClient interface {
	Recv() (*v02.Log, error)
	grpc.ClientStream
}

type CLI_LogsServer

type CLI_LogsServer interface {
	Send(*v02.Log) error
	grpc.ServerStream
}

type FlowStatus

type FlowStatus struct {
	Ready bool `protobuf:"varint,1,opt,name=ready,proto3" json:"ready,omitempty"`
	// contains filtered or unexported fields
}

func (*FlowStatus) Descriptor deprecated

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

Deprecated: Use FlowStatus.ProtoReflect.Descriptor instead.

func (*FlowStatus) GetReady

func (x *FlowStatus) GetReady() bool

func (*FlowStatus) ProtoMessage

func (*FlowStatus) ProtoMessage()

func (*FlowStatus) ProtoReflect

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

func (*FlowStatus) Reset

func (x *FlowStatus) Reset()

func (*FlowStatus) String

func (x *FlowStatus) String() string

type GetAddressRequest

type GetAddressRequest struct {
	Application string `protobuf:"bytes,1,opt,name=application,proto3" json:"application,omitempty"`
	Service     string `protobuf:"bytes,2,opt,name=service,proto3" json:"service,omitempty"`
	Endpoint    string `protobuf:"bytes,3,opt,name=endpoint,proto3" json:"endpoint,omitempty"`
	// contains filtered or unexported fields
}

func (*GetAddressRequest) Descriptor deprecated

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

Deprecated: Use GetAddressRequest.ProtoReflect.Descriptor instead.

func (*GetAddressRequest) GetApplication

func (x *GetAddressRequest) GetApplication() string

func (*GetAddressRequest) GetEndpoint

func (x *GetAddressRequest) GetEndpoint() string

func (*GetAddressRequest) GetService

func (x *GetAddressRequest) GetService() string

func (*GetAddressRequest) ProtoMessage

func (*GetAddressRequest) ProtoMessage()

func (*GetAddressRequest) ProtoReflect

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

func (*GetAddressRequest) Reset

func (x *GetAddressRequest) Reset()

func (*GetAddressRequest) String

func (x *GetAddressRequest) String() string

type GetAddressResponse

type GetAddressResponse struct {
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// contains filtered or unexported fields
}

func (*GetAddressResponse) Descriptor deprecated

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

Deprecated: Use GetAddressResponse.ProtoReflect.Descriptor instead.

func (*GetAddressResponse) GetAddress

func (x *GetAddressResponse) GetAddress() string

func (*GetAddressResponse) ProtoMessage

func (*GetAddressResponse) ProtoMessage()

func (*GetAddressResponse) ProtoReflect

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

func (*GetAddressResponse) Reset

func (x *GetAddressResponse) Reset()

func (*GetAddressResponse) String

func (x *GetAddressResponse) String() string

type GetAgentInformationRequest

type GetAgentInformationRequest struct {
	Agent string `protobuf:"bytes,1,opt,name=agent,proto3" json:"agent,omitempty"`
	// contains filtered or unexported fields
}

func (*GetAgentInformationRequest) Descriptor deprecated

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

Deprecated: Use GetAgentInformationRequest.ProtoReflect.Descriptor instead.

func (*GetAgentInformationRequest) GetAgent

func (x *GetAgentInformationRequest) GetAgent() string

func (*GetAgentInformationRequest) ProtoMessage

func (*GetAgentInformationRequest) ProtoMessage()

func (*GetAgentInformationRequest) ProtoReflect

func (*GetAgentInformationRequest) Reset

func (x *GetAgentInformationRequest) Reset()

func (*GetAgentInformationRequest) String

func (x *GetAgentInformationRequest) String() string

type GetConfigurationRequest added in v0.1.62

type GetConfigurationRequest struct {
	Application string `protobuf:"bytes,1,opt,name=application,proto3" json:"application,omitempty"`
	Service     string `protobuf:"bytes,2,opt,name=service,proto3" json:"service,omitempty"`
	// contains filtered or unexported fields
}

func (*GetConfigurationRequest) Descriptor deprecated added in v0.1.62

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

Deprecated: Use GetConfigurationRequest.ProtoReflect.Descriptor instead.

func (*GetConfigurationRequest) GetApplication added in v0.1.62

func (x *GetConfigurationRequest) GetApplication() string

func (*GetConfigurationRequest) GetService added in v0.1.62

func (x *GetConfigurationRequest) GetService() string

func (*GetConfigurationRequest) ProtoMessage added in v0.1.62

func (*GetConfigurationRequest) ProtoMessage()

func (*GetConfigurationRequest) ProtoReflect added in v0.1.62

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

func (*GetConfigurationRequest) Reset added in v0.1.62

func (x *GetConfigurationRequest) Reset()

func (*GetConfigurationRequest) String added in v0.1.62

func (x *GetConfigurationRequest) String() string

type GetConfigurationResponse added in v0.1.62

type GetConfigurationResponse struct {
	Configurations []*v01.Configuration `protobuf:"bytes,1,rep,name=configurations,proto3" json:"configurations,omitempty"`
	// contains filtered or unexported fields
}

func (*GetConfigurationResponse) Descriptor deprecated added in v0.1.62

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

Deprecated: Use GetConfigurationResponse.ProtoReflect.Descriptor instead.

func (*GetConfigurationResponse) GetConfigurations added in v0.1.62

func (x *GetConfigurationResponse) GetConfigurations() []*v01.Configuration

func (*GetConfigurationResponse) ProtoMessage added in v0.1.62

func (*GetConfigurationResponse) ProtoMessage()

func (*GetConfigurationResponse) ProtoReflect added in v0.1.62

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

func (*GetConfigurationResponse) Reset added in v0.1.62

func (x *GetConfigurationResponse) Reset()

func (*GetConfigurationResponse) String added in v0.1.62

func (x *GetConfigurationResponse) String() string

type GetProjectsResponse

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

func (*GetProjectsResponse) Descriptor deprecated

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

Deprecated: Use GetProjectsResponse.ProtoReflect.Descriptor instead.

func (*GetProjectsResponse) GetProjects

func (x *GetProjectsResponse) GetProjects() []string

func (*GetProjectsResponse) ProtoMessage

func (*GetProjectsResponse) ProtoMessage()

func (*GetProjectsResponse) ProtoReflect

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

func (*GetProjectsResponse) Reset

func (x *GetProjectsResponse) Reset()

func (*GetProjectsResponse) String

func (x *GetProjectsResponse) String() string

type MultiGraphResponse

type MultiGraphResponse struct {
	Graphs []*v0.GraphResponse `protobuf:"bytes,1,rep,name=graphs,proto3" json:"graphs,omitempty"`
	// contains filtered or unexported fields
}

func (*MultiGraphResponse) Descriptor deprecated

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

Deprecated: Use MultiGraphResponse.ProtoReflect.Descriptor instead.

func (*MultiGraphResponse) GetGraphs

func (x *MultiGraphResponse) GetGraphs() []*v0.GraphResponse

func (*MultiGraphResponse) ProtoMessage

func (*MultiGraphResponse) ProtoMessage()

func (*MultiGraphResponse) ProtoReflect

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

func (*MultiGraphResponse) Reset

func (x *MultiGraphResponse) Reset()

func (*MultiGraphResponse) String

func (x *MultiGraphResponse) String() string

type ProjectRequest

type ProjectRequest struct {
	Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
	// contains filtered or unexported fields
}

func (*ProjectRequest) Descriptor deprecated

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

Deprecated: Use ProjectRequest.ProtoReflect.Descriptor instead.

func (*ProjectRequest) GetProject

func (x *ProjectRequest) GetProject() string

func (*ProjectRequest) ProtoMessage

func (*ProjectRequest) ProtoMessage()

func (*ProjectRequest) ProtoReflect

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

func (*ProjectRequest) Reset

func (x *ProjectRequest) Reset()

func (*ProjectRequest) String

func (x *ProjectRequest) String() string

type RunningInformation

type RunningInformation struct {
	Application string `protobuf:"bytes,1,opt,name=application,proto3" json:"application,omitempty"`
	Service     string `protobuf:"bytes,2,opt,name=service,proto3" json:"service,omitempty"`
	AgentPid    int32  `protobuf:"varint,3,opt,name=agent_pid,json=agentPid,proto3" json:"agent_pid,omitempty"`
	// contains filtered or unexported fields
}

func (*RunningInformation) Descriptor deprecated

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

Deprecated: Use RunningInformation.ProtoReflect.Descriptor instead.

func (*RunningInformation) GetAgentPid

func (x *RunningInformation) GetAgentPid() int32

func (*RunningInformation) GetApplication

func (x *RunningInformation) GetApplication() string

func (*RunningInformation) GetService

func (x *RunningInformation) GetService() string

func (*RunningInformation) ProtoMessage

func (*RunningInformation) ProtoMessage()

func (*RunningInformation) ProtoReflect

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

func (*RunningInformation) Reset

func (x *RunningInformation) Reset()

func (*RunningInformation) String

func (x *RunningInformation) String() string

type UnimplementedCLIServer

type UnimplementedCLIServer struct {
}

UnimplementedCLIServer must be embedded to have forward compatible implementations.

func (UnimplementedCLIServer) ActiveLogHistory

func (UnimplementedCLIServer) GetActive

func (UnimplementedCLIServer) GetAddresses

func (UnimplementedCLIServer) GetAgentInformation

func (UnimplementedCLIServer) GetFlowStatus

func (UnimplementedCLIServer) GetProjectInventory

func (UnimplementedCLIServer) GetProjectPublicApplicationsDependencyGraph

func (UnimplementedCLIServer) GetProjectPublicApplicationsDependencyGraph(context.Context, *ProjectRequest) (*MultiGraphResponse, error)

func (UnimplementedCLIServer) GetProjectServiceDependencyGraph

func (UnimplementedCLIServer) GetProjectServiceDependencyGraph(context.Context, *ProjectRequest) (*v02.GraphResponse, error)

func (UnimplementedCLIServer) GetProjects

func (UnimplementedCLIServer) GetSharedConfiguration added in v0.1.62

func (UnimplementedCLIServer) LogHistory

func (UnimplementedCLIServer) Logs

func (UnimplementedCLIServer) Ping

func (UnimplementedCLIServer) StopFlow

type UnsafeCLIServer

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

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

Jump to

Keyboard shortcuts

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