datapathplugins

package
v1.20.0-pre.3 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

README

Protocol Documentation

Table of Contents

Top

datapathplugins/datapathplugins.proto

AttachmentContext

AttachmentContext contains the context about the attachment point in question. It may carry endpoint-specific information used to determine which hooks to load or how to configure them.

Field Type Label Description
host AttachmentContext.Host
lxc AttachmentContext.LXC
overlay AttachmentContext.Overlay
socket AttachmentContext.Socket
wireguard AttachmentContext.Wireguard
xdp AttachmentContext.XDP

AttachmentContext.Host

attachment context for bpf_host (netdev, cilium_host, cilium_net).

Field Type Label Description
iface AttachmentContext.InterfaceInfo interface that is being configured.

AttachmentContext.InterfaceInfo

InterfaceInfo contains information about a network interface.

Field Type Label Description
name string name of the network interface.

AttachmentContext.LXC

attachment context for bpf_lxc (containers).

Field Type Label Description
iface AttachmentContext.InterfaceInfo interface that is being configured.
pod_info AttachmentContext.PodInfo pod that is being configured.

AttachmentContext.Overlay

attachment context for bpf_overlay (vxlan/geneve).

Field Type Label Description
iface AttachmentContext.InterfaceInfo interface that is being configured.

AttachmentContext.PodInfo

PodInfo contains information about a pod.

Field Type Label Description
namespace string pod namespace.
name string pod name.
container_name string container name.

AttachmentContext.Socket

attachment context for bpf_sock (connect4,bind4,...)

AttachmentContext.Wireguard

attachment context for bpf_wireguard (cilium_wg)

Field Type Label Description
iface AttachmentContext.InterfaceInfo interface that is being configured.

AttachmentContext.XDP

attachment context for bpf_xdp (netdev)

Field Type Label Description
iface AttachmentContext.InterfaceInfo interface that is being configured.

InstrumentCollectionRequest

Phase 2: Cilium has constructed and loaded the collection along with any dispatcher programs that are meant to replace existing entrypoints in the collection. Cilium sends a round of requests to any plugins that wanted to inject hooks in the prepare phase.

Field Type Label Description
collection InstrumentCollectionRequest.Collection
attachment_context AttachmentContext
config google.protobuf.Any config contains datapath configuration for this collection.
hooks InstrumentCollectionRequest.Hook repeated list of hooks corresponding with those specified by the plugin in its PrepareHooks response.
pins string an ephemeral per-request bpffs directory where a plugin can pin an arbitrary set of objects. The lifecycle of these pins will be bound to that of the attachment context. This is useful especially in cases where the plugin loads its own set of tail call programs accessible from the entrypoint hook program and want to make sure a PROG_ARRAY and the programs it contains remain intact even after the InstrumentCollection request returns.
cookie string cookie matches the cookie provided in the plugin's PrepareHooks response.

InstrumentCollectionRequest.Collection

Program and map IDs in the collection

Field Type Label Description
programs InstrumentCollectionRequest.Collection.ProgramsEntry repeated program details for each programs in the collection.
maps InstrumentCollectionRequest.Collection.MapsEntry repeated map details for each map in the collection.

InstrumentCollectionRequest.Collection.Map
Field Type Label Description
id uint32

InstrumentCollectionRequest.Collection.MapsEntry
Field Type Label Description
key string
value InstrumentCollectionRequest.Collection.Map

InstrumentCollectionRequest.Collection.Program
Field Type Label Description
id uint32

InstrumentCollectionRequest.Collection.ProgramsEntry
Field Type Label Description
key string
value InstrumentCollectionRequest.Collection.Program

InstrumentCollectionRequest.Hook
Field Type Label Description
type HookType position of the hook relative to the target program.
target string name of the program that should be instrumented.
attach_target InstrumentCollectionRequest.Hook.AttachTarget info necessary for loading freplace programs.
pin_path string plugin must pin the hook program to this pin path before responding to Cilium.

InstrumentCollectionRequest.Hook.AttachTarget
Field Type Label Description
program_id uint32 id of the target program.
subprog_name string name of the hook's subprogram inside the target program.

InstrumentCollectionResponse

PrepareCollectionRequest

Phase 1: As Cilium loads and prepares a collection for a particular attachment point, it sends a PrepareHooksRequest to each plugin with context about the attachment point, collection, and its configuration. The plugin decides which hooks it would like to insert, where it would like to insert them, and informs Cilium in the PrepareHooksResponse.

Field Type Label Description
collection PrepareCollectionRequest.CollectionSpec
attachment_context AttachmentContext
config google.protobuf.Any config contains datapath configuration for this collection.

PrepareCollectionRequest.CollectionSpec
Field Type Label Description
programs PrepareCollectionRequest.CollectionSpec.ProgramsEntry repeated program details for each programs in the collection.
maps PrepareCollectionRequest.CollectionSpec.MapsEntry repeated map details for each map in the collection.

PrepareCollectionRequest.CollectionSpec.MapSpec
Field Type Label Description
type uint32
key_size uint32
value_size uint32
max_entries uint32
flags uint32
pin_type uint32

PrepareCollectionRequest.CollectionSpec.MapsEntry
Field Type Label Description
key string
value PrepareCollectionRequest.CollectionSpec.MapSpec

PrepareCollectionRequest.CollectionSpec.ProgramSpec
Field Type Label Description
type uint32
attach_type uint32
section_name string
license string

PrepareCollectionRequest.CollectionSpec.ProgramsEntry
Field Type Label Description
key string
value PrepareCollectionRequest.CollectionSpec.ProgramSpec

PrepareCollectionResponse
Field Type Label Description
hooks PrepareCollectionResponse.HookSpec repeated list of hooks that should be added to the collection.
cookie string cookie is an opaque string that will be passed in the subsequent InstrumentCollectionRequest related to this PrepareCollectionRequest. It may be used by plugins to associate the two requests or carry metadata between them.

PrepareCollectionResponse.HookSpec
Field Type Label Description
type HookType position of the hook relative to the target program.
target string name of the program that should be instrumented.
constraints PrepareCollectionResponse.HookSpec.OrderingConstraint repeated constraints is a list of ordering constraints for this hook. If other plugins want to place a hook at this same hook point, hooks from various plugins will be arranged in an order that respects all ordering constraints.

PrepareCollectionResponse.HookSpec.OrderingConstraint

An OrderingConstraint is a constraint about where this hook should go at this hook point relative to other plugins' hooks.

Field Type Label Description
order PrepareCollectionResponse.HookSpec.OrderingConstraint.Order
plugin string

HookType
Name Number Description
UNKNOWN 0
PRE 1 pre hooks run before the main Cilium program.
POST 2 post hooks run after the main Cilium program.

PrepareCollectionResponse.HookSpec.OrderingConstraint.Order
Name Number Description
UNKNOWN 0
BEFORE 1
AFTER 2

DatapathPlugin

A DatapathPlugin interacts with Cilium's loader to augment or modify BPF collections as they are prepared for an attachment point.

Method Name Request Type Response Type Description
PrepareCollection PrepareCollectionRequest PrepareCollectionResponse PrepareCollection happens before the BPF collection is loaded into the kernel. Cilium passes BPF collection details to the plugin and the plugin tells Cilium how it would like to modify the collection.
InstrumentCollection InstrumentCollectionRequest InstrumentCollectionResponse InstrumentCollection happens after the BPF collection is loaded into the kernel. Cilium passes BPF collection details to the plugin along with details about hook attachment points it created in the prepare phase. The plugin loads its BPF programs and passes them back to Cilium to be attached to these hook points.

Scalar Value Types

.proto Type Notes C++ Java Python Go C# PHP Ruby
double double double float float64 double float Float
float float float float float32 float float Float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int int32 int integer Bignum or Fixnum (as required)
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long int64 long integer/string Bignum
uint32 Uses variable-length encoding. uint32 int int/long uint32 uint integer Bignum or Fixnum (as required)
uint64 Uses variable-length encoding. uint64 long int/long uint64 ulong integer/string Bignum or Fixnum (as required)
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int int32 int integer Bignum or Fixnum (as required)
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long int64 long integer/string Bignum
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int uint32 uint integer Bignum or Fixnum (as required)
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long uint64 ulong integer/string Bignum
sfixed32 Always four bytes. int32 int int int32 int integer Bignum or Fixnum (as required)
sfixed64 Always eight bytes. int64 long int/long int64 long integer/string Bignum
bool bool boolean boolean bool bool boolean TrueClass/FalseClass
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode string string string String (UTF-8)
bytes May contain any arbitrary sequence of bytes. string ByteString str []byte ByteString string String (ASCII-8BIT)

Documentation

Index

Constants

View Source
const (
	DatapathPlugin_PrepareCollection_FullMethodName    = "/datapathplugins.DatapathPlugin/PrepareCollection"
	DatapathPlugin_InstrumentCollection_FullMethodName = "/datapathplugins.DatapathPlugin/InstrumentCollection"
)

Variables

View Source
var (
	HookType_name = map[int32]string{
		0: "UNKNOWN",
		1: "PRE",
		2: "POST",
	}
	HookType_value = map[string]int32{
		"UNKNOWN": 0,
		"PRE":     1,
		"POST":    2,
	}
)

Enum value maps for HookType.

View Source
var (
	PrepareCollectionResponse_HookSpec_OrderingConstraint_Order_name = map[int32]string{
		0: "UNKNOWN",
		1: "BEFORE",
		2: "AFTER",
	}
	PrepareCollectionResponse_HookSpec_OrderingConstraint_Order_value = map[string]int32{
		"UNKNOWN": 0,
		"BEFORE":  1,
		"AFTER":   2,
	}
)

Enum value maps for PrepareCollectionResponse_HookSpec_OrderingConstraint_Order.

View Source
var DatapathPlugin_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "datapathplugins.DatapathPlugin",
	HandlerType: (*DatapathPluginServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "PrepareCollection",
			Handler:    _DatapathPlugin_PrepareCollection_Handler,
		},
		{
			MethodName: "InstrumentCollection",
			Handler:    _DatapathPlugin_InstrumentCollection_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "datapathplugins/datapathplugins.proto",
}

DatapathPlugin_ServiceDesc is the grpc.ServiceDesc for DatapathPlugin 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_datapathplugins_datapathplugins_proto protoreflect.FileDescriptor

Functions

func RegisterDatapathPluginServer

func RegisterDatapathPluginServer(s grpc.ServiceRegistrar, srv DatapathPluginServer)

Types

type AttachmentContext

type AttachmentContext struct {

	// Types that are valid to be assigned to Context:
	//
	//	*AttachmentContext_Host_
	//	*AttachmentContext_Lxc
	//	*AttachmentContext_Overlay_
	//	*AttachmentContext_Socket_
	//	*AttachmentContext_Wireguard_
	//	*AttachmentContext_Xdp
	Context isAttachmentContext_Context `protobuf_oneof:"context"`
	// contains filtered or unexported fields
}

AttachmentContext contains the context about the attachment point in question. It may carry endpoint-specific information used to determine which hooks to load or how to configure them.

func (*AttachmentContext) Descriptor deprecated

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

Deprecated: Use AttachmentContext.ProtoReflect.Descriptor instead.

func (*AttachmentContext) GetContext

func (x *AttachmentContext) GetContext() isAttachmentContext_Context

func (*AttachmentContext) GetHost

func (*AttachmentContext) GetLxc

func (*AttachmentContext) GetOverlay

func (*AttachmentContext) GetSocket

func (*AttachmentContext) GetWireguard

func (*AttachmentContext) GetXdp

func (*AttachmentContext) MarshalJSON

func (msg *AttachmentContext) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext) ProtoMessage

func (*AttachmentContext) ProtoMessage()

func (*AttachmentContext) ProtoReflect

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

func (*AttachmentContext) Reset

func (x *AttachmentContext) Reset()

func (*AttachmentContext) String

func (x *AttachmentContext) String() string

func (*AttachmentContext) UnmarshalJSON

func (msg *AttachmentContext) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Host

type AttachmentContext_Host struct {

	// interface that is being configured.
	Iface *AttachmentContext_InterfaceInfo `protobuf:"bytes,1,opt,name=iface,proto3" json:"iface,omitempty"`
	// contains filtered or unexported fields
}

attachment context for bpf_host (netdev, cilium_host, cilium_net).

func (*AttachmentContext_Host) Descriptor deprecated

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

Deprecated: Use AttachmentContext_Host.ProtoReflect.Descriptor instead.

func (*AttachmentContext_Host) GetIface

func (*AttachmentContext_Host) MarshalJSON

func (msg *AttachmentContext_Host) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_Host) ProtoMessage

func (*AttachmentContext_Host) ProtoMessage()

func (*AttachmentContext_Host) ProtoReflect

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

func (*AttachmentContext_Host) Reset

func (x *AttachmentContext_Host) Reset()

func (*AttachmentContext_Host) String

func (x *AttachmentContext_Host) String() string

func (*AttachmentContext_Host) UnmarshalJSON

func (msg *AttachmentContext_Host) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Host_

type AttachmentContext_Host_ struct {
	Host *AttachmentContext_Host `protobuf:"bytes,1,opt,name=host,proto3,oneof"`
}

type AttachmentContext_InterfaceInfo

type AttachmentContext_InterfaceInfo struct {

	// name of the network interface.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

InterfaceInfo contains information about a network interface.

func (*AttachmentContext_InterfaceInfo) Descriptor deprecated

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

Deprecated: Use AttachmentContext_InterfaceInfo.ProtoReflect.Descriptor instead.

func (*AttachmentContext_InterfaceInfo) GetName

func (*AttachmentContext_InterfaceInfo) MarshalJSON

func (msg *AttachmentContext_InterfaceInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_InterfaceInfo) ProtoMessage

func (*AttachmentContext_InterfaceInfo) ProtoMessage()

func (*AttachmentContext_InterfaceInfo) ProtoReflect

func (*AttachmentContext_InterfaceInfo) Reset

func (*AttachmentContext_InterfaceInfo) String

func (*AttachmentContext_InterfaceInfo) UnmarshalJSON

func (msg *AttachmentContext_InterfaceInfo) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_LXC

type AttachmentContext_LXC struct {

	// interface that is being configured.
	Iface *AttachmentContext_InterfaceInfo `protobuf:"bytes,1,opt,name=iface,proto3" json:"iface,omitempty"`
	// pod that is being configured.
	PodInfo *AttachmentContext_PodInfo `protobuf:"bytes,2,opt,name=pod_info,json=podInfo,proto3" json:"pod_info,omitempty"`
	// contains filtered or unexported fields
}

attachment context for bpf_lxc (containers).

func (*AttachmentContext_LXC) Descriptor deprecated

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

Deprecated: Use AttachmentContext_LXC.ProtoReflect.Descriptor instead.

func (*AttachmentContext_LXC) GetIface

func (*AttachmentContext_LXC) GetPodInfo

func (*AttachmentContext_LXC) MarshalJSON

func (msg *AttachmentContext_LXC) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_LXC) ProtoMessage

func (*AttachmentContext_LXC) ProtoMessage()

func (*AttachmentContext_LXC) ProtoReflect

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

func (*AttachmentContext_LXC) Reset

func (x *AttachmentContext_LXC) Reset()

func (*AttachmentContext_LXC) String

func (x *AttachmentContext_LXC) String() string

func (*AttachmentContext_LXC) UnmarshalJSON

func (msg *AttachmentContext_LXC) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Lxc

type AttachmentContext_Lxc struct {
	Lxc *AttachmentContext_LXC `protobuf:"bytes,2,opt,name=lxc,proto3,oneof"`
}

type AttachmentContext_Overlay

type AttachmentContext_Overlay struct {

	// interface that is being configured.
	Iface *AttachmentContext_InterfaceInfo `protobuf:"bytes,1,opt,name=iface,proto3" json:"iface,omitempty"`
	// contains filtered or unexported fields
}

attachment context for bpf_overlay (vxlan/geneve).

func (*AttachmentContext_Overlay) Descriptor deprecated

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

Deprecated: Use AttachmentContext_Overlay.ProtoReflect.Descriptor instead.

func (*AttachmentContext_Overlay) GetIface

func (*AttachmentContext_Overlay) MarshalJSON

func (msg *AttachmentContext_Overlay) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_Overlay) ProtoMessage

func (*AttachmentContext_Overlay) ProtoMessage()

func (*AttachmentContext_Overlay) ProtoReflect

func (*AttachmentContext_Overlay) Reset

func (x *AttachmentContext_Overlay) Reset()

func (*AttachmentContext_Overlay) String

func (x *AttachmentContext_Overlay) String() string

func (*AttachmentContext_Overlay) UnmarshalJSON

func (msg *AttachmentContext_Overlay) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Overlay_

type AttachmentContext_Overlay_ struct {
	Overlay *AttachmentContext_Overlay `protobuf:"bytes,3,opt,name=overlay,proto3,oneof"`
}

type AttachmentContext_PodInfo

type AttachmentContext_PodInfo struct {

	// pod namespace.
	Namespace string `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace,omitempty"`
	// pod name.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// container name.
	ContainerName string `protobuf:"bytes,3,opt,name=container_name,json=containerName,proto3" json:"container_name,omitempty"`
	// contains filtered or unexported fields
}

PodInfo contains information about a pod.

func (*AttachmentContext_PodInfo) Descriptor deprecated

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

Deprecated: Use AttachmentContext_PodInfo.ProtoReflect.Descriptor instead.

func (*AttachmentContext_PodInfo) GetContainerName

func (x *AttachmentContext_PodInfo) GetContainerName() string

func (*AttachmentContext_PodInfo) GetName

func (x *AttachmentContext_PodInfo) GetName() string

func (*AttachmentContext_PodInfo) GetNamespace

func (x *AttachmentContext_PodInfo) GetNamespace() string

func (*AttachmentContext_PodInfo) MarshalJSON

func (msg *AttachmentContext_PodInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_PodInfo) ProtoMessage

func (*AttachmentContext_PodInfo) ProtoMessage()

func (*AttachmentContext_PodInfo) ProtoReflect

func (*AttachmentContext_PodInfo) Reset

func (x *AttachmentContext_PodInfo) Reset()

func (*AttachmentContext_PodInfo) String

func (x *AttachmentContext_PodInfo) String() string

func (*AttachmentContext_PodInfo) UnmarshalJSON

func (msg *AttachmentContext_PodInfo) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Socket

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

attachment context for bpf_sock (connect4,bind4,...)

func (*AttachmentContext_Socket) Descriptor deprecated

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

Deprecated: Use AttachmentContext_Socket.ProtoReflect.Descriptor instead.

func (*AttachmentContext_Socket) MarshalJSON

func (msg *AttachmentContext_Socket) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_Socket) ProtoMessage

func (*AttachmentContext_Socket) ProtoMessage()

func (*AttachmentContext_Socket) ProtoReflect

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

func (*AttachmentContext_Socket) Reset

func (x *AttachmentContext_Socket) Reset()

func (*AttachmentContext_Socket) String

func (x *AttachmentContext_Socket) String() string

func (*AttachmentContext_Socket) UnmarshalJSON

func (msg *AttachmentContext_Socket) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Socket_

type AttachmentContext_Socket_ struct {
	Socket *AttachmentContext_Socket `protobuf:"bytes,4,opt,name=socket,proto3,oneof"`
}

type AttachmentContext_Wireguard

type AttachmentContext_Wireguard struct {

	// interface that is being configured.
	Iface *AttachmentContext_InterfaceInfo `protobuf:"bytes,1,opt,name=iface,proto3" json:"iface,omitempty"`
	// contains filtered or unexported fields
}

attachment context for bpf_wireguard (cilium_wg)

func (*AttachmentContext_Wireguard) Descriptor deprecated

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

Deprecated: Use AttachmentContext_Wireguard.ProtoReflect.Descriptor instead.

func (*AttachmentContext_Wireguard) GetIface

func (*AttachmentContext_Wireguard) MarshalJSON

func (msg *AttachmentContext_Wireguard) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_Wireguard) ProtoMessage

func (*AttachmentContext_Wireguard) ProtoMessage()

func (*AttachmentContext_Wireguard) ProtoReflect

func (*AttachmentContext_Wireguard) Reset

func (x *AttachmentContext_Wireguard) Reset()

func (*AttachmentContext_Wireguard) String

func (x *AttachmentContext_Wireguard) String() string

func (*AttachmentContext_Wireguard) UnmarshalJSON

func (msg *AttachmentContext_Wireguard) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Wireguard_

type AttachmentContext_Wireguard_ struct {
	Wireguard *AttachmentContext_Wireguard `protobuf:"bytes,5,opt,name=wireguard,proto3,oneof"`
}

type AttachmentContext_XDP

type AttachmentContext_XDP struct {

	// interface that is being configured.
	Iface *AttachmentContext_InterfaceInfo `protobuf:"bytes,1,opt,name=iface,proto3" json:"iface,omitempty"`
	// contains filtered or unexported fields
}

attachment context for bpf_xdp (netdev)

func (*AttachmentContext_XDP) Descriptor deprecated

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

Deprecated: Use AttachmentContext_XDP.ProtoReflect.Descriptor instead.

func (*AttachmentContext_XDP) GetIface

func (*AttachmentContext_XDP) MarshalJSON

func (msg *AttachmentContext_XDP) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*AttachmentContext_XDP) ProtoMessage

func (*AttachmentContext_XDP) ProtoMessage()

func (*AttachmentContext_XDP) ProtoReflect

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

func (*AttachmentContext_XDP) Reset

func (x *AttachmentContext_XDP) Reset()

func (*AttachmentContext_XDP) String

func (x *AttachmentContext_XDP) String() string

func (*AttachmentContext_XDP) UnmarshalJSON

func (msg *AttachmentContext_XDP) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type AttachmentContext_Xdp

type AttachmentContext_Xdp struct {
	Xdp *AttachmentContext_XDP `protobuf:"bytes,6,opt,name=xdp,proto3,oneof"`
}

type DatapathPluginClient

type DatapathPluginClient interface {
	// PrepareCollection happens before the BPF collection is loaded into the
	// kernel. Cilium passes BPF collection details to the plugin and the plugin
	// tells Cilium how it would like to modify the collection.
	PrepareCollection(ctx context.Context, in *PrepareCollectionRequest, opts ...grpc.CallOption) (*PrepareCollectionResponse, error)
	// InstrumentCollection happens after the BPF collection is loaded into the
	// kernel. Cilium passes BPF collection details to the plugin along with
	// details about hook attachment points it created in the prepare phase.
	// The plugin loads its BPF programs and passes them back to Cilium to be
	// attached to these hook points.
	InstrumentCollection(ctx context.Context, in *InstrumentCollectionRequest, opts ...grpc.CallOption) (*InstrumentCollectionResponse, error)
}

DatapathPluginClient is the client API for DatapathPlugin 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.

A DatapathPlugin interacts with Cilium's loader to augment or modify BPF collections as they are prepared for an attachment point.

type DatapathPluginServer

type DatapathPluginServer interface {
	// PrepareCollection happens before the BPF collection is loaded into the
	// kernel. Cilium passes BPF collection details to the plugin and the plugin
	// tells Cilium how it would like to modify the collection.
	PrepareCollection(context.Context, *PrepareCollectionRequest) (*PrepareCollectionResponse, error)
	// InstrumentCollection happens after the BPF collection is loaded into the
	// kernel. Cilium passes BPF collection details to the plugin along with
	// details about hook attachment points it created in the prepare phase.
	// The plugin loads its BPF programs and passes them back to Cilium to be
	// attached to these hook points.
	InstrumentCollection(context.Context, *InstrumentCollectionRequest) (*InstrumentCollectionResponse, error)
}

DatapathPluginServer is the server API for DatapathPlugin service. All implementations should embed UnimplementedDatapathPluginServer for forward compatibility.

A DatapathPlugin interacts with Cilium's loader to augment or modify BPF collections as they are prepared for an attachment point.

type HookType

type HookType int32
const (
	HookType_UNKNOWN HookType = 0
	// pre hooks run before the main Cilium program.
	HookType_PRE HookType = 1
	// post hooks run after the main Cilium program.
	HookType_POST HookType = 2
)

func (HookType) Descriptor

func (HookType) Descriptor() protoreflect.EnumDescriptor

func (HookType) Enum

func (x HookType) Enum() *HookType

func (HookType) EnumDescriptor deprecated

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

Deprecated: Use HookType.Descriptor instead.

func (HookType) Number

func (x HookType) Number() protoreflect.EnumNumber

func (HookType) String

func (x HookType) String() string

func (HookType) Type

type InstrumentCollectionRequest

type InstrumentCollectionRequest struct {
	Collection        *InstrumentCollectionRequest_Collection `protobuf:"bytes,1,opt,name=collection,proto3" json:"collection,omitempty"`
	AttachmentContext *AttachmentContext                      `protobuf:"bytes,2,opt,name=attachment_context,json=attachmentContext,proto3" json:"attachment_context,omitempty"`
	// config contains datapath configuration for this collection.
	Config *anypb.Any `protobuf:"bytes,3,opt,name=config,proto3" json:"config,omitempty"`
	// list of hooks corresponding with those specified by the plugin in its
	// PrepareHooks response.
	Hooks []*InstrumentCollectionRequest_Hook `protobuf:"bytes,4,rep,name=hooks,proto3" json:"hooks,omitempty"`
	// an ephemeral per-request bpffs directory where a plugin can pin an
	// arbitrary set of objects. The lifecycle of these pins will be bound to
	// that of the attachment context. This is useful especially in cases where
	// the plugin loads its own set of tail call programs accessible from the
	// entrypoint hook program and want to make sure a PROG_ARRAY and the
	// programs it contains remain intact even after the InstrumentCollection
	// request returns.
	Pins string `protobuf:"bytes,5,opt,name=pins,proto3" json:"pins,omitempty"`
	// cookie matches the cookie provided in the plugin's PrepareHooks response.
	Cookie string `protobuf:"bytes,6,opt,name=cookie,proto3" json:"cookie,omitempty"`
	// contains filtered or unexported fields
}

Phase 2: Cilium has constructed and loaded the collection along with any dispatcher programs that are meant to replace existing entrypoints in the collection. Cilium sends a round of requests to any plugins that wanted to inject hooks in the prepare phase.

func (*InstrumentCollectionRequest) Descriptor deprecated

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

Deprecated: Use InstrumentCollectionRequest.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest) GetAttachmentContext

func (x *InstrumentCollectionRequest) GetAttachmentContext() *AttachmentContext

func (*InstrumentCollectionRequest) GetCollection

func (*InstrumentCollectionRequest) GetConfig

func (x *InstrumentCollectionRequest) GetConfig() *anypb.Any

func (*InstrumentCollectionRequest) GetCookie

func (x *InstrumentCollectionRequest) GetCookie() string

func (*InstrumentCollectionRequest) GetHooks

func (*InstrumentCollectionRequest) GetPins

func (x *InstrumentCollectionRequest) GetPins() string

func (*InstrumentCollectionRequest) MarshalJSON

func (msg *InstrumentCollectionRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest) ProtoMessage

func (*InstrumentCollectionRequest) ProtoMessage()

func (*InstrumentCollectionRequest) ProtoReflect

func (*InstrumentCollectionRequest) Reset

func (x *InstrumentCollectionRequest) Reset()

func (*InstrumentCollectionRequest) String

func (x *InstrumentCollectionRequest) String() string

func (*InstrumentCollectionRequest) UnmarshalJSON

func (msg *InstrumentCollectionRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionRequest_Collection

type InstrumentCollectionRequest_Collection struct {

	// program details for each programs in the collection.
	Programs map[string]*InstrumentCollectionRequest_Collection_Program `` /* 143-byte string literal not displayed */
	// map details for each map in the collection.
	Maps map[string]*InstrumentCollectionRequest_Collection_Map `` /* 135-byte string literal not displayed */
	// contains filtered or unexported fields
}

Program and map IDs in the collection

func (*InstrumentCollectionRequest_Collection) Descriptor deprecated

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

Deprecated: Use InstrumentCollectionRequest_Collection.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest_Collection) GetMaps

func (*InstrumentCollectionRequest_Collection) GetPrograms

func (*InstrumentCollectionRequest_Collection) MarshalJSON

func (msg *InstrumentCollectionRequest_Collection) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest_Collection) ProtoMessage

func (*InstrumentCollectionRequest_Collection) ProtoReflect

func (*InstrumentCollectionRequest_Collection) Reset

func (*InstrumentCollectionRequest_Collection) String

func (*InstrumentCollectionRequest_Collection) UnmarshalJSON

func (msg *InstrumentCollectionRequest_Collection) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionRequest_Collection_Map

type InstrumentCollectionRequest_Collection_Map struct {
	Id uint32 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*InstrumentCollectionRequest_Collection_Map) Descriptor deprecated

Deprecated: Use InstrumentCollectionRequest_Collection_Map.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest_Collection_Map) GetId

func (*InstrumentCollectionRequest_Collection_Map) MarshalJSON

func (msg *InstrumentCollectionRequest_Collection_Map) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest_Collection_Map) ProtoMessage

func (*InstrumentCollectionRequest_Collection_Map) ProtoReflect

func (*InstrumentCollectionRequest_Collection_Map) Reset

func (*InstrumentCollectionRequest_Collection_Map) String

func (*InstrumentCollectionRequest_Collection_Map) UnmarshalJSON

func (msg *InstrumentCollectionRequest_Collection_Map) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionRequest_Collection_Program

type InstrumentCollectionRequest_Collection_Program struct {
	Id uint32 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*InstrumentCollectionRequest_Collection_Program) Descriptor deprecated

Deprecated: Use InstrumentCollectionRequest_Collection_Program.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest_Collection_Program) GetId

func (*InstrumentCollectionRequest_Collection_Program) MarshalJSON

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest_Collection_Program) ProtoMessage

func (*InstrumentCollectionRequest_Collection_Program) ProtoReflect

func (*InstrumentCollectionRequest_Collection_Program) Reset

func (*InstrumentCollectionRequest_Collection_Program) String

func (*InstrumentCollectionRequest_Collection_Program) UnmarshalJSON

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionRequest_Hook

type InstrumentCollectionRequest_Hook struct {

	// position of the hook relative to the target program.
	Type HookType `protobuf:"varint,1,opt,name=type,proto3,enum=datapathplugins.HookType" json:"type,omitempty"`
	// name of the program that should be instrumented.
	Target string `protobuf:"bytes,2,opt,name=target,proto3" json:"target,omitempty"`
	// info necessary for loading freplace programs.
	AttachTarget *InstrumentCollectionRequest_Hook_AttachTarget `protobuf:"bytes,3,opt,name=attach_target,json=attachTarget,proto3" json:"attach_target,omitempty"`
	// plugin must pin the hook program to this pin path before responding
	// to Cilium.
	PinPath string `protobuf:"bytes,4,opt,name=pin_path,json=pinPath,proto3" json:"pin_path,omitempty"`
	// contains filtered or unexported fields
}

func (*InstrumentCollectionRequest_Hook) Descriptor deprecated

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

Deprecated: Use InstrumentCollectionRequest_Hook.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest_Hook) GetAttachTarget

func (*InstrumentCollectionRequest_Hook) GetPinPath

func (x *InstrumentCollectionRequest_Hook) GetPinPath() string

func (*InstrumentCollectionRequest_Hook) GetTarget

func (*InstrumentCollectionRequest_Hook) GetType

func (*InstrumentCollectionRequest_Hook) MarshalJSON

func (msg *InstrumentCollectionRequest_Hook) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest_Hook) ProtoMessage

func (*InstrumentCollectionRequest_Hook) ProtoMessage()

func (*InstrumentCollectionRequest_Hook) ProtoReflect

func (*InstrumentCollectionRequest_Hook) Reset

func (*InstrumentCollectionRequest_Hook) String

func (*InstrumentCollectionRequest_Hook) UnmarshalJSON

func (msg *InstrumentCollectionRequest_Hook) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionRequest_Hook_AttachTarget

type InstrumentCollectionRequest_Hook_AttachTarget struct {

	// id of the target program.
	ProgramId uint32 `protobuf:"varint,1,opt,name=program_id,json=programId,proto3" json:"program_id,omitempty"`
	// name of the hook's subprogram inside the target program.
	SubprogName string `protobuf:"bytes,2,opt,name=subprog_name,json=subprogName,proto3" json:"subprog_name,omitempty"`
	// contains filtered or unexported fields
}

func (*InstrumentCollectionRequest_Hook_AttachTarget) Descriptor deprecated

Deprecated: Use InstrumentCollectionRequest_Hook_AttachTarget.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionRequest_Hook_AttachTarget) GetProgramId

func (*InstrumentCollectionRequest_Hook_AttachTarget) GetSubprogName

func (*InstrumentCollectionRequest_Hook_AttachTarget) MarshalJSON

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionRequest_Hook_AttachTarget) ProtoMessage

func (*InstrumentCollectionRequest_Hook_AttachTarget) ProtoReflect

func (*InstrumentCollectionRequest_Hook_AttachTarget) Reset

func (*InstrumentCollectionRequest_Hook_AttachTarget) String

func (*InstrumentCollectionRequest_Hook_AttachTarget) UnmarshalJSON

UnmarshalJSON implements json.Unmarshaler

type InstrumentCollectionResponse

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

func (*InstrumentCollectionResponse) Descriptor deprecated

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

Deprecated: Use InstrumentCollectionResponse.ProtoReflect.Descriptor instead.

func (*InstrumentCollectionResponse) MarshalJSON

func (msg *InstrumentCollectionResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*InstrumentCollectionResponse) ProtoMessage

func (*InstrumentCollectionResponse) ProtoMessage()

func (*InstrumentCollectionResponse) ProtoReflect

func (*InstrumentCollectionResponse) Reset

func (x *InstrumentCollectionResponse) Reset()

func (*InstrumentCollectionResponse) String

func (*InstrumentCollectionResponse) UnmarshalJSON

func (msg *InstrumentCollectionResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionRequest

type PrepareCollectionRequest struct {
	Collection        *PrepareCollectionRequest_CollectionSpec `protobuf:"bytes,1,opt,name=collection,proto3" json:"collection,omitempty"`
	AttachmentContext *AttachmentContext                       `protobuf:"bytes,2,opt,name=attachment_context,json=attachmentContext,proto3" json:"attachment_context,omitempty"`
	// config contains datapath configuration for this collection.
	Config *anypb.Any `protobuf:"bytes,3,opt,name=config,proto3" json:"config,omitempty"`
	// contains filtered or unexported fields
}

Phase 1: As Cilium loads and prepares a collection for a particular attachment point, it sends a PrepareHooksRequest to each plugin with context about the attachment point, collection, and its configuration. The plugin decides which hooks it would like to insert, where it would like to insert them, and informs Cilium in the PrepareHooksResponse.

func (*PrepareCollectionRequest) Descriptor deprecated

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

Deprecated: Use PrepareCollectionRequest.ProtoReflect.Descriptor instead.

func (*PrepareCollectionRequest) GetAttachmentContext

func (x *PrepareCollectionRequest) GetAttachmentContext() *AttachmentContext

func (*PrepareCollectionRequest) GetCollection

func (*PrepareCollectionRequest) GetConfig

func (x *PrepareCollectionRequest) GetConfig() *anypb.Any

func (*PrepareCollectionRequest) MarshalJSON

func (msg *PrepareCollectionRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PrepareCollectionRequest) ProtoMessage

func (*PrepareCollectionRequest) ProtoMessage()

func (*PrepareCollectionRequest) ProtoReflect

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

func (*PrepareCollectionRequest) Reset

func (x *PrepareCollectionRequest) Reset()

func (*PrepareCollectionRequest) String

func (x *PrepareCollectionRequest) String() string

func (*PrepareCollectionRequest) UnmarshalJSON

func (msg *PrepareCollectionRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionRequest_CollectionSpec

type PrepareCollectionRequest_CollectionSpec struct {

	// program details for each programs in the collection.
	Programs map[string]*PrepareCollectionRequest_CollectionSpec_ProgramSpec `` /* 143-byte string literal not displayed */
	// map details for each map in the collection.
	Maps map[string]*PrepareCollectionRequest_CollectionSpec_MapSpec `` /* 135-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*PrepareCollectionRequest_CollectionSpec) Descriptor deprecated

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

Deprecated: Use PrepareCollectionRequest_CollectionSpec.ProtoReflect.Descriptor instead.

func (*PrepareCollectionRequest_CollectionSpec) GetMaps

func (*PrepareCollectionRequest_CollectionSpec) GetPrograms

func (*PrepareCollectionRequest_CollectionSpec) MarshalJSON

func (msg *PrepareCollectionRequest_CollectionSpec) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PrepareCollectionRequest_CollectionSpec) ProtoMessage

func (*PrepareCollectionRequest_CollectionSpec) ProtoReflect

func (*PrepareCollectionRequest_CollectionSpec) Reset

func (*PrepareCollectionRequest_CollectionSpec) String

func (*PrepareCollectionRequest_CollectionSpec) UnmarshalJSON

func (msg *PrepareCollectionRequest_CollectionSpec) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionRequest_CollectionSpec_MapSpec

type PrepareCollectionRequest_CollectionSpec_MapSpec struct {
	Type       uint32 `protobuf:"varint,1,opt,name=type,proto3" json:"type,omitempty"`
	KeySize    uint32 `protobuf:"varint,2,opt,name=key_size,json=keySize,proto3" json:"key_size,omitempty"`
	ValueSize  uint32 `protobuf:"varint,3,opt,name=value_size,json=valueSize,proto3" json:"value_size,omitempty"`
	MaxEntries uint32 `protobuf:"varint,4,opt,name=max_entries,json=maxEntries,proto3" json:"max_entries,omitempty"`
	Flags      uint32 `protobuf:"varint,5,opt,name=flags,proto3" json:"flags,omitempty"`
	PinType    uint32 `protobuf:"varint,6,opt,name=pin_type,json=pinType,proto3" json:"pin_type,omitempty"`
	// contains filtered or unexported fields
}

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) Descriptor deprecated

Deprecated: Use PrepareCollectionRequest_CollectionSpec_MapSpec.ProtoReflect.Descriptor instead.

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetFlags

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetKeySize

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetMaxEntries

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetPinType

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetType

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) GetValueSize

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) MarshalJSON

MarshalJSON implements json.Marshaler

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) ProtoMessage

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) ProtoReflect

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) Reset

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) String

func (*PrepareCollectionRequest_CollectionSpec_MapSpec) UnmarshalJSON

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionRequest_CollectionSpec_ProgramSpec

type PrepareCollectionRequest_CollectionSpec_ProgramSpec struct {
	Type        uint32 `protobuf:"varint,1,opt,name=type,proto3" json:"type,omitempty"`
	AttachType  uint32 `protobuf:"varint,2,opt,name=attach_type,json=attachType,proto3" json:"attach_type,omitempty"`
	SectionName string `protobuf:"bytes,3,opt,name=section_name,json=sectionName,proto3" json:"section_name,omitempty"`
	License     string `protobuf:"bytes,4,opt,name=license,proto3" json:"license,omitempty"`
	// contains filtered or unexported fields
}

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) Descriptor deprecated

Deprecated: Use PrepareCollectionRequest_CollectionSpec_ProgramSpec.ProtoReflect.Descriptor instead.

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) GetAttachType

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) GetLicense

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) GetSectionName

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) GetType

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) MarshalJSON

MarshalJSON implements json.Marshaler

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) ProtoMessage

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) ProtoReflect

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) Reset

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) String

func (*PrepareCollectionRequest_CollectionSpec_ProgramSpec) UnmarshalJSON

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionResponse

type PrepareCollectionResponse struct {

	// list of hooks that should be added to the collection.
	Hooks []*PrepareCollectionResponse_HookSpec `protobuf:"bytes,1,rep,name=hooks,proto3" json:"hooks,omitempty"`
	// cookie is an opaque string that will be passed in the subsequent
	// InstrumentCollectionRequest related to this PrepareCollectionRequest. It
	// may be used by plugins to associate the two requests or carry metadata
	// between them.
	Cookie string `protobuf:"bytes,2,opt,name=cookie,proto3" json:"cookie,omitempty"`
	// contains filtered or unexported fields
}

func (*PrepareCollectionResponse) Descriptor deprecated

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

Deprecated: Use PrepareCollectionResponse.ProtoReflect.Descriptor instead.

func (*PrepareCollectionResponse) GetCookie

func (x *PrepareCollectionResponse) GetCookie() string

func (*PrepareCollectionResponse) GetHooks

func (*PrepareCollectionResponse) MarshalJSON

func (msg *PrepareCollectionResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PrepareCollectionResponse) ProtoMessage

func (*PrepareCollectionResponse) ProtoMessage()

func (*PrepareCollectionResponse) ProtoReflect

func (*PrepareCollectionResponse) Reset

func (x *PrepareCollectionResponse) Reset()

func (*PrepareCollectionResponse) String

func (x *PrepareCollectionResponse) String() string

func (*PrepareCollectionResponse) UnmarshalJSON

func (msg *PrepareCollectionResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionResponse_HookSpec

type PrepareCollectionResponse_HookSpec struct {

	// position of the hook relative to the target program.
	Type HookType `protobuf:"varint,1,opt,name=type,proto3,enum=datapathplugins.HookType" json:"type,omitempty"`
	// name of the program that should be instrumented.
	Target string `protobuf:"bytes,2,opt,name=target,proto3" json:"target,omitempty"`
	// constraints is a list of ordering constraints for this hook. If other
	// plugins want to place a hook at this same hook point, hooks from
	// various plugins will be arranged in an order that respects all
	// ordering constraints.
	Constraints []*PrepareCollectionResponse_HookSpec_OrderingConstraint `protobuf:"bytes,3,rep,name=constraints,proto3" json:"constraints,omitempty"`
	// contains filtered or unexported fields
}

func (*PrepareCollectionResponse_HookSpec) Descriptor deprecated

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

Deprecated: Use PrepareCollectionResponse_HookSpec.ProtoReflect.Descriptor instead.

func (*PrepareCollectionResponse_HookSpec) GetConstraints

func (*PrepareCollectionResponse_HookSpec) GetTarget

func (*PrepareCollectionResponse_HookSpec) GetType

func (*PrepareCollectionResponse_HookSpec) MarshalJSON

func (msg *PrepareCollectionResponse_HookSpec) MarshalJSON() ([]byte, error)

MarshalJSON implements json.Marshaler

func (*PrepareCollectionResponse_HookSpec) ProtoMessage

func (*PrepareCollectionResponse_HookSpec) ProtoMessage()

func (*PrepareCollectionResponse_HookSpec) ProtoReflect

func (*PrepareCollectionResponse_HookSpec) Reset

func (*PrepareCollectionResponse_HookSpec) String

func (*PrepareCollectionResponse_HookSpec) UnmarshalJSON

func (msg *PrepareCollectionResponse_HookSpec) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionResponse_HookSpec_OrderingConstraint

type PrepareCollectionResponse_HookSpec_OrderingConstraint struct {
	Order  PrepareCollectionResponse_HookSpec_OrderingConstraint_Order `` /* 145-byte string literal not displayed */
	Plugin string                                                      `protobuf:"bytes,2,opt,name=plugin,proto3" json:"plugin,omitempty"`
	// contains filtered or unexported fields
}

An OrderingConstraint is a constraint about where this hook should go at this hook point relative to other plugins' hooks.

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) Descriptor deprecated

Deprecated: Use PrepareCollectionResponse_HookSpec_OrderingConstraint.ProtoReflect.Descriptor instead.

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) GetOrder

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) GetPlugin

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) MarshalJSON

MarshalJSON implements json.Marshaler

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) ProtoMessage

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) ProtoReflect

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) Reset

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) String

func (*PrepareCollectionResponse_HookSpec_OrderingConstraint) UnmarshalJSON

UnmarshalJSON implements json.Unmarshaler

type PrepareCollectionResponse_HookSpec_OrderingConstraint_Order

type PrepareCollectionResponse_HookSpec_OrderingConstraint_Order int32
const (
	PrepareCollectionResponse_HookSpec_OrderingConstraint_UNKNOWN PrepareCollectionResponse_HookSpec_OrderingConstraint_Order = 0
	PrepareCollectionResponse_HookSpec_OrderingConstraint_BEFORE  PrepareCollectionResponse_HookSpec_OrderingConstraint_Order = 1
	PrepareCollectionResponse_HookSpec_OrderingConstraint_AFTER   PrepareCollectionResponse_HookSpec_OrderingConstraint_Order = 2
)

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) Descriptor

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) Enum

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) EnumDescriptor deprecated

Deprecated: Use PrepareCollectionResponse_HookSpec_OrderingConstraint_Order.Descriptor instead.

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) Number

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) String

func (PrepareCollectionResponse_HookSpec_OrderingConstraint_Order) Type

type UnimplementedDatapathPluginServer

type UnimplementedDatapathPluginServer struct{}

UnimplementedDatapathPluginServer should be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedDatapathPluginServer) PrepareCollection

type UnsafeDatapathPluginServer

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

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

Jump to

Keyboard shortcuts

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