Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ kgateway is a **dual control plane** implementing the Kubernetes Gateway API for
### Controller Names & Isolation
kgateway supports **two independent controllers** that can run side-by-side:
- **Envoy Controller**: `kgateway.dev/kgateway` (defined in `wellknown.DefaultGatewayControllerName`)
- **Agentgateway Controller**: `kgateway.dev/agentgateway` (defined in `wellknown.DefaultAgwControllerName`)
- **Agentgateway Controller**: `agentgateway.dev/agentgateway` (defined in `wellknown.DefaultAgwControllerName`)

**Critical Requirements:**
1. Controllers MUST always respect `GatewayClass.spec.controllerName` Classname can matter, in the case of waypoints, but its always more specific information
Expand All @@ -34,7 +34,7 @@ kgateway supports **two independent controllers** that can run side-by-side:
**Deployment:**
- Gateway reconciler checks enable flags before calling deployer
- Deployer selects chart based on Gateway's controllerName from GatewayClass
- Chart selection: envoy chart for `kgateway.dev/kgateway`, agentgateway chart for `kgateway.dev/agentgateway`
- Chart selection: envoy chart for `kgateway.dev/kgateway`, agentgateway chart for `agentgateway.dev/agentgateway`

**Enable Flags:**
- `EnableEnvoy` (default: true): Controls if envoy ProxySyncer, StatusSyncer, and GatewayClass creation run
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,7 @@ conformance-%: ## Run only the specified Gateway API conformance test by ShortN
#----------------------------------------------------------------------------------

# Agent Gateway conformance test configuration
AGW_CONFORMANCE_GATEWAY_CLASS ?= agentgateway
AGW_CONFORMANCE_GATEWAY_CLASS ?= agentgateway-v2
AGW_CONFORMANCE_REPORT_ARGS ?= -report-output=$(TEST_ASSET_DIR)/conformance/agw-$(VERSION)-report.yaml -organization=kgateway-dev -project=kgateway -version=$(VERSION) -url=github.com/kgateway-dev/kgateway -contact=github.com/kgateway-dev/kgateway/issues/new/choose
AGW_CONFORMANCE_ARGS := -gateway-class=$(AGW_CONFORMANCE_GATEWAY_CLASS) $(AGW_CONFORMANCE_REPORT_ARGS)

Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/kgateway/gateway_parameters_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ type KubernetesProxyConfig struct {
Deployment *ProxyDeployment `json:"deployment,omitempty"`

// Configuration for the container running Envoy.
// If the Gateway uses a GatewayClass with controllerName: kgateway.dev/agentgateway,
// If the Gateway uses a GatewayClass with controllerName: agentgateway.dev/agentgateway,
// the EnvoyContainer values will be ignored.
Comment on lines +86 to 87
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this accurate now?

rather, I see that it's accurate, but is it relevant as an API doc going forward?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#13101 resolves this.

//
// +optional
Expand Down Expand Up @@ -679,7 +679,7 @@ func (in *StatsMatcher) GetExclusionList() []shared.StringMatcher {

// Agentgateway configures the agentgateway dataplane integration.
// The agentgateway dataplane is automatically used when the Gateway references a GatewayClass
// with controllerName: kgateway.dev/agentgateway.
// with controllerName: agentgateway.dev/agentgateway.
type Agentgateway struct {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

breadcrumb for followup:
shouldn't this whole thing be removed now?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#13101 resolves this too.

// Log level for the agentgateway. Defaults to info.
// Levels include "trace", "debug", "info", "error", "warn". See: https://docs.rs/tracing/latest/tracing/struct.Level.html
Expand Down
2 changes: 1 addition & 1 deletion examples/ai-backend-with-routes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: Gateway
metadata:
name: ai-gateway
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: http
port: 8080
Expand Down
2 changes: 1 addition & 1 deletion examples/ai-bedrock-with-prompt-caching.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ kind: Gateway
metadata:
name: ai-gateway
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: http
port: 8080
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@ spec:
envoyContainer:
description: |-
Configuration for the container running Envoy.
If the Gateway uses a GatewayClass with controllerName: kgateway.dev/agentgateway,
If the Gateway uses a GatewayClass with controllerName: agentgateway.dev/agentgateway,
the EnvoyContainer values will be ignored.
properties:
bootstrap:
Expand Down
2 changes: 1 addition & 1 deletion pkg/agentgateway/plugins/testdata/backendpolicy/ai.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -158,4 +158,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,4 @@ status:
reason: PartiallyValid
status: "True"
type: Accepted
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
2 changes: 1 addition & 1 deletion pkg/agentgateway/plugins/testdata/frontendpolicy/full.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -129,4 +129,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@ status:
reason: PartiallyValid
status: "True"
type: Accepted
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
2 changes: 1 addition & 1 deletion pkg/agentgateway/plugins/testdata/trafficpolicy/cel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
2 changes: 1 addition & 1 deletion pkg/agentgateway/plugins/testdata/trafficpolicy/cors.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ status:
reason: Pending
status: "False"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ status:
reason: Pending
status: "False"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
2 changes: 1 addition & 1 deletion pkg/agentgateway/plugins/testdata/trafficpolicy/retry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ status:
reason: Attached
status: "True"
type: Attached
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
4 changes: 2 additions & 2 deletions pkg/agentgateway/translator/testdata/gateways/_defaults.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: gateway.networking.k8s.io/v1
kind: GatewayClass
metadata:
name: agentgateway
name: agentgateway-v2
spec:
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
tls:
frontend:
perPort:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: http
port: 80
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: valid
port: 443
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: https
port: 443
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: tls
port: 443
Expand Down
6 changes: 3 additions & 3 deletions pkg/agentgateway/translator/testdata/routes/_defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ metadata:
apiVersion: gateway.networking.k8s.io/v1
kind: GatewayClass
metadata:
name: agentgateway
name: agentgateway-v2
spec:
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
---
apiVersion: gateway.networking.k8s.io/v1
kind: Gateway
metadata:
name: test-gateway
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: http
port: 80
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
6 changes: 3 additions & 3 deletions pkg/agentgateway/translator/testdata/routes/basic-tcp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ metadata:
name: tcp-gw
namespace: default
spec:
gatewayClassName: agentgateway
gatewayClassName: agentgateway-v2
listeners:
- name: foo
protocol: TCP
Expand Down Expand Up @@ -100,7 +100,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand All @@ -126,7 +126,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ status:
reason: BackendNotFound
status: "False"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
2 changes: 1 addition & 1 deletion pkg/agentgateway/translator/testdata/routes/matchers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand All @@ -129,7 +129,7 @@ status:
reason: ResolvedRefs
status: "True"
type: ResolvedRefs
controllerName: kgateway.dev/agentgateway
controllerName: agentgateway.dev/agentgateway
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
Expand Down
4 changes: 2 additions & 2 deletions pkg/deployer/deployer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ var _ = Describe("Deployer", func() {
agwp = agentgatewayParam("agent-gateway-params")
gwc = &gwv1.GatewayClass{
ObjectMeta: metav1.ObjectMeta{
Name: "agentgateway",
Name: wellknown.DefaultAgwClassName,
},
Spec: gwv1.GatewayClassSpec{
ControllerName: wellknown.DefaultAgwControllerName,
Expand All @@ -525,7 +525,7 @@ var _ = Describe("Deployer", func() {
Namespace: defaultNamespace,
},
Spec: gwv1.GatewaySpec{
GatewayClassName: "agentgateway",
GatewayClassName: wellknown.DefaultAgwClassName,
Infrastructure: &gwv1.GatewayInfrastructure{
ParametersRef: &gwv1.LocalParametersReference{
Group: agentgatewayv1alpha1.GroupName,
Expand Down
2 changes: 1 addition & 1 deletion pkg/deployer/gateway_parameters_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ func TestGetInMemoryGatewayParameters(t *testing.T) {

const (
envoyController = "kgateway.dev/kgateway"
agwController = "kgateway.dev/agentgateway"
agwController = "agentgateway.dev/agentgateway"
waypointClass = "waypoint"
)

Expand Down
Loading