pluginbinding

package
v2.1.13 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2026 License: Apache-2.0 Imports: 12 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BindingForPluginAndRoute

func BindingForPluginAndRoute(
	ctx context.Context,
	logger logr.Logger,
	cl client.Client,
	httpRoute *gwtypes.HTTPRoute,
	pRef *gwtypes.ParentReference,
	cp *commonv1alpha1.ControlPlaneRef,
	pluginName string,
	routeName string,
) (kongPluginBinding *configurationv1alpha1.KongPluginBinding, err error)

BindingForPluginAndRoute creates or updates a KongPluginBinding for the given plugin and route.

The function performs the following operations: 1. Generates the KongPluginBinding name using the namegen package 2. Checks if a KongPluginBinding with that name already exists in the cluster 3. If it exists, updates the KongPluginBinding annotations to include the current HTTPRoute 4. If it doesn't exist, creates a new KongPluginBinding 5. Returns the KongPluginBinding resource for use by the caller

Parameters:

  • ctx: The context for API calls and cancellation
  • logger: Logger for structured logging
  • cl: Kubernetes client for API operations
  • httpRoute: The HTTPRoute resource from which the KongPluginBinding is derived
  • pRef: The parent reference (Gateway) for the HTTPRoute
  • cp: The control plane reference for the KongPluginBinding
  • pluginName: The name of the KongPlugin to bind
  • routeName: The name of the KongRoute to bind to

Returns:

  • kongPluginBinding: The created or updated KongPluginBinding resource
  • err: Any error that occurred during the process

Types

This section is empty.

Jump to

Keyboard shortcuts

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