lib

package
v1.18.3 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2025 License: Apache-2.0 Imports: 15 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Indicates a non-recoverable error for DeletionFallbackClient.
	ErrClientFailure = errors.New("client failed")
)

Functions

This section is empty.

Types

type DeletionFallbackClient

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

func NewDeletionFallbackClient

func NewDeletionFallbackClient(logger *slog.Logger) *DeletionFallbackClient

NewDeletionFallbackClient creates a new deletion client.

func (*DeletionFallbackClient) EndpointDeleteMany

func (dc *DeletionFallbackClient) EndpointDeleteMany(req *models.EndpointBatchDeleteRequest) error

EndpointDeleteMany deletes multiple endpoints based on the endpoint deletion request, either by directly accessing the API or dropping in a queued-deletion file.

To prevent race conditions, the logic is: 1. Try and connect to the socket and request deletion. if that succeeds, done. 2. Otherwise, take a shared lock on the delete queue directory. 3. Once we have the lock, check again to see if the deletion request succeeds. 4. Persist the request to offline queue in case of failure.

Endpoint Deletion handled by this method returns two types of errors: 1. Delete request processing errors propagated from cilium-agent(eg. NotFound, Invalid) 2. Client failure indicating a non-recoverable error(eg. when deletion queue locking during fallback fails)

Jump to

Keyboard shortcuts

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