Skip to content

Conversation

@ronething
Copy link
Contributor

@ronething ronething commented Apr 17, 2025

  • Temporarily ignore consistency tests

@ronething ronething marked this pull request as draft April 17, 2025 04:04
@ronething ronething changed the title (WIP)fix: remove default config (WIP)fix: remove gateway config items from the config file. Apr 17, 2025
@ronething ronething marked this pull request as ready for review April 17, 2025 10:20
@ronething ronething requested review from AlinsRan and Copilot April 17, 2025 10:20
@ronething ronething changed the title (WIP)fix: remove gateway config items from the config file. fix: remove gateway config items from the config file. Apr 17, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes legacy gateway configuration items from the config file and updates related tests and resource manifests to use a new GatewayProxy schema. Key changes include:

  • Removal of the gatewayAddress field and associated config references.
  • Replacement of legacy Ingress and Gateway configuration with new GatewayProxy YAML definitions.
  • Updates across tests, docs, and config files to drop deprecated gateway configuration items.

Reviewed Changes

Copilot reviewed 20 out of 20 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
test/e2e/scaffold/scaffold.go Removed gatewayAddress field from the Scaffold struct.
test/e2e/scaffold/ingress.go Removed reference to gatewayAddress in the ingress deployment.
test/e2e/ingress/ingress.go Updated Ingress tests to use new GatewayProxy YAML configuration.
test/e2e/gatewayapi/* Updated multiple test files to use the new GatewayProxy resource.
internal/provider/controlplane/controlplane.go Removed legacy gateway config usage when configuring the dashboard client.
internal/provider/adc/adc.go Dropped default ADC configuration using gateway config values.
internal/controller/utils.go Updated logging calls to use zap for consistency.
internal/controller/ingress_controller.go Modified function signatures and error messages to work with new parameters.
internal/controller/gateway_controller.go Updated gateway reconciliation to utilize the new GatewayProxy structure.
internal/controller/config/* and docs/config samples/chart files Removed deprecated gateway config items from configuration and docs.


// 1. use the IngressStatusAddress in the config
statusAddresses := config.GetIngressStatusAddress()
statusAddresses := gatewayProxy.Spec.StatusAddress
Copy link

Copilot AI Apr 17, 2025

Choose a reason for hiding this comment

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

The updateStatus function attempts to access gatewayProxy.Spec.StatusAddress, but the new GatewayProxy manifest no longer includes this field. Please update the logic to reflect the current GatewayProxy schema or provide an alternative field.

Copilot uses AI. Check for mistakes.
# - ${ENDPOINT} # The endpoint of the control plane.
# tls_verify: false
# addresses: # record the status address of the gateway-api gateway
# - "172.18.0.4" # The LB IP of the gateway service.
Copy link
Contributor

Choose a reason for hiding this comment

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

Why keep it?

Copy link
Contributor Author

@ronething ronething Apr 18, 2025

Choose a reason for hiding this comment

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

will resolve it in the next PR.

@@ -1,4 +1,4 @@
log_level: "info" # The log level of the API7 Ingress Controller.
log_level: "debug" # The log level of the API7 Ingress Controller.
Copy link
Contributor

Choose a reason for hiding this comment

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

info

return nil
}

//nolint:unused
Copy link
Contributor

Choose a reason for hiding this comment

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

dito.

- type: ExtensionRef
extensionRef:
group: gateway.api7.io
group: gateway.apisix.io
Copy link
Contributor

Choose a reason for hiding this comment

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

Are all our resources grouped as gateway.apisix.io, or are some grouped as gateway.api7.io and some grouped as gateway.apisix.io?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have changed all "gateway.api7.io" in the code to "gateway.apisix.io".

@ronething ronething merged commit c6f9a74 into release-v2-dev Apr 18, 2025
7 of 8 checks passed
@ronething ronething deleted the feat/remove_default_config branch April 18, 2025 02:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants