definition

package
v0.0.0-...-7f2974b Latest Latest
Warning

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

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

Documentation

Overview

Package definition is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var (
	ArangoDBMode_name = map[int32]string{
		0: "Single",
		1: "ActiveFailover",
		2: "Cluster",
	}
	ArangoDBMode_value = map[string]int32{
		"Single":         0,
		"ActiveFailover": 1,
		"Cluster":        2,
	}
)

Enum value maps for ArangoDBMode.

View Source
var (
	ArangoDBEdition_name = map[int32]string{
		0: "Community",
		1: "Enterprise",
	}
	ArangoDBEdition_value = map[string]int32{
		"Community":  0,
		"Enterprise": 1,
	}
)

Enum value maps for ArangoDBEdition.

View Source
var (
	ArangoDBSharding_name = map[int32]string{
		0: "Sharded",
		1: "OneShardEnforced",
	}
	ArangoDBSharding_value = map[string]int32{
		"Sharded":          0,
		"OneShardEnforced": 1,
	}
)

Enum value maps for ArangoDBSharding.

View Source
var File_integrations_inventory_v1_definition_inventory_proto protoreflect.FileDescriptor
View Source
var File_integrations_inventory_v1_definition_service_proto protoreflect.FileDescriptor
View Source
var InventoryV1_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "inventory.InventoryV1",
	HandlerType: (*InventoryV1Server)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Inventory",
			Handler:    _InventoryV1_Inventory_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "integrations/inventory/v1/definition/service.proto",
}

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

Functions

func RegisterInventoryV1Handler

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

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

func RegisterInventoryV1HandlerClient

func RegisterInventoryV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client InventoryV1Client) error

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

func RegisterInventoryV1HandlerFromEndpoint

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

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

func RegisterInventoryV1HandlerServer

func RegisterInventoryV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server InventoryV1Server) error

RegisterInventoryV1HandlerServer registers the http handlers for service InventoryV1 to "mux". UnaryRPC :call InventoryV1Server 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 RegisterInventoryV1HandlerFromEndpoint instead. GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call.

func RegisterInventoryV1Server

func RegisterInventoryV1Server(s grpc.ServiceRegistrar, srv InventoryV1Server)

Types

type ArangoDBConfiguration

type ArangoDBConfiguration struct {

	// ArangoDB Deployment Mode
	Mode ArangoDBMode `protobuf:"varint,1,opt,name=mode,proto3,enum=inventory.ArangoDBMode" json:"mode,omitempty"`
	// ArangoDB Deployment Edition
	Edition ArangoDBEdition `protobuf:"varint,2,opt,name=edition,proto3,enum=inventory.ArangoDBEdition" json:"edition,omitempty"`
	// ArangoDB Deployment Version
	Version string `protobuf:"bytes,3,opt,name=version,proto3" json:"version,omitempty"`
	// ArangoDB Sharding Mode
	Sharding ArangoDBSharding `protobuf:"varint,4,opt,name=sharding,proto3,enum=inventory.ArangoDBSharding" json:"sharding,omitempty"`
	// contains filtered or unexported fields
}

ArangoDB Deployment Configuration

func NewArangoDBConfiguration

func NewArangoDBConfiguration(spec api.DeploymentSpec, status api.DeploymentStatus) *ArangoDBConfiguration

func (*ArangoDBConfiguration) Descriptor deprecated

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

Deprecated: Use ArangoDBConfiguration.ProtoReflect.Descriptor instead.

func (*ArangoDBConfiguration) GetEdition

func (x *ArangoDBConfiguration) GetEdition() ArangoDBEdition

func (*ArangoDBConfiguration) GetMode

func (x *ArangoDBConfiguration) GetMode() ArangoDBMode

func (*ArangoDBConfiguration) GetSharding

func (x *ArangoDBConfiguration) GetSharding() ArangoDBSharding

func (*ArangoDBConfiguration) GetVersion

func (x *ArangoDBConfiguration) GetVersion() string

func (*ArangoDBConfiguration) ProtoMessage

func (*ArangoDBConfiguration) ProtoMessage()

func (*ArangoDBConfiguration) ProtoReflect

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

func (*ArangoDBConfiguration) Reset

func (x *ArangoDBConfiguration) Reset()

func (*ArangoDBConfiguration) String

func (x *ArangoDBConfiguration) String() string

type ArangoDBEdition

type ArangoDBEdition int32

ArangoDB Deployment Edition

const (
	// Community Edition
	ArangoDBEdition_Community ArangoDBEdition = 0
	// Enterprise Edition
	ArangoDBEdition_Enterprise ArangoDBEdition = 1
)

func (ArangoDBEdition) Descriptor

func (ArangoDBEdition) Enum

func (x ArangoDBEdition) Enum() *ArangoDBEdition

func (ArangoDBEdition) EnumDescriptor deprecated

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

Deprecated: Use ArangoDBEdition.Descriptor instead.

func (ArangoDBEdition) Number

func (ArangoDBEdition) String

func (x ArangoDBEdition) String() string

func (ArangoDBEdition) Type

type ArangoDBMode

type ArangoDBMode int32

ArangoDB Deployment Mode

const (
	// Single Mode
	ArangoDBMode_Single ArangoDBMode = 0
	// ActiveFailover Mode
	ArangoDBMode_ActiveFailover ArangoDBMode = 1
	// Cluster Mode
	ArangoDBMode_Cluster ArangoDBMode = 2
)

func (ArangoDBMode) Descriptor

func (ArangoDBMode) Enum

func (x ArangoDBMode) Enum() *ArangoDBMode

func (ArangoDBMode) EnumDescriptor deprecated

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

Deprecated: Use ArangoDBMode.Descriptor instead.

func (ArangoDBMode) Number

func (ArangoDBMode) String

func (x ArangoDBMode) String() string

func (ArangoDBMode) Type

type ArangoDBSharding

type ArangoDBSharding int32

ArangoDB Sharding Mode

const (
	// Sharded Sharding Mode
	ArangoDBSharding_Sharded ArangoDBSharding = 0
	// OneShardEnforced Sharding Mode
	ArangoDBSharding_OneShardEnforced ArangoDBSharding = 1
)

func (ArangoDBSharding) Descriptor

func (ArangoDBSharding) Enum

func (ArangoDBSharding) EnumDescriptor deprecated

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

Deprecated: Use ArangoDBSharding.Descriptor instead.

func (ArangoDBSharding) Number

func (ArangoDBSharding) String

func (x ArangoDBSharding) String() string

func (ArangoDBSharding) Type

type Inventory

type Inventory struct {

	// Current Envoy Configuration details
	Configuration *InventoryConfiguration `protobuf:"bytes,1,opt,name=configuration,proto3,oneof" json:"configuration,omitempty"`
	// ArangoDB Deployment Configuration
	Arangodb *ArangoDBConfiguration `protobuf:"bytes,2,opt,name=arangodb,proto3,oneof" json:"arangodb,omitempty"`
	// contains filtered or unexported fields
}

Platform Inventory

func (*Inventory) Descriptor deprecated

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

Deprecated: Use Inventory.ProtoReflect.Descriptor instead.

func (*Inventory) GetArangodb

func (x *Inventory) GetArangodb() *ArangoDBConfiguration

func (*Inventory) GetConfiguration

func (x *Inventory) GetConfiguration() *InventoryConfiguration

func (*Inventory) JSON

func (s *Inventory) JSON() ([]byte, error)

func (*Inventory) ProtoMessage

func (*Inventory) ProtoMessage()

func (*Inventory) ProtoReflect

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

func (*Inventory) Reset

func (x *Inventory) Reset()

func (*Inventory) String

func (x *Inventory) String() string

type InventoryConfiguration

type InventoryConfiguration struct {

	// Configuration hash
	Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
	// contains filtered or unexported fields
}

Envoy Configuration details

func (*InventoryConfiguration) Descriptor deprecated

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

Deprecated: Use InventoryConfiguration.ProtoReflect.Descriptor instead.

func (*InventoryConfiguration) GetHash

func (x *InventoryConfiguration) GetHash() string

func (*InventoryConfiguration) ProtoMessage

func (*InventoryConfiguration) ProtoMessage()

func (*InventoryConfiguration) ProtoReflect

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

func (*InventoryConfiguration) Reset

func (x *InventoryConfiguration) Reset()

func (*InventoryConfiguration) String

func (x *InventoryConfiguration) String() string

type InventoryV1Client

type InventoryV1Client interface {
	// Inventory returns current State
	Inventory(ctx context.Context, in *definition.Empty, opts ...grpc.CallOption) (*Inventory, error)
}

InventoryV1Client is the client API for InventoryV1 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.

type InventoryV1Server

type InventoryV1Server interface {
	// Inventory returns current State
	Inventory(context.Context, *definition.Empty) (*Inventory, error)
	// contains filtered or unexported methods
}

InventoryV1Server is the server API for InventoryV1 service. All implementations must embed UnimplementedInventoryV1Server for forward compatibility

type UnimplementedInventoryV1Server

type UnimplementedInventoryV1Server struct {
}

UnimplementedInventoryV1Server must be embedded to have forward compatible implementations.

func (UnimplementedInventoryV1Server) Inventory

type UnsafeInventoryV1Server

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

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

Jump to

Keyboard shortcuts

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